Problem with finding the general solution of an ode

In summary: D+2C)\cos(x)-(2D-C)\sin(x)\right)I got it now :D...y_p''(x)=e^{2x}\left((D+2C)\cos(x)-(2D-C)\sin(x)\right)
  • #1
brunette15
58
0
Hi everyone, I am trying to find the general solution for the following ode: y'' +gy' + 10y = e2xcos(x)

The solution states that the answer is y = 1/145 (5cos(x) + 2sin(x))e2x + (Acos(x) + Bsin(x))e-3x

I was able to correctly find the homogeneous part of the equation as e-3x (Acos(x) + Bsin(x))

Now to find the particular solution I have guessed that the answer is yp = Csin(x) + Dcos(x)

From here,

yp' = Ccos(x) - Dsin(x)
yp'' = -Csin(x) - Dcos(x)

Substituting yp,yp',yp'' in the ODE

-Csin(x) - Dcos(x) + 6Ccos(x) - 6Dsin(x) + 10Csin(x) + 10Dcos(x) = e2xcos(x)

Gathering all sin(x)

-C-6D + 10C = 0

C = 2/3D -->equation1

Gathering all cos(x)

6C + 9D = e2x --> equation 2

Solving equation 1 and equation 2

D = e2x/13

C = e2x2/39

As you can see i have different values for C and D compared to the solution.

Can anyone see where i am going wrong or is there a chance that the solution may be incorrect?
Thanks in advance :)
 
Physics news on Phys.org
  • #2
Judging by your homogeneous solution, the ODE should actually be:

\(\displaystyle y''+6y'+10y=e^{2x}\cos(x)\)

Is this correct?

Another issue I see is the form of your particular solution...do you see anything missing from it? :D
 
  • #3
MarkFL said:
Judging by your homogeneous solution, the ODE should actually be:

\(\displaystyle y''+6y'+10y=e^{2x}\cos(x)\)

Is this correct?

Another issue I see is the form of your particular solution...do you see anything missing from it? :D

Yes sorry i made a typo that should be the correct ODE.

I still don't see what i am missing (Worried)
 
  • #4
brunette15 said:
Yes sorry i made a typo that should be the correct ODE.

I still don't see what i am missing (Worried)

On the right side of the ODE you have:

\(\displaystyle e^{2x}\cos(x)\)

And so the form for your particular solution should be:

\(\displaystyle y_p(x)=e^{2x}\left(C\cos(x)+D\sin(x)\right)\)
 
  • #5
MarkFL said:
On the right side of the ODE you have:

\(\displaystyle e^{2x}\cos(x)\)

And so the form for your particular solution should be:

\(\displaystyle y_p(x)=e^{2x}\left(C\cos(x)+D\sin(x)\right)\)

Can you please work me through it?
I am still struggling to get the right answer :(
 
  • #6
brunette15 said:
Can you please work me through it?
I am still struggling to get the right answer :(

First, you need to compute the first and second derivatives of the particular solution $y_p(x)$...what do you get?
 
  • #7
MarkFL said:
First, you need to compute the first and second derivatives of the particular solution $y_p(x)$...what do you get?

yp' = e2x (Ccos(x) - Dsin(x)) + e2(Csin(x) + Dcos(x))

yp'' = 2e2(Ccos(x) - Dsin(x)) + e2x(-Csin(x) - Dcos(x))

?
 
  • #8
brunette15 said:
yp' = e2x (Ccos(x) - Dsin(x)) + e2(Csin(x) + Dcos(x))

yp'' = 2e2(Ccos(x) - Dsin(x)) + e2x(-Csin(x) - Dcos(x))

?

If you post your intermediary steps, it will be easier for us to tell you where you may be going astray. :D

Okay, we begin with:

\(\displaystyle y_p(x)=e^{2x}\left(C\cos(x)+D\sin(x)\right)\)

And then using the product rule to differentiate with respect to $x$, we obtain:

\(\displaystyle y_p'(x)=e^{2x}\left(D\cos(x)-C\sin(x)\right)+2e^{2x}\left(C\cos(x)+D\sin(x)\right)\)

Factor:

\(\displaystyle y_p'(x)=e^{2x}\left(D\cos(x)-C\sin(x)+2C\cos(x)+2D\sin(x)\right)\)

Combine like terms in the second factor:

\(\displaystyle y_p'(x)=e^{2x}\left((D+2C)\cos(x)-(2D-C)\sin(x)\right)\)

This form will make things easier for you when you substitute into the ODE and when you differentiate again to get the second derivative.

Can you now compute $y_p''(x)$ and put it into the same factored/combined form? :D
 
  • #9
MarkFL said:
If you post your intermediary steps, it will be easier for us to tell you where you may be going astray. :D

Okay, we begin with:

\(\displaystyle y_p(x)=e^{2x}\left(C\cos(x)+D\sin(x)\right)\)

And then using the product rule to differentiate with respect to $x$, we obtain:

\(\displaystyle y_p'(x)=e^{2x}\left(D\cos(x)-C\sin(x)\right)+2e^{2x}\left(C\cos(x)+D\sin(x)\right)\)

Factor:

\(\displaystyle y_p'(x)=e^{2x}\left(D\cos(x)-C\sin(x)+2C\cos(x)+2D\sin(x)\right)\)

Combine like terms in the second factor:

\(\displaystyle y_p'(x)=e^{2x}\left((D+2C)\cos(x)-(2D-C)\sin(x)\right)\)

This form will make things easier for you when you substitute into the ODE and when you differentiate again to get the second derivative.

Can you now compute $y_p''(x)$ and put it into the same factored/combined form? :D

I got it now :D thankyou!
 

FAQ: Problem with finding the general solution of an ode

What is an ODE?

An ODE (ordinary differential equation) is a mathematical equation that describes the relationship between an unknown function and its derivatives. It is commonly used to model physical phenomena in fields such as physics, engineering, and biology.

What is the general solution of an ODE?

The general solution of an ODE is a formula that contains all possible solutions to the equation. It includes a set of arbitrary constants that can be adjusted to fit specific initial conditions.

Why is finding the general solution of an ODE important?

Finding the general solution of an ODE allows us to understand the behavior of the unknown function and make predictions about its values at different points. It is also an essential step in solving more complex problems that involve multiple variables and equations.

What are the methods for finding the general solution of an ODE?

The most common methods for finding the general solution of an ODE are separation of variables, integrating factors, and substitution. Other techniques, such as power series, Laplace transforms, and numerical methods, may also be used depending on the specific equation.

What are some common challenges in finding the general solution of an ODE?

One of the main challenges in finding the general solution of an ODE is determining the appropriate method to use. Some equations may require the use of multiple techniques, and choosing the wrong one can lead to incorrect solutions. Additionally, the presence of singularities or non-constant coefficients can make finding the general solution more difficult.

Similar threads

Replies
52
Views
3K
Replies
5
Views
1K
Replies
3
Views
1K
Replies
4
Views
4K
Replies
2
Views
1K
Replies
1
Views
1K
Replies
4
Views
1K
Back
Top