summaryrefslogtreecommitdiff
path: root/3836/CH12
diff options
context:
space:
mode:
authorprashantsinalkar2017-10-10 12:27:19 +0530
committerprashantsinalkar2017-10-10 12:27:19 +0530
commit7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 (patch)
treedbb9e3ddb5fc829e7c5c7e6be99b2c4ba356132c /3836/CH12
parentb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (diff)
downloadScilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.gz
Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.tar.bz2
Scilab-TBC-Uploads-7f60ea012dd2524dae921a2a35adbf7ef21f2bb6.zip
initial commit / add all books
Diffstat (limited to '3836/CH12')
-rw-r--r--3836/CH12/EX12.1/Ex12_1.sce12
-rw-r--r--3836/CH12/EX12.2/Ex12_2.sce12
-rw-r--r--3836/CH12/EX12.5/Ex12_5.sce24
-rw-r--r--3836/CH12/EX12.6/Ex12_6.sce19
4 files changed, 67 insertions, 0 deletions
diff --git a/3836/CH12/EX12.1/Ex12_1.sce b/3836/CH12/EX12.1/Ex12_1.sce
new file mode 100644
index 000000000..dc818ae51
--- /dev/null
+++ b/3836/CH12/EX12.1/Ex12_1.sce
@@ -0,0 +1,12 @@
+clear
+//Initialization
+i1=8 //current in Amp
+i2=1 //current in Amp
+i3=4 //current in Amp
+
+//Calculation
+i4=i2+i3-i1 //current in Amp
+
+//Results
+printf("\n Magnitude, I4 = %d A",i4)
+
diff --git a/3836/CH12/EX12.2/Ex12_2.sce b/3836/CH12/EX12.2/Ex12_2.sce
new file mode 100644
index 000000000..d7ac33cd2
--- /dev/null
+++ b/3836/CH12/EX12.2/Ex12_2.sce
@@ -0,0 +1,12 @@
+clear
+//Initialization
+e=12 //EMF source in volt
+v1=3 //node voltage
+v3=3 //node voltage
+
+//Calculation
+v2=v1+v3-e //node voltage
+
+//Results
+printf("\n V2 = %d V",v2)
+
diff --git a/3836/CH12/EX12.5/Ex12_5.sce b/3836/CH12/EX12.5/Ex12_5.sce
new file mode 100644
index 000000000..668b0596d
--- /dev/null
+++ b/3836/CH12/EX12.5/Ex12_5.sce
@@ -0,0 +1,24 @@
+clear
+//Initialization
+r1=100 //Resistance in Ohm
+r2=200 //Resistance in Ohm
+r3=50 //Resistance in Ohm
+v1=15 //voltage source
+v2=20 //voltage source
+
+//Calculation
+//Considering 15 V as a source & replace the other voltage source by its internal resistance,
+r11=(r2*r3)*(r2+r3)**-1 //resistance in parallel
+v11=v1*(r11/(r1+r11)) //voltage
+//Considering 20 V as a source & replace the other voltage source by its internal resistance,
+r22=(r1*r3)*(r1+r3)**-1 //resistance in parallel
+v22=v2*(r22/(r2+r22)) //voltage
+
+//output of the original circuit
+v33=v11+v22
+
+
+
+//Results
+printf("\n Voltage, V = %.2f",v33)
+
diff --git a/3836/CH12/EX12.6/Ex12_6.sce b/3836/CH12/EX12.6/Ex12_6.sce
new file mode 100644
index 000000000..a8ccc8f3f
--- /dev/null
+++ b/3836/CH12/EX12.6/Ex12_6.sce
@@ -0,0 +1,19 @@
+clear
+//Initialization
+r1=10 //Resistance in Ohm
+r2=5 //Resistance in Ohm
+v2=5 //voltage source
+i=2 //current in Amp
+
+//Calculation
+//Considering 5 V as a source & replace the current source by its internal resistance,
+i1=v2*(r1+r2)**-1 //current using Ohms law
+//Considering current source & replace the voltage source by its internal resistance,
+r3=(r1*r2)*(r1+r2)**-1 //resistance in parallel
+v3=i*r3 //voltage using Ohms law
+i2=v3*r2**-1 //current using Ohms law
+i3=i1+i2 //total current
+
+//Results
+printf("\n Output Current, I = %.2f A",i3)
+