Closed GoogleCodeExporter closed 9 years ago
In method public static IExpr expand(final IAST ast) of Expand class, I modify
else if (ast.isASTSizeGE(F.Times, 3)) {
// (a+b)*(c+d)...
// return expandTimes(ast);
IExpr[] temp = getFractionalParts(ast);
if (temp[0].equals(F.C1)) {
return F.Power(expandTimes(ast), F.CN1);
}
.....
to
else if (ast.isASTSizeGE(F.Times, 3)) {
// (a+b)*(c+d)...
// return expandTimes(ast);
IExpr[] temp = getFractionalParts(ast);
if (temp[0].equals(F.C1)) {
IExpr b = EvalEngine.eval(F.Power(ast, F.CN1));
IExpr a = expandTimes((IAST)b);
return F.Power(a,F.CN1);
//return F.Power(expandTimes(ast), F.CN1);
}
It works fine.
I hope that it's useful for you.
Original comment by huynhlam...@gmail.com
on 22 Sep 2010 at 9:30
Original comment by axelclk@gmail.com
on 22 Sep 2010 at 5:07
Fixed in SVN
http://code.google.com/p/symja/source/detail?r=559
Original comment by axelclk@gmail.com
on 22 Sep 2010 at 5:28
Original comment by axelclk@gmail.com
on 22 Sep 2010 at 5:29
Original comment by axelclk@gmail.com
on 27 Oct 2010 at 4:35
Original issue reported on code.google.com by
huynhlam...@gmail.com
on 22 Sep 2010 at 8:42