diff options
Diffstat (limited to '1382/CH1')
-rwxr-xr-x | 1382/CH1/EX1.1/ex_1_1.sce | 6 | ||||
-rwxr-xr-x | 1382/CH1/EX1.2/ex_1_2.sce | 7 | ||||
-rwxr-xr-x | 1382/CH1/EX1.3/ex_1_3.sce | 15 | ||||
-rwxr-xr-x | 1382/CH1/EX1.4/ex_1_4.sce | 7 | ||||
-rwxr-xr-x | 1382/CH1/EX1.5/ex_1_5.sce | 10 | ||||
-rwxr-xr-x | 1382/CH1/EX1.6/ex_1_6.sce | 18 | ||||
-rwxr-xr-x | 1382/CH1/EX1.7.a/ex_1_7_a.sce | 6 | ||||
-rwxr-xr-x | 1382/CH1/EX1.7.b/ex_1_7_b.sce | 5 | ||||
-rwxr-xr-x | 1382/CH1/EX1.8/ex_1_8.sce | 6 | ||||
-rwxr-xr-x | 1382/CH1/EX1.9/ex_1_9.sce | 7 |
10 files changed, 87 insertions, 0 deletions
diff --git a/1382/CH1/EX1.1/ex_1_1.sce b/1382/CH1/EX1.1/ex_1_1.sce new file mode 100755 index 000000000..aab7ce466 --- /dev/null +++ b/1382/CH1/EX1.1/ex_1_1.sce @@ -0,0 +1,6 @@ +// Example 1.1: resistance
+clc, clear
+Iz=10*10^-3; // reverse current in ampere
+Vz=0.05; // zener voltage in volts
+Rz=Vz/Iz; // resistance in ohm
+disp(Rz,"resistance (ohm) = ");
diff --git a/1382/CH1/EX1.2/ex_1_2.sce b/1382/CH1/EX1.2/ex_1_2.sce new file mode 100755 index 000000000..ba31bedc8 --- /dev/null +++ b/1382/CH1/EX1.2/ex_1_2.sce @@ -0,0 +1,7 @@ +// Example 1.2: terminal voltage
+clc, clear
+v=4.7; // in volts
+r=15; // in ohm
+i=20*10^-3; // in ampere
+Vz=(v+(i*r)); // terminal voltage in volts
+disp(Vz,"terminal voltage in volts(v)");
diff --git a/1382/CH1/EX1.3/ex_1_3.sce b/1382/CH1/EX1.3/ex_1_3.sce new file mode 100755 index 000000000..e13647a07 --- /dev/null +++ b/1382/CH1/EX1.3/ex_1_3.sce @@ -0,0 +1,15 @@ +// Example 1.3: tuning range of the circuit
+clc, clear
+C1=5*10^-12; // minimum capacitance in farad
+C2=50*10^-12; // maximum capacitance in farad
+L=10*10^-3; // in henry
+CTmin= (C1/2);//minimum total capacitance of varactor diode
+p= (sqrt(L*CTmin)); // calculating square root
+q= (2*3.14*p);
+fomax= (1/q); // maximum resonant frequency
+CTmax= ((C2*C2)/(C2+C2));//maximum total capacitance of varactor diode
+r= (sqrt(L*CTmax)); // calculating square root
+s= (2*3.14*r);
+fomin= (1/s); // minimum resonant frequency
+disp(fomax,"maximum resonant frequency in(Hz)");
+disp(fomin,"minimum resonant frequency in(Hz)");
diff --git a/1382/CH1/EX1.4/ex_1_4.sce b/1382/CH1/EX1.4/ex_1_4.sce new file mode 100755 index 000000000..56b51f9f4 --- /dev/null +++ b/1382/CH1/EX1.4/ex_1_4.sce @@ -0,0 +1,7 @@ +// Example 1.3: standard resistor
+clc, clear
+vf=1.8; // in volts
+if=16*10^-3; // in ampere
+vo=8; // in volts
+rs=(vo-vf)/if; // resistor in ohm
+disp(rs,"standard resistor (ohm) = ")
diff --git a/1382/CH1/EX1.5/ex_1_5.sce b/1382/CH1/EX1.5/ex_1_5.sce new file mode 100755 index 000000000..4ced63e97 --- /dev/null +++ b/1382/CH1/EX1.5/ex_1_5.sce @@ -0,0 +1,10 @@ +// Example 1.5: min and max value of led current
+clc, clear
+v1=1.5; // in volts
+v2=2.3; // in volts
+vs=10; // in volts
+r1=470; // in ohm
+I1=(vs-v1)/r1; // in ampere
+I2=(vs-v2)/r1; // in ampere
+disp(I1,"maximum current in ampere (A) = ")
+disp(I2,"minimum current in ampere (A) = ")
diff --git a/1382/CH1/EX1.6/ex_1_6.sce b/1382/CH1/EX1.6/ex_1_6.sce new file mode 100755 index 000000000..643e466e9 --- /dev/null +++ b/1382/CH1/EX1.6/ex_1_6.sce @@ -0,0 +1,18 @@ +// Example 1.6: which supply voltage will keep brighness of diode constant
+clc, clear
+v1=1.8; // in volts
+v2=3; // in volts
+vs=24; // in volts
+rs=820;// in ohms
+Imin=((vs-v2)/rs);//case1
+Imax=((vs-v1)/rs);
+vs1=5; // in volts
+rs1=120;// in ohms
+Imin1=((vs1-v2)/rs1);//case2
+Imax1=((vs1-v1)/rs1);
+r1=470; // in ohmI1=(vs-v1)/r1; // in ampere
+disp(Imax,"maximum current in ampere in case1(A) = ")
+disp(Imin,"minimum current in ampere in case1(A) = ")
+disp(Imax1,"maximum current in ampere in case2(A) = ")
+disp(Imin1,"minimum current in ampere in case2(A) = ")
+disp("Brightness in the first case will remain constant wheras in second case it will be changing ,therefore, in order to get an approximately constant brighntness we use as large a supply voltage as possible")
diff --git a/1382/CH1/EX1.7.a/ex_1_7_a.sce b/1382/CH1/EX1.7.a/ex_1_7_a.sce new file mode 100755 index 000000000..cec5a4fcc --- /dev/null +++ b/1382/CH1/EX1.7.a/ex_1_7_a.sce @@ -0,0 +1,6 @@ +// Example 1.7.a : photocurrent
+clc, clear
+r=0.85; // reponsivity of a photodiode in apmere per watt
+p1=1; // incident light power in milli watt
+Ip=r*p1;
+disp(Ip,"photocurrent (mA) = ")
diff --git a/1382/CH1/EX1.7.b/ex_1_7_b.sce b/1382/CH1/EX1.7.b/ex_1_7_b.sce new file mode 100755 index 000000000..04abf1bf1 --- /dev/null +++ b/1382/CH1/EX1.7.b/ex_1_7_b.sce @@ -0,0 +1,5 @@ +// Example 1.7.b : photocurrent
+clc, clear
+r=0.85; // reponsivity of a photodiode in apmere per watt
+p1=2; // incident light power in milli watt
+disp("Given input power saturation is 1.5mw so Ip is not proportional to Pop hencewe cannot find the value of photocurrent")
diff --git a/1382/CH1/EX1.8/ex_1_8.sce b/1382/CH1/EX1.8/ex_1_8.sce new file mode 100755 index 000000000..a0b4f4ba5 --- /dev/null +++ b/1382/CH1/EX1.8/ex_1_8.sce @@ -0,0 +1,6 @@ +// Example 1.8: quantum efficiency
+clc, clear
+EHP=5.4*10^6;
+photons=6*10^6;
+n=EHP/photons;
+disp(n,"quantum efficiency = ")
diff --git a/1382/CH1/EX1.9/ex_1_9.sce b/1382/CH1/EX1.9/ex_1_9.sce new file mode 100755 index 000000000..9e1f83501 --- /dev/null +++ b/1382/CH1/EX1.9/ex_1_9.sce @@ -0,0 +1,7 @@ +h=6.62*10^-34;// planc's constant
+c=3*10^8;// speed of light in vaccum
+e=0.70;//efficiency
+Eg=0.75*1.6*10^-19;// Energy gap in volts
+w=((h*c)/Eg);//wavelength in meters
+R=((e/1248)*w);// in ampere per watt
+disp (R , "Responsivity = ")
|