summaryrefslogtreecommitdiff
path: root/692/CH2/EX2.2
diff options
context:
space:
mode:
Diffstat (limited to '692/CH2/EX2.2')
-rwxr-xr-x692/CH2/EX2.2/P2_2.sce13
1 files changed, 13 insertions, 0 deletions
diff --git a/692/CH2/EX2.2/P2_2.sce b/692/CH2/EX2.2/P2_2.sce
new file mode 100755
index 000000000..aeffc0e8d
--- /dev/null
+++ b/692/CH2/EX2.2/P2_2.sce
@@ -0,0 +1,13 @@
+//EXAMPLE 2.2 , BASIC OPERATIONS.
+clear;
+clc;
+c=[3.2 41 36 -9.5 0];
+disp(c,'c = ');
+d=[1.7 -0.5 0 0.8 1];
+disp(d,'d = ');
+w1=c.*d; //Multiplication
+disp(w1,'The product of two input vectors is =');
+w2=c+d; //addition
+disp(w2,'The addition of two input vectors is =');
+w3=3.5*c;
+disp(w3,'The scaling of first input vector is =');