USing Series solutions to solve DE (please check my work, thanks)

In summary, the homework statement is to solve the differential equation using power series. The attempt at a solution is to find y in terms of c_nx^n. The solution is y = [sum from n=0 to n=infinity]c_n x^n.
  • #1
darryw
127
0

Homework Statement


solve the DE using power series about x_0 = 0

y'' + xy' + 2y = 0

so, i want a solution in form of y = [sum from n=0 to n=infinity]c_n x^n

(i hope this makes sense, i don't know how to get summation symbol)

y = [sum from n=0 to n=infinity]c_n x^n

y' = [sum from n=0 to n=infinity]nc_n x^(n-1)

y'' = [sum from n=0 to n=infinity](n-1)n c_n x^(n-2)

then plug these values into DE..
i just need to know if i am correct so far..then i will proceed..thanks


Homework Equations





The Attempt at a Solution


 
Physics news on Phys.org
  • #2
darryw said:

Homework Statement


solve the DE using power series about x_0 = 0

y'' + xy' + 2y = 0

so, i want a solution in form of y = [sum from n=0 to n=infinity]c_n x^n

(i hope this makes sense, i don't know how to get summation symbol)

Click on the [itex]\LaTeX[/itex] image below to see the code that generated it:

[tex]y(x)=\sum_{n=0}^{\infty} c_n x^n[/tex]

And also take a look at my sig:wink:

y = [sum from n=0 to n=infinity]c_n x^n

y' = [sum from n=0 to n=infinity]nc_n x^(n-1)

y'' = [sum from n=0 to n=infinity](n-1)n c_n x^(n-2)

then plug these values into DE..
i just need to know if i am correct so far..then i will proceed..thanks

Looks fine so far...
 
  • #3
I don't understand latex at all.
I enter the exact same code and it gives me two different versions of it..

heres my example.. i want it to read x to the power of (n-1). (please look at the code)

[tex]x^n-1[/tex] (1)

so then i change it so that there's a hat after minus sign and a hat after 1,and it gives me desired symbols.

[tex]x^n^-^1[/tex] (2)

but then when i copy and paste (2) it reverts back to (1) even though it has the code for (2)
[tex]x^n^-^1[/tex] (3)

please click on the code to see what I am talking about.

I totally don't understand the logic of this.. please help.. totally new to latex. thanksEDIT: OK so i noticed that as i submitted reply it modified the code. So is previewing latex unreliable or something? ??

So just to clarify, when i was previewing the message, (3) looked just like (1) even though it had the code for (2). That sounds kinda weird but that is what was happening.. why?
 
  • #4
Just put your entire exponent (or subscript) inside curly brackets...i.e. x^{n-1} comes up as [itex]x^{n-1}[/itex]. Also, the images won't always appear properly on your screen when you preview/post them even if you've typed the code in correctly...just hit the refresh button once to see if it comes up properly.
 
  • #5
OK I've been doing some experimenting and noticed that when i preview a latex image, for some reason it shows the previous latex image rather than the one I am trying to preview. Is this normal?
for example, when i initially tried to preview the image below, it previewed x to the power of (n-1). But when i clicked submit, it shows the correct image.
?

[tex]
\sum_{n=0}^{\infty} c_n x^n^-^1
[/tex]
 
  • #6
ok thanks gabbag, ill try refresh
 
  • #7
[tex]
y(x)=\sum_{n=0}^{\infty} c_n x^n
[/tex]

[tex]
y'(x)=\sum_{n=1}^{\infty} nc_n x^{n-1}
[/tex]

[tex]
y''(x)=\sum_{n=2}^{\infty} (n-1)nc_n x^{n-2}
[/tex]

but before i insert into DE, I want all the indices (is that right word?) to match (so they all go from n=0 to infinity) so i modifiy y' and y'' to get the following:

[tex]
y'(x)=\sum_{n=1}^{\infty} nc_n x^{n-1}
[/tex]
=[tex]
=\sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n}
[/tex]

[tex]
y''(x)=\sum_{n=2}^{\infty} (n-1)nc_n x^{n-2}
[/tex]
[tex]
=\sum_{n=0}^{\infty} (n+1)(n+2)c_{n+2} x^{n}
[/tex]

then, inserting into y'' + xy' + 2y = 0, i get..

[tex]
\sum_{n=0}^{\infty} (n+1)(n+2)c_{n+2} x^{n} + (x) \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n}
+ (2) \sum_{n=0}^{\infty} c_n x^n = 0
[/tex]

combining sums and factoring out the x^n...

[tex]
\sum_{n=0}^{\infty} x^n [(n+1)(n+2)c_{n+2} + (x) (n+1)c_{n+1}
+ 2c_n] = 0
[/tex]

is this correct so far?? If so, i don't know what to do with the lone x still in the brackets. Thanks for any help
 
Last edited:
  • #8
wow latex makes it look so much nicer.. and easier to read!
 
  • #9
Careful, if [itex]n\to n+1[/itex], then [itex]c_n\to c_{n+1}[/itex]

[tex]y'(x)=\sum_{n=1}^{\infty} nc_n x^{n-1}=\sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n}[/tex]

And similar results apply to [itex]y''(x)[/itex]
 
  • #10
I edited my post #7 to reflect the changes to C_n
IS it OK now? thanks
 
  • #11
darryw said:
combining sums and factoring out the x^n...

[tex]
\sum_{n=0}^{\infty} x^n [(n+1)(n+2)c_{n+2} + (x) (n+1)c_{n+1}
+ 2c_n] = 0
[/tex]

is this correct so far?? If so, i don't know what to do with the lone x still in the brackets. Thanks for any help

Looks good to me... now use the fact that [itex]a_0+a_1x+a_2x^2+\ldots[/itex] can only be zero for all [itex]x[/itex], if all the [itex]a_n[/itex] are zero.
 
  • #12
thanks but could you elaborate a little bit on that? I think its the taylor expansion that is confusing me.. As I understand it, i thought everything in the brackets must = 0, so i would solve that equation and find what C_n is, and that is the recursive relation right?
if so, then how does that a_0 + a_1x etc fit into this?? thanks
 
  • #13
Is this valid thing i can do to the middle term
[tex]
(x) \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n}

= \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}

= \sum_{n=0}^{\infty} (n)c_{n+1} x^{n}
[/tex]

?

that way i can get rid of the lone x.
 
  • #14
darryw said:
Is this valid thing i can do to the middle term
[tex]
(x) \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n}

= \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}

= \sum_{n=0}^{\infty} (n)c_{n+1} x^{n}
[/tex]

?

that way i can get rid of the lone x.

Your first step is correct, but

[tex]\sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}=\sum_{n=1}^{\infty} nc_{n} x^{n}\neq \sum_{n=0}^{\infty} (n)c_{n+1} x^{n}[/tex]
 
  • #15
you saw x at start of equality though, right?
 
  • #16
please disregard last post...
I am confused about how the subscript of the constant relates to coefficient of constant and the powers of x.
thanks
 
  • #17
darryw said:
please disregard last post...
I am confused about how the subscript of the constant relates to coefficient of constant and the powers of x.
thanks

just plug in numbers for "n" (aka expand each sum)

[tex]\sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}=c_1x+2c_2x^2+3c_3x^3+\ldots[/tex]

and

[tex]\sum_{n=1}^{\infty} nc_{n} x^{n}=c_1x+2c_2x^2+3c_3x^3+\ldots[/tex]

so, [tex]\sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}=\sum_{n=1}^{\infty} nc_{n} x^{n}[/tex]

Or am I misunderstanding your question?
 
  • #18
OK so after the last correction I am left with:

[tex]
\sum_{n=0}^{\infty} x^n [(n+1)(n+2)c_{n+2} + nc_n + 2c_n] = 0
[/tex]

so next i should solve this equation: [tex] (n+1)(n+2)c_{n+2} + nc_n + 2c_n = 0
[/tex] for [tex]c_{n+2}[/tex], correct?
thanks
 
  • #19
that was kinda my question, but its small thing actually i think i understand that pasrt now.
but am i proceeding correctly so far (up to post #18) ? that is, next i should solve for c_n+2 ?
 
  • #20
darryw said:
OK so after the last correction I am left with:

[tex]
\sum_{n=0}^{\infty} x^n [(n+1)(n+2)c_{n+2} + nc_n + 2c_n] = 0
[/tex]

That's not quite correct. The summation in you middle term start at one, not zero. So, you should have:

[tex]\begin{aligned}0 &= \sum_{n=0}^{\infty} x^n [(n+1)(n+2)c_{n+2} + 2c_n]+\sum_{n=1}^{\infty}nc_nx^n \\ &= 2c_2+2c_0+\sum_{n=1}^{\infty} x^n [(n+1)(n+2)c_{n+2}+nc_n + 2c_n]
\end{alinged}[/tex]
 
  • #21
OK I see what you were saying s few posts ago then..
but given that one of the terms starts at n=1, wouldn't it have been better to just leave the middle term in form [tex] \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}[/tex]

i mean, if i change it to n=1, then that means i have to change the other 2 terms to match, right?
 
  • #22
darryw said:
OK I see what you were saying s few posts ago then..
but given that one of the terms starts at n=1, wouldn't it have been better to just leave the middle term in form [tex] \sum_{n=0}^{\infty} (n+1)c_{n+1} x^{n+1}[/tex]

But then your sum would have terms with both [itex]x^n[/itex] and [itex]x^{n+1}[/itex] in it and you wouldn't simply be able to compare coefficients.

i mean, if i change it to n=1, then that means i have to change the other 2 terms to match, right?

Not necessarily, you can just take out the n=0 term:

[tex]\sum_{n=0}^{\infty}a_nx^n=a_0+\sum_{n=1}^{\infty}a_nx^n[/tex]

Which is exactly what I did in my last post (that's where the [itex]2c_0+2c_2[/itex] came from).
 
  • #23
do u think there is there a mistake on this page of lecture? he never changes it to n=1.
(no big deal if u don't want to look at this) thanks
 

Attachments

  • lecturepg39.pdf
    52.2 KB · Views: 203
  • #24
Yeah, there's definitely an error in that lecture.
 
  • #25
OK so [tex]
[(n+1)(n+2)c_{n+2}+nc_n + 2c_n] = 0 [/tex]
and solve for c_n+2, correct?
if that is right, why solve for c_n+2? (why not c_n or c_n+1 for that matter?)
 
  • #26
thanks for looking at the notes
 
  • #27
darryw said:
OK so [tex]
[(n+1)(n+2)c_{n+2}+nc_n + 2c_n] = 0 [/tex]
and solve for c_n+2, correct?

Right. This is your recursion relationship. It tells you that [itex]c_2=-c_0[/itex] and [itex]c_3=-\frac{1}{2}c_1[/itex], [itex]c_4=-\frac{1}{3}c_2=\frac{1}{3}c_0[/itex] and so on...

Also, after looking again, there is no harm in saying that [tex]\sum_{n=1}^{\infty}nc_nx^n=\sum_{n=0}^{\infty}nc_nx^n[/itex], since the n=0 term is zero anyways. Your lecture is actually fine.
 
  • #28
Im going to come back to this in couple hours.. Thanks a lot for all the excellent help gabbag..
 
  • #29
Can someone please clarify something for me?
i found out that c_n+2 = -c_n / (n+1)
Is this called the "recursion relation"? also, i got a bunch of values for c_2 and c_3 and c_4 etc, by just plugging in values for n.

but how do these values equate to y = c_0 (1-x^2 + x^4/3 - x^6/5*3 + ...)

i mean what are the steps to put in in this form??
thanks for any help
 
  • #30
Well, you can express all of the odd coefficients in terms of [itex]c_1[/itex] and all the even coefficients in terms of [itex]c_0[/itex]...so you can split your sum into two (even and odd terms) and factor out [itex]c_0[/itex] from the evn sum and [itex]c_1[/itex] from the odd one...
 

Similar threads

  • Calculus and Beyond Homework Help
Replies
16
Views
435
  • Calculus and Beyond Homework Help
Replies
2
Views
297
  • Calculus and Beyond Homework Help
Replies
8
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
314
  • Calculus and Beyond Homework Help
Replies
8
Views
925
  • Calculus and Beyond Homework Help
Replies
4
Views
992
  • Calculus and Beyond Homework Help
Replies
3
Views
495
Replies
13
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
7
Views
624
Back
Top