diff options
Diffstat (limited to '45/CH14/EX14.2/example_14_2.sce')
-rwxr-xr-x | 45/CH14/EX14.2/example_14_2.sce | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/45/CH14/EX14.2/example_14_2.sce b/45/CH14/EX14.2/example_14_2.sce new file mode 100755 index 000000000..3535efbe8 --- /dev/null +++ b/45/CH14/EX14.2/example_14_2.sce @@ -0,0 +1,11 @@ +//example 14.2
+clc;
+clear;
+close;
+vdc = input('Enter the value of DC voltage Vdc in volts :');
+r = input('Enter the value of resistace in K ohms :');
+//v = input(' Enter the value of voltage across diode in volts:');
+v= 1.6;
+i = (vdc-v)/r ; /// calculating the current
+ disp('The diode current in mA is :');
+ disp(i);
|