20 Reputation

3 Badges

1 years, 9 days

MaplePrimes Activity

These are replies submitted by Chouette

@Kitonum I just realized that both rationalize(simplify(...)) and Algebraic[Normal](...) may fail to put products of radicals into a canonical form:

{%} intersect {%%};

{%} intersect {%%};

Both intersections are empty.

Maybe one has to pass through the minimal polynomial (with rational coefficients) of the algebraic numbers if one really wants a bullet-proof solution to this problem...

@acer Thank you for submitting the bug report. By the way, what is the right way to do it? Do you just fill this form?

@Kitonum Thanks for the workarounds! They work great. However for more general equations, some caution is needed for the second workaround, because the same algebraic number can be expressed in two different forms in Sol1 and Sol2, and intersect will not recognize this. It can be quite tricky to turn the two different expressions into the same form, as in the following example.

Sol1 := {solve( R^2-sqrt(2)*R-1 )};
Sol1_simplify := simplify(Sol1);
Sol1_normal   := Algebraic[Normal](Sol1);

Sol2 := {solve( (sqrt(3)+1)*R^2 = sqrt(3)-1 )};
Sol2_simplify := simplify(Sol2);
Sol2_normal   := Algebraic[Normal](Sol2);

Sol1 intersect Sol2;
Sol1_simplify intersect Sol2_simplify;
Sol1_normal intersect Sol2_normal;

The first two intersections are empty, and the last is not.

@Carl Love

Thanks for the suggestion on the relation between sovle and eliminate. Another observation is that, for polynomial equations, solve seems to mess up only when the coefficients are not (real) rational:


work just fine, but


fail to find any solutions.
Ultimately, we should probably just look into the code of solve (which is indeed very long...) to track down the origin of the problem. But that's for another day ;-)  (when I have some hours to kill)

Page 1 of 1