> < ^ Date: Mon, 11 Aug 2003 14:15:40 +0200
> < ^ From: Bill Allombert <allomber@math.u-bordeaux.fr >
> < ^ Subject: Re: Testing expression for positivity
On Mon, Jul 28, 2003 at 01:32:25PM +0100, Derek Holt wrote:
> Dear GAP Forum,
> 
> (I sent this message early in July, but I did not see it appear in the
> GAP Forum, so apologies if it appears twice!)
> 
> I have an expression, z,  say, involving the n-th roots of unity E(n), which
> evaluates to a real number (i.e. ComplexCojugate(z) = z.) For example
> z := E(5) + E(5)^-1 + E(3) + E(3)^-1;
> 
> Is there any way to test within GAP whether z is greater than 0, numerically?

I believe there is two answers:

1) You can't, because z is defined up to conjugacy and some conjugates
can be positive and other negative. For example z:=E(8)+E(-8) can be both
sqrt(2) and -sqrt(2).

2) You can use Sturm algorithm with the minimal polynomial of z.
At least that will tell you how many positive conjugates there are.
I don't know if this algorithm is available in GAP, but it is not
difficult to implement.

In your example, Sturm algorithm show there are two negative roots.

Cheers,
Bill.


> < [top]