I want to numerically solve the LDE (Linear Differential Equation) by integrating it numerically according to a flow diagram (see attached file). I have tried my best to come up with a script, but it does not give the correct answer.
syms y(t) x(t) t
Dy = diff(y,t); D2y = diff(y,t,2); old = sympref ('HeavisideAtOrigin', 1);
cond = [y(0)==0, Dy(0)==0, D2y(0)==0];
eqn = diff(y,t,2) + 3*diff(y,t,1) + 2*y == heaviside(t);
ySol(t) = dsolve (eqn)