Solution of delayed forcing function

  • Context: Undergrad 
  • Thread starter Thread starter Jag1972
  • Start date Start date
  • Tags Tags
    Function
Click For Summary
SUMMARY

The discussion focuses on solving the differential equation ##y(t)'' + 4y(t) = 7u(t-2)## using two methods: Laplace Transforms and the method of undetermined coefficients. The Laplace Transform solution is given by ##y(t) = u(t-2)(\frac {7}{4} - \frac {7}{4} cos (2(t-2))) + 2 cos (2t) + 2 sin (2t)##, while the method of undetermined coefficients yields different results for ##t \geq 2##. The discrepancy arises from using decimal approximations for coefficients instead of retaining exact expressions, which can be reconciled using trigonometric identities. The correct approach ensures both methods yield the same solution.

PREREQUISITES
  • Understanding of differential equations, specifically second-order linear equations.
  • Proficiency in Laplace Transforms and their application in solving differential equations.
  • Knowledge of the method of undetermined coefficients for finding particular solutions.
  • Familiarity with trigonometric identities and their use in simplifying expressions.
NEXT STEPS
  • Study the application of Laplace Transforms in solving non-homogeneous differential equations.
  • Learn about the method of undetermined coefficients and its limitations in certain scenarios.
  • Explore trigonometric identities and their role in simplifying solutions to differential equations.
  • Investigate the implications of initial conditions on the solutions of differential equations.
USEFUL FOR

Mathematicians, engineering students, and anyone involved in solving differential equations, particularly those interested in methods for handling non-homogeneous terms and initial conditions.

Jag1972
Messages
40
Reaction score
0
TL;DR
Compare the solution of delayed forcing function differential equation using Laplace transform and method of undermined coefficients.
Tried to figure out myself but have now admitted defeat, requesting some guidance from you good people. Not looking for any specific answers, unless the problem is my working out and not my process.

If we take the following differential equation: ##y(t)'' + 4y(t) = 7u(t-2)## and determine solution for following time range: ##\:\:0\leq t \lt \infty \: ## with initial conditions: ##y(0) = 2, \:y'(0) = 4##.

First solved using Laplace Transforms (This is the most straight forward way), this is solution calculated.

##y(t) = u(t-2)(\frac {7}{4} - \frac {7}{4} cos (2(t-2))) + 2 cos (2t) + 2 sin (2t)##

I tried to get a solution that would match this using method of undermined coefficients. This was my approach which felt intuitive to me. Determined 2 separate solutions for the following differential equations:1) ##y(t)'' + 4y(t) = 0\:\:## for range ##\:\:0\leq t \lt 2 \: ## initial conditions ##y(0) = 2, \:y'(0) = 4##.
2) ##y(t)'' + 4y(t) = 7## for range ##\:\:0\leq t \lt \infty \: ## initial conditions ##y(2) = -2.8, \:y'(2) = 0.4##.

The 2 solutions obtained were:

1) ##y(t)=2 cos(2t) + 2 sin (2t)\:\:## for range ##\:\:0\leq t \lt 2 \: ##

The initial conditions for the second solution were determine using solution 1 and its derivative. Simply replaced t with 2 in both equations.

2) ##y(t)=(2.9) cos(2t) + (3.5) sin (2t) + \frac {7}{4}\:\:## for range ##\:\:0\leq t \lt 2 \: ##

My problem is that the Laplace transform and Undermined coefficients solutions don't give same results for ##t\geq2##.

for example when ##t=3##

1) Laplace Transform

##y(t) = u(t-2)(\frac {7}{4} - \frac {7}{4} cos (2(t-2))) + 2 cos (2t) + 2 sin (2t)##

## = u(1)(\frac {7}{4} - \frac {7}{4} cos (2(1))) + 2 cos (5) + 2 sin (5)##

2) Undermined Coefficients

##y(t)=(2.9) cos(2t) + (3.5) sin (2t) + \frac {7}{4}\:\:## for range ##\:\:0\leq t \lt 2 \: ##

##-0.7836=(2.9) cos(5) + (3.5) sin (5) + \frac {7}{4}\:\:## for range ##\:\:0\leq t \lt 2 \: ##

Would appreciate any support on this.
 
Last edited:
Physics news on Phys.org
Jag1972 said:
TL;DR Summary: Compare the solution of delayed forcing function differential equation using Laplace transform and method of undermined coefficients.

Tried to figure out myself but have now admitted defeat, requesting some guidance from you good people. Not looking for any specific answers, unless the problem is my working out and not my process.

If we take the following differential equation: ##y(t)'' + 4y(t) = 7u(t-2)## and determine solution for following time range: ##\:\:0\leq t \lt \infty \: ## with initial conditions: ##y(0) = 2, \:y'(0) = 4##.

First solved using Laplace Transforms (This is the most straight forward way), this is solution calculated.

##y(t) = u(t-2)(\frac {7}{4} - \frac {7}{4} cos (2(t-2))) + 2 cos (2t) + 2 sin (2t)##

I tried to get a solution that would match this using method of undermined coefficients. This was my approach which felt intuitive to me. Determined 2 separate solutions for the following differential equations:1) ##y(t)'' + 4y(t) = 0\:\:## for range ##\:\:0\leq t \lt 2 \: ## initial conditions ##y(0) = 2, \:y'(0) = 4##.
2) ##y(t)'' + 4y(t) = 7## for range ##\:\:0\leq t \lt \infty \: ## initial conditions ##y(2) = -2.8, \:y'(2) = 0.4##.

The 2 solutions obtained were:

1) ##y(t)=2 cos(2t) + 2 sin (2t)\:\:## for range ##\:\:0\leq t \lt 2 \: ##

The initial conditions for the second solution were determine using solution 1 and its derivative. Simply replaced t with 2 in both equations.

2) ##y(t)=(2.9) cos(2t) + (3.5) sin (2t) + \frac {7}{4}\:\:## for range ##\:\:0\leq t \lt 2 \: ##

It is a mistake to use decimal approximations for the coefficients here. Instead retain the exact expressions in terms of \cos 4 and \sin 4. For <br /> y(t) = \frac74 + C\cos 2t + D\sin 2t I find \begin{split}<br /> C = 2 - \frac74 \cos 4 \\<br /> D = 2 - \frac74 \sin 4. \end{split} You can then simplify the result using the angle sum and difference formulae, <br /> \begin{split}<br /> \cos(a \pm b) &amp;= \cos a \cos b \mp \sin a \sin b, \\<br /> \sin(a \pm b) &amp;= \sin a \cos b \pm \cos a \sin b.\end{split} You should find that you get the same solution as the Laplace method.
 
Last edited:
Many thanks sir for your reply, I am working it out now. Why is it a mistake to work out the values for the coefficients
 
Jag1972 said:
Many thanks sir for your reply, I am working it out now. Why is it a mistake to work out the values for the coefficients

Keeping them as exact values means that you can apply the trigonometric identities I gave to convert your expression into that obtained by the Laplace transform method, thus showing that they are indeed equal.
 
I am a little embarrassed to ask for help again but am stuck on the mathematics part and request further guidance.
How are you getting the value for constants, C and D. Are both solutions evaluated when t = 2, as shown?

## y(t) = 2 cos (4) + 2 sin (4)## for ## \:\:0\leq t \lt2##
## y(t) = \frac {7}{4}+C cos (4) +D sin (4)## for ## \:\:2\leq t \lt \infty##

when t=2, they equal each other

## y(t) = 2 cos (4) + 2 sin (4) = \frac {7}{4}+C cos (4) +D sin (4)##

Is this how the constants were worked out?

Thank you so much in advance
 
Got the answer, however the expression for my constants is slightly different to yours, not sure why.

picking up for solution of differential equation using method of undetermined coefficients for following time range: ## 2\leq t \lt \infty##

Wrote equation and its derivative

## y =\:\:\:\:\:\:A cos(2t) + B sin(2t) + \frac{7}{4}\:\:\:\:\:\:## Equation 1
## y' = -2A sin(2t) + 2B cos(2t) \:\:\:\:\:\:\:\:\:\:\:\:## Equation 2

Multiplied Equation 1 by ## 2 sin (2t)## and equation 2 by ## cos(2t)## and added both

## \:\:\:\:2A cos(2t) sin(2t) + 2B sin^2(2t) + \frac{7}{2} sin(2t)##
## -2A sin(2t) cos(2t) + 2B cos^2(2t) ##

## 2B + \frac{7}{2} sin(2t) ## therefore ## B= -\frac{7}{4} sin (2t)##

By substituting B into Equation 2, got ##A = -\frac{7}{4} cos(2t)##

Set t = 2, this where the differential equation has non-zero input

A = -\frac{7}{4} cos(4)##
B = -\frac{7}{4} sin(4)##

The expressions obtained for unknown constants were slightly different to yours:

C = ##2 -\frac{7}{4} cos(4)##
D = ##2 -\frac{7}{4} sin(4)##

After substituting the expressions obtained for A and B into original differential equation and using trig identities got the same expression as Laplace Transform.

## y =\:\:\:\:\:\:(- \frac{7}{4} cos(4)) cos(2t) + (- \frac{7}{4} sin(4)) sin(2t) + \frac{7}{4}\:\:\:\:\:\:##
## y =\:\:\:\:\:\:- \frac{7}{4} cos(4) cos(2t) - \frac{7}{4} sin(4) sin(2t) + \frac{7}{4}\:\:\:\:\:\:##

Used product identities

## y =\:\:\:\:\:\:- \frac{7}{4} (cos(4) cos(2t) + sin(4) sin(2t) )+ \frac{7}{4}\:\:\:\:\:\:##

## y =\:\:\:\:\:\:- \frac{7}{4} (\frac{cos(2t-4)+cos(2t+4)}{2}) + (\frac{cos(2t-4)-cos(2t+4)}{2}) + \frac{7}{4}\:\:\:\:\:\:##

## y =\:\:\:\:\:\:- \frac{7}{4} (\frac{cos(2t-4)+cos(2t+4)+ cos(2t-4)-cos(2t+4)}{2}) + \frac{7}{4}\:\:\:\:\:\:##

## y =\:\:\:\:\:\:- \frac{7}{4} cos(2t-4) + \frac{7}{4}\:\:\:\:\:\:#### y =\:\:\:\:\:\: \frac{7}{4} - \frac{7}{4} cos(2(t-2)) \:\:\:\:\:\:##

This now matches my answer from Laplace transforms. The solution here only shows the function when ##t\leq2##

My question in practical terms, in order to plot function would we need to show the homogeneous solution when ##2\leq t \lt \infty## . The Laplace transform solution shows both parts summed. Does the homogeneous part actually play any part in the function when ##t\geq 2##

##y(t) = u(t-2)(\frac {7}{4} - \frac {7}{4} cos (2(t-2))) + 2 cos (2t) + 2 sin (2t)##

Should it be
##y(t) = u(t-2)(\frac {7}{4} - \frac {7}{4} cos (2(t-2))) + (u(t) - u(t - 2))(2 cos (2t) + 2 sin (2t))##

The u(t-2) on the right should now be exactly 2 should be just less than 2. Hope I have explained my question properly.
 

Similar threads

  • · Replies 11 ·
Replies
11
Views
2K
  • · Replies 3 ·
Replies
3
Views
4K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 11 ·
Replies
11
Views
4K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K