summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorprashantsinalkar2019-03-05 12:22:05 +0530
committerprashantsinalkar2019-03-05 12:22:05 +0530
commit78393cafce80433241bec45bc8edb39602c4dfc7 (patch)
tree67071fcefabb00bc1216e475ac36a82386d2e0b5
parentcbed1b2e60c2db1016a99fe32389145e7c4f2cc8 (diff)
downloadScilab-TBC-Uploads-1-78393cafce80433241bec45bc8edb39602c4dfc7.tar.gz
Scilab-TBC-Uploads-1-78393cafce80433241bec45bc8edb39602c4dfc7.tar.bz2
Scilab-TBC-Uploads-1-78393cafce80433241bec45bc8edb39602c4dfc7.zip
updated the code for scilab on cloud[scilab 5.5.2]
-rwxr-xr-x887/CH4/EX4.2/4_2.sce32
1 files changed, 16 insertions, 16 deletions
diff --git a/887/CH4/EX4.2/4_2.sce b/887/CH4/EX4.2/4_2.sce
index 957d29c6f..d9c686935 100755
--- a/887/CH4/EX4.2/4_2.sce
+++ b/887/CH4/EX4.2/4_2.sce
@@ -1,16 +1,16 @@
-clc
-//ex4.3
-//Vs is a direct source
-//Circuit is in steady state prior to t=0
-//Before t=0, the inductor behaves as a short circuit ==>V(t)=0 for t<0 and i(t)=Vs/Ri for t<0
-//Before the switch opens, current circulates through Vs,R1 and the inductance and When it opens, nothing changes but the return path through R2
-//Then, a voltage appears across R2 and the inductance, causing the current to decay
-//There are no sources driving the circuit after the switch opens ==>the steady-state solution is zero for t>0
-//Hence, the solution for i(t) is given by i(t)=K*e^(-t/T) for t>0 in time constant T=L/R2
-//For current to be continuous i(0+)=(Vs/R1)=K*e^0=K ==> K=Vs/R1
-//The voltage is given by V(t)=(L*d(i(t))/dt)=-(L*Vs*e^(-t/T))/(R1*T) for t>0
-disp('Both current and voltage are 0 for t<0')
-disp('')
-disp('And for t>0:')
-disp('The expression for the current is i(t)=(Vs/R1)*e^(-t/T)')
-disp('The expression for the volatge is V(t)=-(L*Vs*e^(-t/T))/(R1*T)')
+clc
+//ex4.2
+//Vs is a direct source
+//Circuit is in steady state prior to t=0
+//Before t=0, the inductor behaves as a short circuit ==&gt;V(t)=0 for t&lt;0 and i(t)=Vs/Ri for t&lt;0
+//Before the switch opens, current circulates through Vs,R1 and the inductance and When it opens, nothing changes but the return path through R2
+//Then, a voltage appears across R2 and the inductance, causing the current to decay
+//There are no sources driving the circuit after the switch opens ==&gt;the steady-state solution is zero for t&gt;0
+//Hence, the solution for i(t) is given by i(t)=K*e^(-t/T) for t&gt;0 in time constant T=L/R2
+//For current to be continuous i(0+)=(Vs/R1)=K*e^0=K ==&gt; K=Vs/R1
+//The voltage is given by V(t)=(L*d(i(t))/dt)=-(L*Vs*e^(-t/T))/(R1*T) for t&gt;0
+disp('Both current and voltage are 0 for t&lt;0')
+disp('')
+disp('And for t&gt;0:')
+disp('The expression for the current is i(t)=(Vs/R1)*e^(-t/T)')
+disp('The expression for the volatge is V(t)=-(L*Vs*e^(-t/T))/(R1*T)') \ No newline at end of file