Variation of parameters ODE what am i doing wrong?

In summary, the given equation can be simplified by diagonalizing the matrix and solving two separate, uncoupled equations. This method can be used to find the general solution by finding the inverse of the diagonalizing matrix. It is important to be careful with calculations to avoid errors.
  • #1
bmxicle
55
0

Homework Statement


[tex] \mathbb{x'}= \begin{bmatrix} 1 & 1 \\ 4 & 1 \end{bmatrix} \mathbf{x} \ + \ \begin{bmatrix} 2e^{t} \\ -e^{t} \end{bmatrix} [/tex]

Find the general solution.



Homework Equations





The Attempt at a Solution


Well i found the eigenvalues of the matrix That i'll call A, to get the solution to the homogenous equation:

[tex] \mathbf{x_h} = c_1\begin{bmatrix} 1 \\ 2 \end{bmatrix} e^{3t} + c_2 \begin{bmatrix} -1 \\ 2 \end{bmatrix} e^{-t}[/tex]

Let F be the fundamental matrix such that
[tex] F = \begin{bmatrix} e^{3t} & -e^{-t} \\ 2e^{3t} & 2e^{-t}\end{bmatrix} [/tex]
[tex] \mathbf{x'} = A\mathbf{x} + \mathbf{g}[/tex]

If we assume a solution [tex] \mathbf{x_{p}} = F\mathbf{u}[/tex]
Then after a few calculations we get
[tex]\mathbf{u'} = F^{-1}\mathbf{g}[/tex]
[tex]\mathbf{u'} = \frac{1}{4e^{4t}} \begin{bmatrix} 2e^{-t} & e^{-t} \\ -2e^{3t} & e^{3t} \end{bmatrix}* \begin{bmatrix} 2e^t \\ -e^t \end{bmatrix}[/tex] [tex]
\mathbf{u'} = \begin{bmatrix} 16e^{-4t} -4e^{-4t} \\-16 - 4 \end{bmatrix} = \begin{bmatrix} 12e^{-4t} \\ -20 \end{bmatrix} [/tex]
[tex] u_{1} = \int 12e^{-4t} dt = -3e^-4t + c [/tex]
[tex] u_{2} = \int -20 dt = -20t + c [/tex]
[tex] \mathbf{x_{p}} = F\mathbf{u} = \begin{bmatrix} e^{3t} & -e^{-t} \\ 2e^{3t} & 2e^{-t}\end{bmatrix} * \begin{bmatrix} -3e^{-4t} \\ -20t \end{bmatrix} [/tex]

[tex] \mathbf{x_{p}} =\begin{bmatrix} -3e^{-t} + 20e^{-t} \\ - 6 e^{-t} -40te^{-t} \end{bmatrix}[/tex]

So then to get the final answer you just add the particular solution X_p to the homogeneous solution.

I've been working on a bunch of these different non-homogeneous equations, and i keep getting the wrong answer basically every time, so If someone sees where i might be going wrong it would be much appreciated.
 
Physics news on Phys.org
  • #2
You basic error is that your [itex]F^{-1}[/itex] is wrong.
[tex]\begin{bmatrix}e^{3t} & - e^{-t} \\ 2e^{3t} & 2 e^{-t}\end{bmatrix}\begin{bmatrix}2e^{-t} & e^{-t} \\ -2e^{3t} & e^{3t}\end{bmatrix}= \begin{bmatrix}4e^{2t} & 0 \\ 0 & 4e^{2t}\end{bmatrix}[/tex]
so your
[tex]\frac{1}{4e^{4t}}[/tex]
should be
[tex]\frac{1}{4e^{2t}}[/tex]

However, here is a whole general method I prefer to what you are doing. You have already determined that the eigenvalues for the A matrix are 3 and -1 and that corresponding eigenvectors are [tex]\begin{bmatrix}1 \\ 2 \end{bmatrix}[/tex] and [tex]\begin{bmatrix}-1 \\ 2\end{bmatrix}[/tex] respectively. That means that A can be diagonalized- specifically that if
[tex]P= \begin{bmatrix}1 & -1 \\ 2 & 2\end{bmatrix}[/tex]
so that
[tex]P^{-1}= \begin{bmatrix}\frac{1}{2} & \frac{1}{4} \\ -\frac{1}{2} & \frac{1}{4}\end{bmatrix}[/tex]

then [itex]P^{-1}AP[/itex] is diagonal:
[tex]\begin{bmatrix}\frac{1}{2} & \frac{1}{4} \\ -\frac{1}{2} & \frac{1}{4}\end{bmatrix}\begin{bmatrix}1 & 1 \\ 4 & 1\end{bmatrix}\begin{bmatrix}1 & -1 \\ 2 & 2\end{bmatrix}= \begin{bmatrix}3 & 0 \\ 0 & -1\end{bmatrix}[/tex]

Now, writing the original equation
[tex]\frac{dX}{dt}= AX+ q[/tex]
and multiplying on both sides by [itex]P^{-1}[/itex],
[tex]\frac{P^{-1}X}{dt}= P^{-1}AX+ P^{-1}q= P^{-1}(APP^{-1}X)+ P^{-1}q[/tex]
[tex]\frac{P^{-1}X}{dt}= D(P^{-1}X)+ P^{-1}q[/tex]
where D is the diagonal matrix.

If we let [itex]Y= P^{-1}x[/itex], then the equation is
[tex]\frac{dY}{dt}= DY+ P^{-1}q[/tex]
which, because D is diagonal is "completely uncoupled". That is, the two equations are completely separate and can be solved separately.

Here,
[tex]P^{-1}q= \begin{bmatrix}\frac{1}{2} & \frac{1}{4} \\ -\frac{1}{2} & \frac{1}{4}\end{bmatrix}\begin{bmatrix}2e^t \\ -e^t\end{bmatrix}= \begin{bmatrix}\frac{3}{4}e^t \\ -\frac{5}{4}e^t \end{bmatrix}[/tex]

That is, writing
[tex]Y(t)= \begin{bmatrix}y_1(t) \\ y_2(t)\end{bmatrix}[/tex]
the equation becomes
[tex]\frac{d\begin{bmatrix}y_1(t) \\ y_2(t)\end{bmatrix}}{dx}= \begin{bmatrix}3 & 0 \\ 0 & -1\end{bmatrix}\begin{bmatrix}y_1(t) \\ y_2(t)\end{bmatrix}+ \begin{bmatrix}\frac{3}{4}e^t \\ -\frac{5}{4}e^t\end{bmatrix}[/tex]
which is simply the two "uncoupled" equations
[tex]\frac{dy_1(t)}{dt}= 3y_1(t)+ \frac{3}{4}e^t[/tex]
and
[tex]\frac{dy_2(t)}{dt}= -y_1(t)- \frac{5}{4}e^t[/tex]

You can solve for [itex]y_1(t)[/itex] and [itex]y_2(t)[/itex] separately and then
[tex]X(t)= PY(t)= \begin{bmatrix}1 & -1 \\ 2 & 2\end{bmatrix}\begin{bmatrix}y_1(t) \\ y_2(t) \end{bmatrix}[/tex].

That only requires finding the inverse of P, a constant matrix.
 
  • #3
ahh yep that would be wrong. I did the after correcting that mistake and got the correct answer. I guess i just keep making computational mistakes somewhere along the way.

Thanks for the derivation of Diagonalization, that was much clearer than the one in my textbook, and it definitely seems easier when the matrix is diagonalizable. When you're solving for Y1 and Y2 is it fine to just set the integration constants to zero because you just need to find a particular solution of the non-homogenous portion of the equation?
 

1. What is the variation of parameters method for solving ODEs?

The variation of parameters method is a technique used to solve nonhomogeneous linear ordinary differential equations (ODEs). It involves finding a particular solution by using a set of functions known as the fundamental set of solutions, which are linearly independent solutions to the corresponding homogeneous ODE. These functions are then multiplied by unknown coefficients and substituted into the ODE, allowing for the determination of the particular solution.

2. What is the difference between variation of parameters and the method of undetermined coefficients?

The method of undetermined coefficients is a technique used to solve particular types of nonhomogeneous linear ODEs, while the variation of parameters method can be applied to a wider range of nonhomogeneous linear ODEs. The method of undetermined coefficients involves making an educated guess for the form of the particular solution, while the variation of parameters method uses a set of functions to construct the particular solution.

3. What are the steps for using the variation of parameters method?

The steps for using the variation of parameters method are as follows:
1. Find the general solution to the corresponding homogeneous ODE
2. Determine the fundamental set of solutions by solving the homogeneous ODE
3. Multiply the fundamental set of solutions by unknown coefficients
4. Substitute the solutions into the nonhomogeneous ODE and solve for the coefficients
5. Use the particular solution and the general solution to obtain the complete solution to the nonhomogeneous ODE.

4. What are some common mistakes made while using the variation of parameters method?

Some common mistakes made while using the variation of parameters method include:
- Not finding the general solution to the corresponding homogeneous ODE
- Using a linearly dependent set of fundamental solutions
- Making errors while multiplying the fundamental solutions by the unknown coefficients
- Forgetting to add the complementary solution to the particular solution to obtain the complete solution.

5. How can I check if my solution using the variation of parameters method is correct?

To check if your solution using the variation of parameters method is correct, you can substitute the particular solution back into the original nonhomogeneous ODE and see if it satisfies the equation. Additionally, you can also check if the general solution obtained by adding the particular solution to the complementary solution satisfies the initial conditions given in the problem.

Similar threads

  • Calculus and Beyond Homework Help
Replies
5
Views
972
  • Calculus and Beyond Homework Help
Replies
3
Views
572
  • Calculus and Beyond Homework Help
Replies
7
Views
1K
  • Calculus and Beyond Homework Help
Replies
4
Views
2K
  • Differential Equations
Replies
2
Views
1K
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
5
Views
1K
  • Calculus and Beyond Homework Help
Replies
12
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
958
  • Calculus and Beyond Homework Help
Replies
11
Views
2K
Back
Top