diff options
author | priyanka | 2015-06-24 15:03:17 +0530 |
---|---|---|
committer | priyanka | 2015-06-24 15:03:17 +0530 |
commit | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch) | |
tree | ab291cffc65280e58ac82470ba63fbcca7805165 /2528/CH7/EX7.2/Ex7_2.sce | |
download | Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2 Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip |
initial commit / add all books
Diffstat (limited to '2528/CH7/EX7.2/Ex7_2.sce')
-rwxr-xr-x | 2528/CH7/EX7.2/Ex7_2.sce | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/2528/CH7/EX7.2/Ex7_2.sce b/2528/CH7/EX7.2/Ex7_2.sce new file mode 100755 index 000000000..722df0e5a --- /dev/null +++ b/2528/CH7/EX7.2/Ex7_2.sce @@ -0,0 +1,33 @@ +// Chapter7
+//Example-7.2
+//Figure 7.24
+//page 222
+clear;
+clc;
+R2=1.5*10^3; //in Ohm
+R1=10*10^3; //in Ohm
+Vcc=15; //in V
+Vpm=1; //in V (=Vp_)
+C=10*10^-9; //in Farad
+
+Vofst=Vcc*R2/(R1+R2);
+printf("\n Voffset %0.2f V",Vofst);
+Vc=Vofst+Vpm;
+printf("\n Vc %0.2f V",Vc);
+Rl=10*10^6; //in Ohm
+T=Rl*C; //discharge Time
+printf("\n T %0.2f S",T);
+Vinp=1.96;
+Vinm=5.96;
+Vind=Vinp-Vinm;
+printf("\n Vin_diff =%0.0f V \n ",Vind);
+//Graph
+t=(0:0.01:5)';
+f=1; //1kHz
+Vin=2*sin(f*%pi*t);
+Vin1=Vin^2-1;
+Vout=Vin1+2.96;
+clf;
+plot(t,Vout,t,Vin1)
+xtitle("Green Input signal & Blue Output signal","t","Vin");//result
+xgrid;
|