• Support PF! Buy your school textbooks, materials and every day products Here!

Have I done this differential equation correctly?

  • Thread starter jakobs
  • Start date
  • #1
15
0

Homework Statement


This is my first big differential equation that I have solved by myself, and I wanted to see if it is correct done, or what I have done wrong with it.
Would really appreciate if somebody could take a look on it.

y''+6y'+8y=0
when y(0)=1 and y'(0)=0



The Attempt at a Solution


This is my solution
y''+6y'+8y=0
r2+6r+8=0

r=-3+- sqrt (9-8)= sqrt 1
r1= -2
r2= -4

y=Ce-2x+De-4x
y'=-2Ce-2x-4De-4x

y(0)=1 1=Ce0+De0=C+D
y'(0)=0 0=-2Ce0-4De0=-2C-4D

1=C+D
0=-2C-4D

I take 1=C+D and take -D on both sides so I get 1-D=C

I take 0=-2C-4D and take +2 on both sides so I get 2=C-4D
I now put in 1-D in it, and get 2=1-D-4D and that I can change to 3=-5D
I then take +5 on both sides and i get that 8=D

I go back to 1-D=C and I get that C=-7

I now take C and D and put them in the equation, so I get:

-7e-2x+8e-4x

Is this right, or have I made something wrong on the way?
 

Answers and Replies

  • #2
6,054
390


This is a question you can answer yourself. Just check that you solution satisfies the equation and the initial conditions.
 
  • #3
15
0


I don't wanna come across as stupid, but how do I do that?
 
  • #4
6,054
390


You have found y(x). Let x = 0, what do you get? It should be 1 as per initial conditions. Then differentiate your y(x). What is y'(0)? It should be 0 as per the conditions. Finally, differentiate that again, and plug your y, y' and y'' in the equation. Is it satisfied?
 
  • #5
vela
Staff Emeritus
Science Advisor
Homework Helper
Education Advisor
14,538
1,150
Also, since solving for C and D was a little subproblem, you should also check if your C and D satisfy the simultaneous equations. You should get in the habit of sanity-checking your work as you go.
 
  • #6
15
0
y''+6y'+8y=0
when y(0)=1 and y'(0)=0



The Attempt at a Solution


This is my solution
y''+6y'+8y=0
r2+6r+8=0

r=-3+- sqrt (9-8)= sqrt 1
r1= -2
r2= -4

y=Ce-2x+De-4x
y'=-2Ce-2x-4De-4x

y(0)=1 1=Ce0+De0=C+D
y'(0)=0 0=-2Ce0-4De0=-2C-4D

1=C+D
0=-2C-4D

I take 1=C+D and take -D on both sides so I get 1-D=C

I take 0=-2C-4D and take +2 on both sides so I get 2=C-4D
I now put in 1-D in it, and get 2=1-D-4D and that I can change to 3=-5D
I then take +5 on both sides and i get that 8=D

I go back to 1-D=C and I get that C=-7

I now take C and D and put them in the equation, so I get:

-7e-2x+8e-4x

Is this right, or have I made something wrong on the way?
I think it gets wrong after what I highlighted.
Is there someone who can explain a little bit, so I can get in the right direction of solving this one?
 
  • #7
6,054
390
You had 0 = -2C - 4D.

This somehow became 2 = C - 4D.

It is you who should explain how this is ever possible. You said "I take +2 on both sides", but that can't be it. +2 on both sides would get you 2 = -2C - 4D + 2
 
  • #8
15
0
i see it now, I thought in the wrong way, I cant take the 2 away from C.
Can I do it like this?

2*1 + 0 = 2*(C+D) - 2C - 4D ⇔ 2 = 2C - 2C + 2D - 4D ⇔ -2D = 2 ⇔ D = -1

This gives 1 = C - 1 ⇔ C = 2
 
  • #9
6,054
390
This is better. Now, check that your result satisfies the conditions of the problem.
 
  • #10
15
0
Everything adds up, it must be correct!
What a great feeling I get from seeing that it is right :)
 

Related Threads for: Have I done this differential equation correctly?

Replies
2
Views
2K
Replies
2
Views
2K
Replies
8
Views
1K
Replies
0
Views
815
  • Last Post
Replies
2
Views
1K
  • Last Post
Replies
1
Views
1K
  • Last Post
Replies
1
Views
949
Replies
2
Views
896
Top