<aside> <img src="https://prod-files-secure.s3.us-west-2.amazonaws.com/369dfa6b-d4d9-4cf2-a446-e369553b6347/61e6d87a-904d-4057-929b-a9ea8e4d937b/Taylor_series.png" alt="https://prod-files-secure.s3.us-west-2.amazonaws.com/369dfa6b-d4d9-4cf2-a446-e369553b6347/61e6d87a-904d-4057-929b-a9ea8e4d937b/Taylor_series.png" width="40px" /> Taylor series: around a function $f(x)$ about the $x_0$
$$ \begin{aligned} f(x)&=f(x_0)+ f'(x_0)(x-x_0)+ f''(x_0) \frac{(x-x_0)^2}{2!}+\ldots \\ &=\sum^\infin_{n=0} \frac{1}{n!}f^{(n)}(x_0)(x-x_0)^n
\end{aligned} $$
</aside>
🐛 Expand $e^x$ about $x=0$
start with
$$ f^{(n)}(x)=\frac{\text d^n}{\text d x^n}e^x=e^x $$
hence
$$ f^{(n)}(0)=1 $$
Thus we have
$$ e^x=\sum^\infin_{n=0} \frac{1}{n!}x^n $$
Lets test if it works by taking the ratio of of successive terms. For this we can analyse the function
$$ f(x)=\sum^\infin_{n=0}a_n x^n $$
If the ratio of successive terms is less than $1$ then the series converges
$$ \lim_{n\to \infin} \left| \frac{a_{n+1}x^{n+1}}{a_nx^n}\right |=\lim_{n\to \infin} \left| \frac{a_{n+1}x}{a_n}\right |<1 $$
then the series converges
For $f(x)=e^x$ then we have
$$ \frac{a_{n+1}}{a_n} x=\frac{x^{n+1}}{(n+1)!}\frac{n!}{x^n}=\frac{x}{n+1}\to 0 \quad n\to\infin \quad \forall x $$
And thus the Taylor expansion of $e^x$ about $x=0$ converges for all values of $x$
🦋 Taylor series of $f(x)=(1-x)^{-1}$
We get
$$ \frac{1}{1-x}=\sum^\infin_{n=0} x^n $$
We don’t know for which value of $x$ the series converges. Since $(a_{n+1}=a_n$) we have
$$ \frac{a_{n+1}}{a_n}x=x $$
Thus the series converges provided $-1<x<1$ and outside this range it diverges
🗒️ Note: this power series technique can be used to solve ODEs
where $\binom{a}{n}= a!/(n!(a-n)!)$
🐌 Show that $y=a_0+a_2 x^2$ is a solution to Hermite’s equation
<aside> <img src="https://prod-files-secure.s3.us-west-2.amazonaws.com/369dfa6b-d4d9-4cf2-a446-e369553b6347/884aef1c-cb30-43ce-9a19-918f699f8c78/Hermites_equation.png" alt="https://prod-files-secure.s3.us-west-2.amazonaws.com/369dfa6b-d4d9-4cf2-a446-e369553b6347/884aef1c-cb30-43ce-9a19-918f699f8c78/Hermites_equation.png" width="40px" /> Hermite’s equation:
$$ \frac{\text d^2 y}{\text d x^2}-2x \frac{\text dy}{\text dx}+2ny =0 \quad n>0 $$
</aside>
We substitute this form of $y$ into it to get
$$ \frac{\text dy}{\text dx}=2a_2 x \quad \frac{\text d^2 y}{\text dx^2}=2 a_2 $$
thus we get
$$ 2a_2-4a_2x^2+2na_0+2na_2x^2=0 $$
If we equate coefficients we find
$$ \begin{aligned} 2a_2+2na_0&=0 \\ -4a_2+2na_2&=0
\end{aligned} $$
The first equation gives us $n=-a_2/a_0$ and the second gives us $n=2$
$$ y=a_0(1+2x^2) $$
as a solution if $n=2$
lets consider the summation of terms as a general solution to Hermite’s equation
$$ y=\sum^\infin_{k=0} a_kx^k $$
if we substitute it into Hermite’s equation we get
$$ \sum^\infin_{k=2}a_k k(k-1)x^{k-2}-2x\sum^\infin_{k=1}a_k kx^{k-1}+2n\sum^\infin_{n=0}a_kx^k=0 $$
We equate the coefficients of $x^k$
$$ a_{k+2}(k+2)(k+1)-2ka_k+2na_k=0 $$
hence we have the recurrence relation
$$ a_{k+2}=\frac{2(k-n)}{(k+2)(k+1)}a_k $$
We get the following solution
$$ y=a_0\left [ 1-2n\frac{x^2}{2!}-2n(4-2n)\frac{x^4}{4!}-\ldots \right ]+a_1\left [ x+(2-2n)\frac{x^3}{3!}+(2-2n)(6-2n)\frac{x^5}{5!}+\ldots \right ] $$
The recurrence relation gives $a_{k+2}=0$ at $k=n$ and one of the series terminates.
If $n=$ even we set $a_1=0$ and we can set $a_0=1$ and we obtain even polynomial solutions
$$ h_0(x)=1 \quad h_2(x)=1-2x^2 \quad h_4(x)=1-4x^2+4x^4/3 $$
Similarly we can set $a_0=0$ and $a_1=1$ to obtain the odd polynomials
$$ h_1(x)=x \quad h_3(x)=x-2x^3/3 \quad h_5(x)=x-4x^3/3+4x^5/15 $$
💎 Conclusion: these are Hermite polynomials which can be normalised and in physics the usual normalisation is to choose the coefficient of $x^n$ in $H_n(x)$ to be $2^n$ and under this condition we obtain:
🐿️ Hermite’s equation applied to Schrodinger equation for a SHM potential
We have a potential $V=Cx^2/2$ and classical mechanics predicts that a particle in this potential will oscillate with frequency $\nu=\frac{1}{2\pi}\sqrt{\frac{C}{m}}$ the corresponding Schrödinger equation is
$$ \frac{\text d^2 \phi}{\text dx^2}+\left [ \frac{2mE}{\hbar ^2}-\left ( \frac{2\pi m \nu}{\hbar} \right )^2 x^2 \right ]\psi=0 $$
we define $\alpha=2\pi m\nu/\hbar$ and $\beta=2mE/\hbar^2$
$$ \frac{\text d^2 \phi}{\text dx^2}+(\beta - \alpha^2 x^2)\psi=0 $$
We make a change of variable $\xi=\sqrt{\alpha} x$ which gets us to
$$ \frac{\text d^2 \psi}{\text d \xi^2}+\left ( \frac{\beta }{\alpha}-\xi^2\right )\psi=0 $$
for $|\xi|\to \infin$ we get
$$ \psi(\xi)=Ae^{-\xi^2/2} \quad |\xi|\to \infin $$
This suggests a general solution of
$$ \psi(\xi)=e^{-\xi^2/2}H(\xi) $$
this can be simplified to
$$ \frac{\text d^2 H}{\text d \xi^2}-2\xi \frac{\text d H}{\text d \xi}+\left ( \frac{\beta}{\alpha}-1 \right )H=0 $$
if we associate $\frac{\beta}{\alpha}-1=2n$ then this equation has solutions which are Hermite polynomials
🐩 SHM equation
We start with the SHM equation
$$ \frac{\text d^2 y}{\text dx^2}+y=0 $$
We take a series expansion at $x=0$
$$ y(x)=a_0+a_1x+a_2x^2+..=\sum^\infin_{n=0}a_n x^n $$
We can derive this to find
$$ \begin{aligned} y''(x)&=2a_2+6a_3 x+12 a_4 x^2+\ldots \\&=\sum^\infin_{n=2}a_n n(n-1) x^{n-2}=\sum^\infin_{n=0}a_{n+2}(n+2)(n+1)x^n \end{aligned} $$
Putting this into the expression for SHM
$$ \begin{aligned} y''+y&=(a_0+2a_2)+(a_1+6a_3)x+(a_2+12a_4)x^2+\ldots \\ &=\sum^\infin_{n=0}[a_{n+2}(n+2)(n+1)+a_n]x^n=0
\end{aligned} $$
Equating the coefficients we get
$$ \begin{aligned} a_0+2a_2&=0 \quad \Rightarrow a_2=-\frac 12 a_0 \\ a_1+6a_3&=0 \quad \Rightarrow a_3=-\frac{1}{6}a_1 \\ a_2+12a_4&=0 \quad \Rightarrow a_4 =-\frac{1}{12}a_2=\frac1{24}a_0
\end{aligned} $$
Thus provided we have $a_0$ we can evaluate $a_n$ for all even $n$ and given $a_1$ we can evaluate all odd $a_n$
We have a solution
$$ y(x)=a_0(1-\frac 12 x^2 +\frac 1{24} x^4-\ldots)+a_1(x-\frac 16 x^3+\ldots) $$
We recognise here our sin and cos terms
$$ \begin{aligned} \sin(x)&=x-\frac{x^3}6+\frac{x^5}{120}-\ldots \\ \cos(x)&=1-\frac {x^2}2+\frac{x^4}{24}-\ldots
\end{aligned} $$
Hence we have
$$ y(x)=a_0\cos(x)+a_1\sin(x) $$