From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 1151/CH8/EX8.20/example20.sce | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100755 1151/CH8/EX8.20/example20.sce (limited to '1151/CH8/EX8.20') diff --git a/1151/CH8/EX8.20/example20.sce b/1151/CH8/EX8.20/example20.sce new file mode 100755 index 000000000..de1526dd6 --- /dev/null +++ b/1151/CH8/EX8.20/example20.sce @@ -0,0 +1,19 @@ +A=[-1 0 0;0 -2 0;0 0 -3]//controlability and observebility +B=[1;1;0] +C=[1 0 2] +p=cont_mat(A,B) +disp (p," controllability matrix="); +d=det(p) +if d==0 +printf ("matrix is singular, so the system is uncontrollable"); +else +printf ("system is controllable "); +end +g= obsv_mat (A,C); +disp (g," Observability Matrix="); +i= det(g) +if i ==0 +printf ("matrix is singular, so the system is unobservable"); +else +printf (" system is observable "); +end -- cgit