# How to solve this 2nd order ODE?

• Tony Hau
In summary: No, ##\psi = Ae^{-\frac{\xi^2}{2}}+ Be^{\frac{\xi^2}{2}}## is not an exact solution of the ODE ##\frac{d^2\psi}{d\xi^2} = \xi^2\psi##. If you plug it in and calculate ##\frac{d^2\psi}{d\xi^2}## you ll find that it is equal to ##(\xi^2+1)\psi## as @pasmith first noted at post #3. But for large ##\xi## it is ##\xi^2+1\approx \xi^2## so it
Tony Hau
Homework Statement
Solve for ##\frac{d^{2}\psi}{d\xi^2} =\xi^2\psi##
Relevant Equations
For unequal roots 2nd order ODE, the solution is: ##y=c_{1}e^{-kx}+c_{2}e^{kx}##
This is a very simple question: I would like to solve for ##\psi## in this equation $$\frac{d^{2}\psi}{d\xi^2} =\xi^2\psi$$
I so apply ##y=c_{1}e^{-kx}+c_{2}e^{kx}## and ##\psi## should be equal to ##\psi=c_{1}e^{-\xi^2}+c_{2}e^{\xi^2}##, because ##(D^2-\xi^2)\psi=0##. However the answer is ##\psi(\xi) = c_{1}e^{-\frac{\xi^2}{2}}+c_{2}e^{\frac{\xi^2}{2}}##. Why is it so?

Your relevant equation is for constant coefficients. Your ODE does not have constant coefficients.

Try the substitution $\psi = e^{f(\xi)}$.

EDIT: Also, $(D - \xi)(D + \xi) \neq (D^2 - \xi^2)$ since multiplication by $\xi$ and differentiation wrt $\xi$ do not commute: By the product rule, $$D\xi = \xi D + 1.$$

Last edited:
Tony Hau and Delta2
Additionally, $e^{\pm\xi^2/2}$ are not solutions, as can be determined by inspection: if $\psi = e^{\pm\xi^2/2}$ then \begin{align*} \psi' &= \pm \xi \psi \\ \psi'' &= \pm(\psi + \xi \psi') = (\xi^2 \pm 1)\psi \\ &\neq \xi^2 \psi. \end{align*} If you want to sove this ODE I suspect you will need to look for a power series. (My proposed substitution will lead to a first -order ODE in $f'$, but it has the drawback of being non-linear.)

Tony Hau
Try tweaking pasmith's non solution. I.e. try e^(x^2/2) + f, and see what f needs to be to kill off the extra terms coming from the first part. Maybe the solution is not "elementary", since you need an antiderivative of e^(x^2/2).

Tony Hau
mathwonk said:
Try tweaking pasmith's non solution. I.e. try e^(x^2/2) + f, and see what f needs to be to kill off the extra terms coming from the first part. Maybe the solution is not "elementary", since you need an antiderivative of e^(x^2/2).
I think it will turn out that ##f=e^{-\frac{x^2}{2}}##. In the OP he claims that the correct solution is ##\psi=c_1e^{\frac{x^2}{2}}+c_2e^{-\frac{x^2}{2}}## and I think that's correct.

I think I was wrong up to a constant, the solution seems to be $$\psi=c\left (e^{\frac{x^2}{2}}+e^{-\frac{x^2}{2}}\right )$$

Tony Hau
Nope I was totally wrong this solution doesn't work. SORRY!

Delta2 said:
I think I was wrong up to a constant, the solution seems to be $$\psi=c\left (e^{\frac{x^2}{2}}+e^{-\frac{x^2}{2}}\right )$$
The solution is same as I stated. Actually this is from a proof on my textbook on quantum mechanics, where the proof is about solving the simple harmonic oscillator. ##\psi(x)## refers to the wave function; ##\xi## refers to the constant ##\sqrt{\frac{m\omega}{\hbar}}x##

Tony Hau said:
The solution is same as I stated. Actually this is from a proof on my textbook on quantum mechanics, where the proof is about solving the simple harmonic oscillator. ##\psi(x)## refers to the wave function; ##\xi## refers to the constant ##\sqrt{\frac{m\omega}{\hbar}}x##
Can you post a screenshot from the book's page, cause the solution you state at the OP doesn't verify the differential equation.

Delta2
Delta2 said:
Can you post a screenshot from the book's page, cause the solution you state at the OP doesn't verify the differential equation.
By the way, it would be very nice if you could explain what asymptotic form is in the second picture. I don't understand the transition from ##\psi = Ae^{\frac{-\xi^2}{2}}+Be^{\frac{\xi^2}{2}}## to ##\psi = h(\xi)e^{\frac{-\xi^2}{2}}##

Tony Hau said:
By the way, it would be very nice if you could explain what asymptotic form is in the second picture. I don't understand the transition from ##\psi = Ae^{\frac{-\xi^2}{2}}+Be^{\frac{\xi^2}{2}}## to ##\psi = h(\xi)e^{\frac{-\xi^2}{2}}##
TO be honest I don't understand that transition myself, however the book says that the solution you give at the OP is an approximate solution for large ##\xi##, something that you didn't tell us from start!

Tony Hau
Delta2 said:
TO be honest I don't understand that transition myself, however the book says that the solution you give at the OP is an approximate solution for large ##\xi##, something that you didn't tell us from start!
I am sorry. I thought the approximation only refers to ##\frac{d^2\psi}{d\xi^2} \approx \xi^2\psi##; with regards to the approximation ##\frac{d^2\psi}{d\xi^2} \approx \xi^2\psi## , the following ##\psi = Ae^{-\frac{\xi^2}{2}}+ Be^{\frac{\xi^2}{2}}## is exact and is not an approximation.

Tony Hau said:
I am sorry. I thought the approximation only refers to ##\frac{d^2\psi}{d\xi^2} \approx \xi^2\psi##; with regards to the approximation ##\frac{d^2\psi}{d\xi^2} \approx \xi^2\psi## , the following ##\psi = Ae^{-\frac{\xi^2}{2}}+ Be^{\frac{\xi^2}{2}}## is exact and is not an approximation.
No, ##\psi = Ae^{-\frac{\xi^2}{2}}+ Be^{\frac{\xi^2}{2}}## is not an exact solution of the ODE ##\frac{d^2\psi}{d\xi^2} = \xi^2\psi##. If you plug it in and calculate ##\frac{d^2\psi}{d\xi^2}## you ll find that it is equal to ##(\xi^2+1)\psi## as @pasmith first noted at post #3. But for large ##\xi## it is ##\xi^2+1\approx \xi^2## so it is indeed an approximate solution for large ##\xi## always.

Tony Hau
Tony Hau said:
This is a very simple question: I would like to solve for ##\psi## in this equation $$\frac{d^{2}\psi}{d\xi^2} =\xi^2\psi$$

This is a special case of Titchmarsh's Equation, the solution of which is in terms of special functions. In your case, the solution of ##y''-x^2y=0## is
$$y(x)=c_1 D[-1/2,\sqrt{2} x]+c_2 D[-1/2,i\sqrt{2}x]$$
where ##D[v,u]## is the parabolic cylinder function: Parabolic Cylinder function
Might be interesting to study how the approximate solution differs from this solution.

Tony Hau and Delta2

## 1. How do I determine the order of a differential equation?

The order of a differential equation is determined by the highest derivative present in the equation. For example, a second order differential equation will have a second derivative present.

## 2. What is the general approach to solving a 2nd order ODE?

The general approach to solving a 2nd order ODE is to first rewrite the equation in standard form, where the highest derivative is isolated on one side. Then, using the appropriate method (such as separation of variables or variation of parameters), solve for the dependent variable.

## 3. How do I know which method to use to solve a 2nd order ODE?

The method used to solve a 2nd order ODE depends on the specific characteristics of the equation, such as whether it is linear or non-linear, homogeneous or non-homogeneous, and whether the coefficients are constant or variable. It is important to carefully analyze the equation before choosing a method.

## 4. Can a 2nd order ODE have multiple solutions?

Yes, a 2nd order ODE can have multiple solutions. This is because the general solution to a 2nd order ODE will typically involve two arbitrary constants, which can result in an infinite number of possible solutions.

## 5. Is it necessary to use initial or boundary conditions when solving a 2nd order ODE?

Yes, it is necessary to use initial or boundary conditions when solving a 2nd order ODE. These conditions help to determine the specific values of the arbitrary constants in the general solution, and therefore provide a unique solution to the equation.

Replies
18
Views
2K
Replies
8
Views
2K
Replies
21
Views
1K
Replies
1
Views
2K
Replies
3
Views
725
Replies
1
Views
758
Replies
6
Views
1K
Replies
4
Views
767
Replies
10
Views
1K
Replies
2
Views
758