Clemfan
Hey all,
These are extra credit challenge problems given in my diff. equ. class, and I am in a bit of a rush to figure them out. I tried a few things, but I get lost toward the end.

Here are the problems:

1)
y'''-y''+y'-y=4sin(x)

I did long division with the homogenous equation to find the eigenvalues: 1 , +-i
I am a bit confused as to where to go from there. I need to solve to the particular and homogenous solutions and then add the two to have the general solution, because that is the method we have been working on.

Any help for #1?

2)
IVP y''+y=sec^2(x), y(0)=-1, y'(0)=0

I found eigenvalues of +-i, and got the homogenous solution of C1sin(x)+C2cos(x). Is that correct? How do you solve for the particular solution?

Thanks for the help guys!

Homework Helper
Welcome to PF!

Hey Clemfan ! Welcome to PF!

(try using the X2 tag just above the Reply box )
y'''-y''+y'-y=4sin(x)

I did long division with the homogenous equation to find the eigenvalues: 1 , +-i
I am a bit confused as to where to go from there. I need to solve to the particular and homogenous solutions and then add the two to have the general solution, because that is the method we have been working on.

That's right … use 1 and ±i to find the general solution to the homogenous equation.

For a particular solution, start by trying a trig function.

What do you get?
y''+y=sec^2(x), y(0)=-1, y'(0)=0

I found eigenvalues of +-i, and got the homogenous solution of C1sin(x)+C2cos(x). Is that correct? How do you solve for the particular solution?

Yes, your general solution to the homogenous equation is correct.

Again, try a trig function.

MATLAB gave me this.

I wouldn't blindly submit the answers from MATLAB to your teacher - he is going to wonder where they came from. At least we will have a target to aim for though.

$$-(1+t)sin(t)+tcos(t)+c_1exp(t)+c_2sin(t)+c_3cos(t)$$

$$sin(t)log((1+sin(t))/cos(t))-1$$

I am pretty sure the solution method for problem 1 is to find the characteristic and particular solutions and add them together.

The second problem is trickier.

edit: I hope no one thinks I'm lame for using a CAS :(

I think I typed in the first equation wrong.

Sorry :(

Matlab gives this now.

$$\cos\!\left(t\right)\, \left(t + \frac{\cos\!\left(2\, t\right)}{2} - \frac{\sin\!\left(2\, t\right)}{2} - \frac{1}{2}\right) - \sin\!\left(t\right) - \cos\!\left(t\right) - \sin\!\left(t\right)\, \left(t - \frac{\cos\!\left(2\, t\right)}{2} - \frac{\sin\!\left(2\, t\right)}{2} + \frac{1}{2}\right) + \mathrm{c_1}\, \cos\!\left(t\right) + \mathrm{c_2}\, \mathrm{e}^{t} + \mathrm{c_3}\, \sin\!\left(t\right)$$