summaryrefslogtreecommitdiff
path: root/147/CH1/EX1.24/Example1_24.sce
diff options
context:
space:
mode:
Diffstat (limited to '147/CH1/EX1.24/Example1_24.sce')
-rw-r--r--147/CH1/EX1.24/Example1_24.sce14
1 files changed, 14 insertions, 0 deletions
diff --git a/147/CH1/EX1.24/Example1_24.sce b/147/CH1/EX1.24/Example1_24.sce
new file mode 100644
index 000000000..07cdc106e
--- /dev/null
+++ b/147/CH1/EX1.24/Example1_24.sce
@@ -0,0 +1,14 @@
+//Voltage of battery E, Current through bd i5
+close();
+clear;
+clc;
+R1 = 10;//ohm
+R2 = 20;
+R3 = 30;
+E = 45;
+i5 = 0;
+R4 = R2*R3/R1;
+//Effective Resistance 'Re'
+Re = (R1+R2)*(R3+R4)/(R1+R2+R3+R4);
+Ibattery = E/Re;
+mprintf('(a): R4 = %0.0f ohm\n(b): Current supplied by battery, I = %0.1f A',R4,Ibattery); \ No newline at end of file