summaryrefslogtreecommitdiff
path: root/260/CH5/EX5.8/5_8.sce
diff options
context:
space:
mode:
Diffstat (limited to '260/CH5/EX5.8/5_8.sce')
-rw-r--r--260/CH5/EX5.8/5_8.sce19
1 files changed, 19 insertions, 0 deletions
diff --git a/260/CH5/EX5.8/5_8.sce b/260/CH5/EX5.8/5_8.sce
new file mode 100644
index 000000000..28bab45ab
--- /dev/null
+++ b/260/CH5/EX5.8/5_8.sce
@@ -0,0 +1,19 @@
+//Eg-5.8
+//pg-231
+
+clear
+clc
+
+A=[1 2 4;3 1 2;4 2 5];
+invA=inv(A);
+z=[1;1;1];
+for i=1:25
+ a=invA*z;
+ b=(sum(a.^2))^.5;
+ z=a/b;
+end
+
+la_d=b;
+minval=1/b;
+disp("minimum eigen value of A")
+disp(minval)