summaryrefslogtreecommitdiff
path: root/2279/CH3/EX3.10/Ex3_10.sce
diff options
context:
space:
mode:
Diffstat (limited to '2279/CH3/EX3.10/Ex3_10.sce')
-rw-r--r--2279/CH3/EX3.10/Ex3_10.sce37
1 files changed, 37 insertions, 0 deletions
diff --git a/2279/CH3/EX3.10/Ex3_10.sce b/2279/CH3/EX3.10/Ex3_10.sce
new file mode 100644
index 000000000..08efe6700
--- /dev/null
+++ b/2279/CH3/EX3.10/Ex3_10.sce
@@ -0,0 +1,37 @@
+//Example 3.10
+clc
+clear all
+t=0:0.01:20;
+function y=signal(x)
+ y=x
+endfunction
+//Assume v(t) as ramp signal
+v1=t;
+v2=t+2;
+//Assume R=1
+i1=signal(v1)
+i2=signal(v2)
+a=2;
+b=2;
+subplot(4,2,1)
+plot(t,a*v1)
+xtitle("a*v1(t)","t in sec","a*v1(t)");
+subplot(4,2,2)
+plot(t,signal(a*v1))
+xtitle("a*i1(t)","t in sec","a*i1(t)");
+subplot(4,2,3)
+plot(t,b*v2)
+xtitle("b*v2(t)","t in sec","b*v2(t)");
+subplot(4,2,4)
+plot(t,signal(b*v2))
+xtitle("b*i2(t)","t in sec","b*i2(t)");
+c=(a*v1)+(b*v2);
+subplot(4,2,5)
+plot(t,c)
+xtitle("v3(t)","t in sec","v3(t)");
+subplot(4,2,6)
+plot(t,signal(c))
+xtitle("i3(t)","t in sec","i3(t)");
+subplot(4,2,8)
+plot(t,signal(a*v1)+signal(b*v2))
+xtitle("LINEAR SYSTEM","t in sec","a*i1(t)+b*i2(t)");