summaryrefslogtreecommitdiff
path: root/62/CH7/EX7.44/ex_7_44.sce
blob: e42f88c090e1d9c9b678423565666ed72dc695d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
clc;
syms t
A=[0 -2 1;0 0 3;0 0 0];
z=A*A*A;
if z==0 then
    disp("A is a nilpotent of index 3");
else
    disp("A is not nilpotent")
end
//we know %e^(at)=b0*I+b1*A+b2*A^2; 
e=spec(A);//eigen values
b2=t^2*%e^(e(3)*t);
b1=t*%e^(e(2)*t)-b2*2*e(2);
b0=%e^(e(1)*t)-b1*e(1)-b2*e(1)^2;
eAt=b0*eye(A)+b1*A+b2*A^2;
disp(eAt,"e^(At)")