Setting of gcd variable.



The rational function package knows nothing about trigonometric functions:
2*cos(x)+sin(x)^3/3 is represented as (6*q1 + q2^3)/3, where q1=cos(x) and
q2=sin(x).  Any simplifications specific to trigonometric functions are
handled in the general simplifier.

ratsimp recursively applies rational function packages, so ratsimp(
sin((x^2-1)/(x-1)) ) => sin(x+1).

The differences among the various settings of gcd come up when the
polynomials do not factor over the integers.

For example, x^2 - 2 does not factor over the integers, but is evenly
divisible by x-sqrt(2) over the algebraic numbers.

Facts declared using assume are not used by the rational function package,
but they are used (though not very consistently) in the general simplifier.
 Mostly this is used to determine whether quantities are in some appropriate
range, so for example abs(x) => x when x>= 0.  That said, many cases are not
covered (usually for reasons of implementation ease or efficiency).  For
example, assume(q1>0,q1<1) floor(q1)=>0 but assume(q2>1,q2<2) floor(q2) =>
unsimplified and assume(equal(q3,0)) floor(q3) => q3 (better than floor(q3),
but why not 0?).  In general, equal is the least well supported: declaring
assume(equal(x,0)) does *not* have the effect of substituting zero for x in
all subsequent uses (why not?  no good reason, really), and
assume(equal(r1,r2)) does not simplify r1-r2 => 0.

           -s

On Tue, Jun 7, 2011 at 10:48, Constantine Frangos <cfrangos at telkomsa.net>wrote:

>
> Dear List,
>
> I am using ratsimp() and fullratsimp() for simplification with the setting
> of the variable gcd = spmod.
>
> Any assistance with the following would be appreciated:
>
> (1) In a recent posting by Stavros Macrakis, it seems that the settings
> spmod = red and spmod = subres
> lead to cancellations in fractions, not obtainable with gcd = spmod.
>
> Which setting is best for the case of expressions with complicated
> trigonometric terms ?
>
> What known  bugs/side-effects result for each possible value of spmod ?
>
>
> (2) Are facts entered using the assume() function, explicitly used by
> all/some simplification functions ?
>
> Thanks very much.
> Regards,
> Constantine Frangos.
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>