The general solution to this second order non-homogenous differential equation is
#y=y_h+y_p#
#y_h# is the solution to #y''-4y'+13y=0#
The caracteristic polynomial is
#r^2-4r+13=0#
The solution is
#y=(4+-sqrt(16-4*13))/(2)=2+-3i#
Therefore,
#y_h=e^(2x)(acos(3x)+bsin(3x))#
The particular solution to the equation
#y''-4y'+13y=24e^(2x)#
is of the form #y_(p1)=de^(2x)#
Therefore,
#4de^(2x)-8de^(2x)+13de^(2x)=24e^(2x)#
#9d=24#
#d=24/9=8/3#
Therefore,
#y_(p1)=8/3e^(2x)#
The particular solution to the equation
#y''-4y'+13y=sin(3x)#
is of the form #y_(p2)=fsin(3x)+gcos(3x)#
#y_(p2)'=3fcos(3x)-3gsin(3x)#
#y_(p2)''=-9fsin(3x)-9gcos(3x)#
Therefore,
#-9fsin(3x)-9gcos(3x)-4(3fcos(3x)-3gsin(3x))+13(fsin(3x)+gcos(3x))=sin(3x)#
#{(4f+12g=1),(4g-12f=0):}#
#<=>#, #{(4f+12g=1),(g=3f):}#
#<=>#, #{(f=1/40),(g=3/40):}#
Therefore,
#y_(p2)=(1/40)sin(3x)+(3/40)cos(3x)#
Putting it all together
#y=y_h+y_(p1)+y_(p2)#
#y=e^(2x)(acos(3x)+bsin(3x))+8/3e^(2x)+(1/40)sin(3x)+(3/40)cos(3x)#