MathGroup Archive 1998

[Date Index] [Thread Index] [Author Index]

Search the Archive

Quartic



hiya,


I want to solve 3 quartic eqns.

 Solve[{expr1, expr2, expr3 == 0}, A]

As it is too long, I was advised to do the folowing:

First, define the list of three expressions that you sent me before.

_______________________________________

In[1]:= expr = ...
_______________________________________


In[2]:= Short[e1 = First[expr], 5]

Out[2]//Short= 
 
        4           3   8    4   2        2      4          2     4
      p1  (B + p2) q  (q  + q  q2  (a + q2 ) + q2  (b + a q2  + q2 ))
>     --------------------------------------------------------------- + <<4>>
                                      4
                                    q2
_______________________________________
 _______________________________________

In[3]:= ccoeffs = 
        CoefficientList[c[1] + c[2] A + c[3] A^2 + c[4] A^3 + c[5] A^4,
A]

Out[3]= {c[1], c[2], c[3], c[4], c[5]}
_______________________________________
_______________________________________

In[4]:= coefflist = CoefficientList[Collect[e1,A],A];
_______________________________________
_______________________________________

In[5]:= sol = Solve[c[1] + c[2] A + c[3] A^2 + c[4] A^3 + c[5] A^4 == 0,
A];
_______________________________________

_______________________________________

In[6]:= InputForm[First[sol]]

Out[6]//InputForm=

  {A -> -c[4]/(4*c[5]) - ...

---------------------------------------

and Using this method, i manage to get the first solution of the 1st
expression.  

If I want all the four solutions from the first quartic, I just type
 
In[6]:= InputForm[sol], right?

So I get all the four solutions.  However, all the four solutions are
the same in symbolic. 
This is not what I got when I just test the quartic by giving each
variable in the quartic a value in which I used NSolve[expr,A].

Why is that?  Are all the four symbolic solutions that I got the correct
answers?

Please advise

As I need to know the answer quit urgent, I have to post it to the
newsgroup.  However, I am in debt to those that been helping me too. I
really appreciate it.

Regards
Col



  • Prev by Date: Nonlinear Programming Package for Mathematica?
  • Next by Date: Re: Boundary cond. at Infinity
  • Prev by thread: Nonlinear Programming Package for Mathematica?
  • Next by thread: Re: Quartic