diff options
Diffstat (limited to '135/CH3/EX3.29')
-rwxr-xr-x | 135/CH3/EX3.29/3_29.JPG | bin | 0 -> 19790 bytes | |||
-rwxr-xr-x | 135/CH3/EX3.29/EX29.sce | 19 |
2 files changed, 19 insertions, 0 deletions
diff --git a/135/CH3/EX3.29/3_29.JPG b/135/CH3/EX3.29/3_29.JPG Binary files differnew file mode 100755 index 000000000..4c6734a71 --- /dev/null +++ b/135/CH3/EX3.29/3_29.JPG diff --git a/135/CH3/EX3.29/EX29.sce b/135/CH3/EX3.29/EX29.sce new file mode 100755 index 000000000..27f8e6bd3 --- /dev/null +++ b/135/CH3/EX3.29/EX29.sce @@ -0,0 +1,19 @@ +// Example 3.29: Output voltage
+clc, clear
+Vy=0.5; // in volts
+Rf=50; // in ohms
+t=[0:5]; // in seconds
+vs=10*t/5; // Input voltage in volts
+// Output voltage
+for i=1:length(vs)
+ if vs(i)<6.5 then
+ // Diode is OFF
+ vo(i)=6; // in volts
+ else
+ // From Fig. 3.66(a), Diode is ON
+ I=(vs(i)-6.5)/(200+Rf+200); // in amperes
+ vo(i)=6+I*200; // in volts
+ end
+end
+plot2d(t,vo,rect=[0,0,5,8]);
+xtitle("Output voltage","t,ms","vo(t)");
\ No newline at end of file |