Share via

how to solve cubic equation on excel

Anonymous
2011-03-11T16:13:44+00:00

Trying to solve x^4+x^3+x^2+x+40=0   using an excel formula...  How do I accomplish this?  Thanks

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

  1. Anonymous
    2011-03-11T16:33:20+00:00

    For Excel to find a solution, a real solution must exist. Normally, you would convert your  formula to an Excel function like

    =A1^4+A1^3+A1^2+A1+40

    and then use Solver to change A1 to get the cell with the formula to have a value of zero.

    But there are no real roots for your equation, so you will need to use a much more sophisticated package, like Wolfram's Mathematica.

    HTH,

    Bernie

    20+ people found this answer helpful.
    0 comments No comments

Answer accepted by question author

  1. Anonymous
    2011-03-11T16:56:36+00:00

    You are not going to be able to solve cubic equations with a formula. To get an itdea why, look at the steps involved that have been delimited at this website...

    http://www.1728.com/cubic2.htm

    Even if you decided to use helper cells, quite a lot of them would be needed to accomplish your task. A better solution would be to develop a UDF (user defined function) solution using VBA and then call it from your worksheet.

    10+ people found this answer helpful.
    0 comments No comments

5 additional answers

Sort by: Most helpful
  1. Anonymous
    2013-11-16T06:00:51+00:00

    That's actually a quartic, cubics go up to the third power.

    The download here:

    http://newtonexcelbach.wordpress.com/2012/10/30/polynomial-update/

    has Excel UDFs to solve polynomials up to quartic (real and complex solutions) using a closed form solution, and for higher powers using an iterative method (which also works well for cubic and quartic equations).

    1 person found this answer helpful.
    0 comments No comments
  2. Anonymous
    2012-04-29T14:42:06+00:00

    You can use Goal seek in excel to solve equation. But the root (answer) should be real number.

    For this case, probably the answer is not real number. But generally, to solve with goal seek, you can do as follows...

    1. Enter your guessing value of x (solution) ...for example: enter 3 in cell A1
    2. Enter the formula according to the equation you want to solve referring to cell A1. For this case, enter =A1^4+A1^3+A1^2+A1+40 in cell A2
    3. Run goal seek and set target cell to A2 and the target value is 0, by changing cell A1

    Read more details about Goal Seek and VBA program to solve equation with Newton-Raphson method at my blog

    http://mechanical-design-handbook.blogspot.com/2008/05/microsoft-excel-goal-seek-technique-for.html

    http://mechanical-design-handbook.blogspot.com/2009/04/numerical-methods-newton-raphson-method.html

    If you want to solve system of equations using Gauss elimination method just check http://mechanical-design-handbook.blogspot.com/2011/02/solving-system-of-equations-using-gauss.html

    1 person found this answer helpful.
    0 comments No comments
  3. Anonymous
    2015-07-28T08:32:30+00:00

    Hi Bernie,

    I need to generalize this equation solver thing for some calculations, so that, i can get the solution every time on changing value of coefficient.

    for example;

    in a cubic equation, if i change coefficient a,b,c,d then also, i can get the solution.

    Please help.

    Thanks !!

    0 comments No comments