       Re: Why is the negative root?

• To: mathgroup at smc.vnet.net
• Subject: [mg69582] Re: Why is the negative root?
• From: Paul Abbott <paul at physics.uwa.edu.au>
• Date: Sat, 16 Sep 2006 03:50:20 -0400 (EDT)
• Organization: The University of Western Australia
• References: <200609130803.EAA18412@smc.vnet.net> <eee0fi\$6gl\$1@smc.vnet.net>

In article <eee0fi\$6gl\$1 at smc.vnet.net>, p-valko at tamu.edu wrote:

> "Why do you need to use ToRadicals here?"
>
> I need the positive root(s) of  the equation  z^3 - z^2 - b*z-1==0
> where b>0. (This is a cubic equation of state problem.)

And indeed, this is what Reduce gives you. The answer given by

ans = Reduce[{z^3 - z^2 - b z - 1 == 0, b > 0, z > 0}, z]

_is_ the positive root of the equation z^3 - z^2 - b z-1==0 where b>0.

> I know the answer: there is only one positive root and it is given by
>
> 1/3 - (2^(1/3)*(-1 - 3*b))/(3*(29 + 9*b + 3*Sqrt*Sqrt[31 + 18*b -
> b^2 - 4*b^3])^(1/3)) +  (29 + 9*b + 3*Sqrt*Sqrt[31 + 18*b - b^2 -
> 4*b^3])^(1/3)/(3*2^(1/3))

In this case, the single root can be represented by this radical. But
modify your example slightly:

Reduce[{z^3 - z^2 - b z + 3 == 0, b > 0, z > 0}, z] // FullSimplify

How would you prefer the result to be expressed now?

> but I still do not have any idea how to persuade Mathematica to give me
> this (or any reasonable) result.

Why is the above result, ans, not reasonable or preferable?

In this example,

Root[#^3 - #^2 - b # - 1 & , 1] // ToRadicals

does give you the radical expression that you are after. However, to
quote Daniel Lichtblau from TMJ 9(3), here are some reasons to prefer
the Root form:

 It is typically faster to obtain.

 It is numerically more stable to evaluate. In general, radical
formulations are prone to numeric problems. Root objects do not have
this liability.

 When the roots of an irreducible cubic are all real but not
rational, the so-called "casus irreducibilis" shows that they still must
be expressed in terms of I. See

http://mathworld.wolfram.com/CasusIrreducibilis.html.

This means that numeric evaluation will give small imaginary parts
unless, by happenstance, they exactly cancel. Small numeric error from
round-off makes this unlikely.

 For sufficiently complicated algebraics, it is often faster to
evaluate the Root form numerically, at least at high precision.

 Polynomial combinations of Root objects simplify using RootReduce.

 Derivatives of Root objects with respect to a parameter are
expressed in terms of Root objects. This is useful for eigenvalue
sensitivity analysis.

So, one can avoid the Root form by using ToRadicals -- but for all
practical computation, you are better off working with Root objects.

Cheers,
Paul

_______________________________________________________________________
Paul Abbott                                      Phone:  61 8 6488 2734
School of Physics, M013                            Fax: +61 8 6488 1014
The University of Western Australia         (CRICOS Provider No 00126G)
AUSTRALIA                               http://physics.uwa.edu.au/~paul

• Prev by Date: Re: MathematicaTask.java
• Next by Date: Re: How to tell Mathematica to stop conditional testing in an If statment if one condition is niether True or False? McCarthy evaluation rules? 'and then' test?
• Previous by thread: Re: Why is the negative root?
• Next by thread: Re: Why is the negative root?