restart;
#Solution of Differential Equations using DTM-Giriraj Methi
X(0):=2;Y(0):=1; for k from 0 to 5 do X(k+1):=solve(2*(k+1)*X(k+1)+(k+1)*Y(k+1)-X(k)-Y(k)+(1)/k!,X(k+1)); Y(k+1):=solve((k+1)*X(k+1)+(k+1)*Y(k+1)+2*X(k)+Y(k)+(1)/k!,Y(k+1)); od;
IiIj
IiIi
Warning, solving for expressions other than names or functions is not recommended.
Error, (in solve) a constant is invalid as a variable, -(1/2)*Y(1)+1
JSFH