y''-2y'-3y=4e²ˣsin(x),
Solving r²-2r-3=(r-3)(r+1) gives us the general (characteristic) solution of y''-2y'-3y=0:
y=Ae³ˣ+Be⁻ˣ, where A and B are arbitrary constants.
The particular solution is probably of the form y=e²ˣ(asin(x)+bcos(x)) where a and b have to be found.
y'=e²ˣ(acos(x)-bsin(x)+2asin(x)+2bcos(x)),
y''=e²ˣ(-asin(x)-bcos(x))+2e²ˣ(acos(x)-bsin(x))+
2e²ˣ(acos(x)-bsin(x))+4e²ˣ(asin(x)+bcos(x)), so:
y''=e²ˣ(3asin(x)+3bcos(x)+4acos(x)-4bsin(x)).
Therefore, the DE becomes:
e²ˣ(3asin(x)+3bcos(x)+4acos(x)-4bsin(x))-
2e²ˣ(acos(x)-bsin(x)+2asin(x)+2bcos(x))-
3e²ˣ(asin(x)+bcos(x))=4e²ˣsin(x).
So, equating sin(x) terms:
3a-4b+2b-4a-3a=4, and equating cos(x) terms:
3b+4a-2a-4b-3b=0.
That is:
-4a-2b=4, 2a-4b=0, a=2b, -8b-2b=4, -10b=4, b=-⅖, a=-⅘.
Therefore the particular solution is y=-2e²ˣ(2sin(x)+cos(x))/5.
The complete solution is:
y=Ae³ˣ+Be⁻ˣ-2e²ˣ(2sin(x)+cos(x))/5.
The particular solution is when A=B=0.