Solving a 3rd Degree Polynomial: What are the Options?

Click For Summary
SUMMARY

The discussion focuses on solving the cubic polynomial equation x³ + x² + 2x + 1 = 0. Participants attempted to find the roots using the Rational Root Theorem and cubic formulas but encountered difficulties. The correct roots were later identified as x = -1, x = i, and x = -i after realizing the original equation contained a typo. The conversation highlights the importance of numerical methods and the use of tools like Wolfram Alpha for solving polynomial equations efficiently.

PREREQUISITES
  • Understanding of cubic equations and their properties
  • Familiarity with the Rational Root Theorem
  • Knowledge of complex numbers and their roots
  • Basic skills in numerical methods for solving equations
NEXT STEPS
  • Learn about numerical methods for solving polynomial equations, such as Newton's method
  • Explore the use of companion matrices for solving cubic equations
  • Study the properties of complex roots and their implications in polynomial equations
  • Utilize online tools like Wolfram Alpha for polynomial root-finding
USEFUL FOR

Students, educators, and mathematicians interested in polynomial equations, particularly those seeking efficient methods for finding roots of cubic and higher-degree polynomials.

fishturtle1
Messages
393
Reaction score
82

Homework Statement


Solve for the roots of the following.
(What do you notice about the complex roots?)

b) x3 + x2 + 2x + 1 = 0

Homework Equations


To find roots of a polynomial of degree n > 3, look at the constant and take all its factors. Those are possible roots. Then plug them into see which ones solve the equation.

cubic equations from this link: http://www.mathportal.org/formulas/algebra/solalgebric.php

The Attempt at a Solution


factors of 1: 1, -1

x=1
(1)3 + 12 + 2(1) + 1 = 0

1 + 1 + 2 + 1 = 0
5 = 0, so 1 is not a root.

x=-1
(-1)3 + (-1)2 + 2(-1) + 1 = 0

-1 + 1 -2 + 1 = 0 -> -1 = 0
So -1 is not a root.

I also tried to use cubic formulas and did not find the correct answer. I checked my calculations.

So i think there is some method more simple than cubic equations that I cannot think of/find on the web.

Are there any other ways besides testing the constant term's factors, and using the cubic equations, to find the roots of a 3rd degree polynomial?
 
Physics news on Phys.org
fishturtle1 said:

Homework Statement


Solve for the roots of the following.
(What do you notice about the complex roots?)

b) x3 + x2 + 2x + 1 = 0

Homework Equations


To find roots of a polynomial of degree n > 3, look at the constant and take all its factors. Those are possible roots. Then plug them into see which ones solve the equation.

cubic equations from this link: http://www.mathportal.org/formulas/algebra/solalgebric.php

The Attempt at a Solution


factors of 1: 1, -1

x=1
(1)3 + 12 + 2(1) + 1 = 0

1 + 1 + 2 + 1 = 0
5 = 0, so 1 is not a root.

x=-1
(-1)3 + (-1)2 + 2(-1) + 1 = 0

-1 + 1 -2 + 1 = 0 -> -1 = 0
So -1 is not a root.

I also tried to use cubic formulas and did not find the correct answer. I checked my calculations.

So i think there is some method more simple than cubic equations that I cannot think of/find on the web.

Are there any other ways besides testing the constant term's factors, and using the cubic equations, to find the roots of a 3rd degree polynomial?

Show us what you got when you used the cubic formulas. Perhaps you made an error, but we cannot tell if you won't show us your work.
 
Testing factors of the constant term will almost certainly fail. It's not worth trying unless the problem function has been specially set up for that to work. You should show us how you used the cubic formulas. They should work every time.
 
Sorry, here is my work:

x3 + x2 + 2x + 1 = 0
So, a1 = 1, a2 = 2, a3 = 1

Then Q = (3a2 - a21)/9
Q = (3(2) - (1)2)/9
Q = (6-1)/9 = 5/9

R = (9a1a2 - 27a3 - 2a13) / 54
R = (9(1)(2) - 27(1) - 2(1)3)/54
R = (18 - 27 - 2) / 54
R = -11/54

S = (R + (Q3 + R2)(1/2))(1/3)
S = ( (-11/54) + ( (125/729) + (121/2916) )(1/2) ) (1/3)
S = about 0.63642

T = ( (R - (Q3 - R2)(1/2) ) (1/3)
T = ( (-11/54) - ( (125/729) - (121/2916) )1/2 ) 1/3
T = about 0.82632i, actually I just checked T = about 0.74690

So for my first root i did this:

x1 = S + T + a1/3 = 0.63642 + 0.82632i - 1/3

x1 = 0.30309 + 0.82632i
So with the new T, x1 = 0.30309 + 0.74690i.. but this is still wrong.
at which point I checked with an online calculator and this was not any of the three roots so I'm wondering if I used this formula incorrectly or just made a calculation error.Correct answers to online calculator:

x1 = -0.56984

x2 = -0.21508 + 1.30713i

x3 = -0.21508 - 1.30713i
 
For T, you should use the negative real third root of (R - (Q3 + R2)(1/2)). That is T=-0.872931847948311.
Your values of Q, R, and S are correct.
With the corrected value of T, you should get the correct roots.
 
fishturtle1 said:
Sorry, here is my work:

x3 + x2 + 2x + 1 = 0
So, a1 = 1, a2 = 2, a3 = 1

Then Q = (3a2 - a21)/9
Q = (3(2) - (1)2)/9
Q = (6-1)/9 = 5/9

R = (9a1a2 - 27a3 - 2a13) / 54
R = (9(1)(2) - 27(1) - 2(1)3)/54
R = (18 - 27 - 2) / 54
R = -11/54

S = (R + (Q3 + R2)(1/2))(1/3)
S = ( (-11/54) + ( (125/729) + (121/2916) )(1/2) ) (1/3)
S = about 0.63642

T = ( (R - (Q3 - R2)(1/2) ) (1/3)
T = ( (-11/54) - ( (125/729) - (121/2916) )1/2 ) 1/3
T = about 0.82632i, actually I just checked T = about 0.74690

So for my first root i did this:

x1 = S + T + a1/3 = 0.63642 + 0.82632i - 1/3

x1 = 0.30309 + 0.82632i
So with the new T, x1 = 0.30309 + 0.74690i.. but this is still wrong.
at which point I checked with an online calculator and this was not any of the three roots so I'm wondering if I used this formula incorrectly or just made a calculation error.Correct answers to online calculator:

x1 = -0.56984

x2 = -0.21508 + 1.30713i

x3 = -0.21508 - 1.30713i

For intermediate result you should keep as many digits as your calculator will hold. If you round intermediate quantities to values like 0.74690, etc., you can introduce significant roundoff errors, perhaps even making the final answer useless. (Of course I realize you may have done this, but it is not clear from what you wrote.)

Before embarking on an equation-solving expedition it is useful to first gain some insight into the nature of the problem. First, since all terms are > 0 for positive x, there is no positive root. Descarte's Rule of signs implies that the number of negative roots x < 0 is either three or one, and plotting the function makes it clear that there is only one. Furthermore, the function is > 0 at x = 0 and is < 0 at x =1, so there is a root between -1 and 0.

Almost nobody I know would ever bother using the cubic solution formula, even they know very well what it is; most people would just solve the equation numerically, which you can do to as many digits of accuracy as you could ever want using modern tools.
 
FactChecker said:
For T, you should use the negative real third root of (R - (Q3 + R2)(1/2)). That is T=-0.872931847948311.
Your values of Q, R, and S are correct.
With the corrected value of T, you should get the correct roots.
So is that a general rule when using these equations? That you leave the " i " out in the T? and yeah i see that this would help me get the real root. Thank you.

Ray Vickson said:
For intermediate result you should keep as many digits as your calculator will hold. If you round intermediate quantities to values like 0.74690, etc., you can introduce significant roundoff errors, perhaps even making the final answer useless. (Of course I realize you may have done this, but it is not clear from what you wrote.)

Before embarking on an equation-solving expedition it is useful to first gain some insight into the nature of the problem. First, since all terms are > 0 for positive x, there is no positive root. Descarte's Rule of signs implies that the number of negative roots x < 0 is either three or one, and plotting the function makes it clear that there is only one. Furthermore, the function is > 0 at x = 0 and is < 0 at x =1, so there is a root between -1 and 0.

Almost nobody I know would ever bother using the cubic solution formula, even they know very well what it is; most people would just solve the equation numerically, which you can do to as many digits of accuracy as you could ever want using modern tools.
I see what you mean. I remember in my physics class they taught us to never round too much in the in between steps and i forgot to use that here.

I feel like i have forgotten something from pre calculus class but what do you mean by "most people would just solve the equation numerically".. is there a method besides the cubic equations and rational roots test?
 
Ray Vickson said:
Almost nobody I know would ever bother using the cubic solution formula, even they know very well what it is; most people would just solve the equation numerically, which you can do to as many digits of accuracy as you could ever want using modern tools.
If I was writing a program, I would use the formulas. Numerical solutions can have problems converging and can require multiple attempts (with different initial values) to get a solution.
 
fishturtle1 said:
So is that a general rule when using these equations? That you leave the " i " out in the T? and yeah i see that this would help me get the real root.
Yes. They want T to be a real number. There is always one real cube root of any real number. If you include 'i', that is not a cube root of the number.
 
  • #10
FactChecker said:
If I was writing a program, I would use the formulas. Numerical solutions can have problems converging and can require multiple attempts (with different initial values) to get a solution.

The issue is not at all straightforward, due in part to the effects of roundoff errors. (Even programming the quadratic solution robustly is not as easy as one might think.)

There seems to be a debate among the experts as to whether iterative methods (Newton, etc.) or algebraic methods are better; both suffer from problems in implementation. However, there are newer iterative methods available that do not require "good" starting points, but they are more sophisticated than straight Newton-Raphson.

The OP might like to consult
http://math.stackexchange.com/quest...ng-cubic-and-quartic-equations-by-computer-pr
or
http://stackoverflow.com/questions/2003465/fastest-numerical-solution-of-a-real-cubic-polynomial

Some contributors to the latter recommend solving a cubic by setting up the companion matrix (for which the cubic is the characteristic polynomial) then using modern numerical linear algebra methods to find the eigenvalues of the matrix; they claim that that is how some of the available solvers actually work.

All of this matters only if you want to write your own code for solving the problem; otherwise (under what I call modern methods), just use one of the many, many cubic (or higher) solvers available already. For example, Wolfram Alpha works well and is free.
 
  • Like
Likes FactChecker
  • #11
Thanks for all your thoughtful answers. This is a late response because after reading some of those articles I was felt out of my depth and decided to come back to this problem set after practicing some easier problems.

Funny thing is, the instructor said the problem was a typo...it was supposed to read x3 + x2 + x + 1 = 0..

which I can see x = -1 is a root

so I can factor out x-1 and rewrite the original equation as: (x+1)(x2+1) = 0

then solve x2 + 1 = 0

x2 = -1

x = i, x = -i

So the roots are x = -1, -i, and i...now i will mark this as solved..just wanted to add the solution incase someone else wanted it.
 

Similar threads

  • · Replies 12 ·
Replies
12
Views
2K
  • · Replies 36 ·
2
Replies
36
Views
7K
  • · Replies 27 ·
Replies
27
Views
5K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 6 ·
Replies
6
Views
3K
Replies
6
Views
2K
  • · Replies 22 ·
Replies
22
Views
3K
  • · Replies 3 ·
Replies
3
Views
4K