Difference equations - just a little clarification wanted

  • Thread starter Thread starter Benny
  • Start date Start date
  • Tags Tags
    Difference
Click For Summary
SUMMARY

The discussion clarifies the application of the "method of undetermined coefficients" for solving linear difference equations, specifically the second-order difference equation x_{n + 2} + 4x_{n + 1} + 4x_n = n. The homogeneous solution is established as x_n = A(-2)^n + Bn(-2)^n. When the right-hand side (RHS) involves terms already present in the homogeneous solution, such as 'n', the trial function for the particular solution must be multiplied by an appropriate power of 'n' to ensure linear independence. The final general solution for the equation is x_n = A(-2)^n + Bn(-2)^n + (1/9)n - 2/15.

PREREQUISITES
  • Understanding of linear difference equations
  • Familiarity with the method of undetermined coefficients
  • Knowledge of characteristic equations and their solutions
  • Basic algebraic manipulation skills
NEXT STEPS
  • Study the method of undetermined coefficients in detail for both difference and differential equations
  • Explore the derivation and application of characteristic equations in linear difference equations
  • Practice solving various second-order difference equations with different RHS terms
  • Investigate the implications of linear independence in the context of difference equations
USEFUL FOR

Mathematicians, educators, and students specializing in difference equations, as well as anyone involved in discrete mathematics or numerical analysis.

Benny
Messages
577
Reaction score
0
Hi, I have a question regarding the solution of linear difference equations. Provided that the 'RHS' is not too complicated, will the same "method of undetermined coefficients" for differential equations work for difference equations.

For example consider the second order difference equation [tex]x_{n + 2} + 4x_{n + 1} + 4x_n = n[/tex]. The homogeneous solution should be [tex]x_n = A\left( { - 2} \right)^n + Bn\left( { - 2} \right)^n[/tex]. If this was a differential equation the trial function would be initally be y = Cx + D. But since something with an x is already in the homogeneous solution we would multiply by x^2 and the trial function would be y = Cx^3 + Dx^2. (I think that's what would be done in the method of undetermined coefficients...I usually don't use that procedure to solve DEs so I'm not entirely sure)

In the case of this difference equation the 'guess' particular solution would initially be x_n = C + Dn. But an 'n' is already in the homogeneous equation, so, generally, in such a situation would I multiply the trial function by some power of n? If so how would I decide which power of n to multiply the trial function by? Any help would be great thanks.
 
Physics news on Phys.org
Benny said:
Hi, I have a question regarding the solution of linear difference equations. Provided that the 'RHS' is not too complicated, will the same "method of undetermined coefficients" for differential equations work for difference equations.
Yes, that is exactly true.
For example consider the second order difference equation [tex]x_{n + 2} + 4x_{n + 1} + 4x_n = n[/tex]. The homogeneous solution should be [tex]x_n = A\left( { - 2} \right)^n + Bn\left( { - 2} \right)^n[/tex]. If this was a differential equation the trial function would be initally be y = Cx + D. But since something with an x is already in the homogeneous solution we would multiply by x^2 and the trial function would be y = Cx^3 + Dx^2. (I think that's what would be done in the method of undetermined coefficients...I usually don't use that procedure to solve DEs so I'm not entirely sure)
Now you've lost me. If this were the differential equation y"+ 4y'+ 4y= x, then the solution to the homogenous equation, y"+ 4y'+ 4y= 0, which has characteristic equation r2+ 4r+ 4= (r+ 2)2= 0 would be y(x)= Ce-2x+ Dxe-2x. Since the RHS, x, does NOT involve either e-2 or xe-2x, you would try a solution simply of the form y= Ax+ B. Then y'= A, y"= 0 so the equation becomes 0+4A+ 4Ax+4B= x. That is 4A= 1 and 4A+4B= 0: A= 1/4, B= -1/4. The general solution to the entire differential equation is y(x)= Ce-2x+ Dxe-2x+ (1/4)x- 1/4.
In the case of this difference equation the 'guess' particular solution would initially be x_n = C + Dn. But an 'n' is already in the homogeneous equation, so, generally, in such a situation would I multiply the trial function by some power of n? If so how would I decide which power of n to multiply the trial function by? Any help would be great thanks.
For the difference equation xn+2+ 4x1+ 4x= n,
the "homogenous" equation is xn+2+ 4x1+ 4x= 0. Its characteristic equation is r2+ 4r+ 4= (r+2)2= 0 as before so the general solution to the homogenous equation is, as you say, xn= A(-2)n+ Bn(-2)n.
If the right hand side involved (-2)n, then you would multiply by another "n": n2(-2)n. That is, to find a specific solution to xn+2+ 4xn+1+ 4xn= (-2)n, you would try a solution of the form
xn= Cn2(-2)n, Then
xn+1= C(n+1)2(-2)n+1
= -2Cn2(-2)n- 4Cn(-2)n-2A(-2)n
xn+2= C(n+2)2(-2)n+2
= 4Cn2(-2)n+ 16Cn(-2)n+ 16C(-2)n.
4xn+1= -8Cn2(-2)n-16Cn(-2)n+16A(-2)n
4xn= 4Cn2(-2)n
so the equation reduces to 8C(-2)n= (-2)n and we must have C= 1/8. The general solution to that difference equation is
xn= A(-2)n+ Bn(-2)n- (1/8)n2(-2)n = (A+ Bn- (1/8)n2)(-2)n.
However, for the equation you give: xn+2+ 4xn+1+ 4xn= n, the right hand side does NOT involve (-2)n so we would just try xn= Cn+ D. Then xn+1= Cn+ C+ D and
xn+2= Cn+ 2C+ D.
4xn+1= 4Cn+ 4C+ 4D
4xn= 4Cn
The equation becomes 9Cn+ 6C+ 5D= n so 9C= 1, 6C+ 5D= 0. C= 1/9,
D= -(6/9)/5= -2/15. The general solution to the difference equation xn+2+ 4xn+1+ 4xn= n is xn= A(-2)n+ Bn(-2)n+ (1/9)n- 2/15.
 
Last edited by a moderator:
Thanks for the clarification and extra information.
 

Similar threads

Replies
7
Views
3K
  • · Replies 7 ·
Replies
7
Views
2K
Replies
6
Views
1K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
Replies
4
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
7
Views
2K
Replies
1
Views
2K
Replies
1
Views
2K