1

When I compute the the eigenvalues of the matrix $$\begin{bmatrix}x^3& 2 + x^3& 3 - 2 x^3\\ 2 + x^3& 4 - 5 x^3& 5 + 3 x^3\\ 3 - 2 x^3& 5 + 3 x^3& x^3\end{bmatrix}$$ using WolframAlpha, I get the following first eigenvalue (copied from WolframAlpha):

λ_1 = 1/3 (4 - 3 x^3) + 1/3 (-432 x^9 - 1449 x^6 + 810 x^3 + 3 sqrt(3) sqrt(-10664 x^18 + 34200 x^15 - 38845 x^12 - 162020 x^9 - 241908 x^6 + 30520 x^3 - 38808) + 1072)^(1/3) - (-78 x^6 - 18 x^3 - 130)/(3 (-432 x^9 - 1449 x^6 + 810 x^3 + 3 sqrt(3) sqrt(-10664 x^18 + 34200 x^15 - 38845 x^12 - 162020 x^9 - 241908 x^6 + 30520 x^3 - 38808) + 1072)^(1/3))

I want to see the first few terms of the Taylor expansion around x=0 of that expression, however, it seems WolframAlpha cannot handle it. I have been looking for an online Taylor series calculator that can do this but it seems the expression is too hard to crack.

Question: Can anyone share with me a website where I can compute the first few terms (until $x^3$) of the desired Tylor expansion about $x=0$? I do not know how to use programs like Matlab to do this. Do you have any recommendations?

In case it is of any help, here is the expression: $$ \frac{1}{3} (4 - 3 x^3) + \frac{1}{3} (-432 x^9 - 1449 x^6 + 810 x^3 + 3 \sqrt{3} \sqrt{-10664 x^{18} + 34200 x^{15} - 38845 x^{12} - 162020 x^9 - 241908 x^6 + 30520 x^3 - 38808} + 1072)^{1/3} - \frac{(-78 x^6 - 18 x^3 - 130)}{(3 (-432 x^9 - 1449 x^6 + 810 x^3 + 3 \sqrt{3} \sqrt{-10664 x^{18} + 34200 x^{15} - 38845 x^{12} - 162020 x^9 - 241908 x^6 + 30520 x^3 - 38808} + 1072)^{1/3})}$$

Yuval Filmus
  • 276,994
  • 27
  • 311
  • 503
Chilote
  • 113
  • 2

1 Answers1

2

SageMath can compute Taylor series. It is free software that can be downloaded for free, or it can be used online via CoCalc.

The following code will calculate Taylor series for all three eigenvalues:

M = matrix([[x^3, 2+x^3, 3-2*x^3], [2+x^3, 4-5*x^3, 5+3*x^3], [3-2*x^3, 5+3*x^3, x^3]])     
[taylor(lam,x,0,3) for lam in M.eigenvalues()]                                              

The resulting expressions don't seem too useful. In particular, although the eigenvalues are real, the equations involve complex numbers (possibly an example of casus irreducibilis).

Yuval Filmus
  • 276,994
  • 27
  • 311
  • 503
  • That's great! Could you please explain what lam is? I would like to understand how the second line of the code works. What does 0 and 3 stand for in taylor(lam,x,0,3)? Thanks. – Chilote Nov 15 '21 at 00:28