3>Find the general solution for y” + y’=e^ x –sin(x)
5.Given that y=e ^(–x) is a solution for the differential equation xy” +(x-1) y’ – y=0,
find its general solution
First find the homogeneous solution:
yh'' + yh' = 0
The characteristic equation is:
m^2 + m = 0
m(m + 1) = 0
m = 0 or m = -1
Thus
yh(x) = A + Be^{-x}
Now for the particular solution. Since this is a linear equation we may propose a form:
yp = yp1 + yp2
where yp1 produces the -sin(x) term and yp2 produces the e^{x} term.
I would suggest trying:
yp(x) = Csin(x) + Dcos(x) + Ee^{x}
Thus
yp'(x) = Ccos(x) - Dsin(x) + Ee^{x}
yp''(x) = -Csin(x) - Dcos(x) + Ee^{x}
So
yp1'' + yp1' = (C - D)cos(x) + (-C - D)sin(x) + 2Ee^{x} = -sin(x) + e^{x}
Thus
C - D = 0
-C - D = -1
2E = 1
The top equation says D = C, so the middle equation says:
-2C = -1
Thus D = C = 1/2 so
yp(x) = 1/2 * (sin(x) + cos(x)) + e^{x}
Thus the full solution will be:
y(x) = A + Be^{-x} + 1/2 * (sin(x) + cos(x)) + 1/2 * e^{x}
Check:
y'(x) = -Be^{-x} + 1/2 *(cos(x) - sin(x)) + 1/2 * e^{x}
y''(x) = Be^{x} + 1/2 *(-sin(x) - cos(x)) + 1/2 * e^{x}
Adding these up:
y''(x) + y'(x) = -sin(x) + e^{x} (Check!)
-Dan
If I've got this right (I had to look it up. It's been a while!) This is the method.
We have one solution y1(x) = e^{-x} to this differential equation. We posit that there is another solution y2(x) = v(x)*y1(x) = e^{-x} * v(x) where v(x) is unknown at this point. So put this into the differential equation:
y2 = e^{-x}*v
y2' = -e^{-x}*v + e^{-x}*v'
y2'' = e^{-x}*v - 2e^{-x}*v' + e^{-x}*v''
So
x*[e^{-x}*v - 2e^{-x}*v' + e^{-x}*v''] + (x - 1)*[-e^{-x}*v + e^{-x}*v'] - [e^{-x}*v] = 0
Or
x*e^{-x}*v'' - (x + 1)*e^{-x}*v' = 0
x*v'' - (x + 1)v' = 0
Now reduce the order. Let z(x) = v'(x). Then:
x*z' - (x + 1)*z = 0
z' -[(x + 1)/x]z = 0
This is a first order homogeneous linear differential equation. To put it mildly, it's been studied. The general solution of z' + p(x)*z = q(x) is:
z(x) = {Int[u(x)*q(x)dx] + C}/u(x)
with u(x) = exp{Int[u(x)dx]}
Here we have p(x) = -(x + 1)/x and q(x) = 0.
u(x) = exp{-Int[(x + 1)/x dx]} = exp{-x - ln(|x|)}
u(x) = (1/|x|)*e^{-x}
So
z(x) =C*|x|*e^{x}
I'm going to do something bad so I can finish this problem. I'm going to drop the absolute value bars on x and let
z(x) = C*x*e^{x}
Then
v'(x) = z(x) = C*x*e^{x}
v(x) = C*Int[x*e^{x} dx] = C*(x - 1)*e^{x}
So
y2(x) = v(x)*e^{-x} = C*(x - 1)
You can verify that this indeed solves the given differential equation.
So the general solution of x*y'' + (x - 1)y' - y = 0 will be arbitrary constants times our two solutions:
y(x) = A*e^{-x} + B*(x - 1)
(The justification for dropping the absolute value bars is that this does generate an acceptable solution. I have no other intelligent comment about it, except that it was necessary to generate a solution.)
-Dan