0
$\begingroup$

I am still a beginner and do not fully understand pure functions and root objects. When I tried to calculate the inverse of a function, Mathematica gave me:

f[B_] :=
  -744.790486 + 
  559.361126 Root[-247818634 - 2500 B + 796044875 #1 - 1032864500 #1^2 + 
    675444825 #1^3 - 222213025 #1^4 + 29396850 #1^5 &, 1] -
  0.468197 Root[-247818634 - 2500 B + 796044875 #1 - 1032864500 #1^2 + 
    675444825 #1^3 - 222213025 #1^4 + 29396850 #1^5 &, 1]^2

Mathematica has no problems evaluating f[B] once B is defined. Simple equations can be easily converted into an Excel-friendly format, but this isn't exactly a simple equation.

My question: Is it possible to format this in a way that Excel can generate the same result as Mathematica, or is this simply beyond the scope of what is achievable with Excel?

$\endgroup$
2
$\begingroup$

Your Root objects look like this:

r = Root[-247818634 - 2500 B + 796044875 #1 - 1032864500 #1^2 + 
          675444825 #1^3 - 222213025 #1^4 + 29396850 #1^5 &, 1]

and have both the parameter B and slot #1. One way to make this more Excel-friendly would be to change the slots into a variable like x:

First[r][x]
-247818634 - 2500 B + 796044875 x - 1032864500 x^2 + 675444825 x^3
                    - 222213025 x^4 + 29396850 x^5
$\endgroup$
  • 1
    $\begingroup$ Can Excel actually find the roots to high precision without numerical problems? I had the impression that Excel was a disaster waiting to happen for this sort of thing, just due to horrible numerics implementation. $\endgroup$ – Oleksandr R. Dec 18 '13 at 3:03
  • $\begingroup$ It wasn't able to find the roots to high precision, but thankfully it was accurate enough for my purposes. $\endgroup$ – Hughie Chan Dec 21 '13 at 22:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.