summaryrefslogtreecommitdiff
path: root/2672/CH1/EX1.21
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /2672/CH1/EX1.21
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '2672/CH1/EX1.21')
-rwxr-xr-x2672/CH1/EX1.21/Ex1_21.sce26
1 files changed, 26 insertions, 0 deletions
diff --git a/2672/CH1/EX1.21/Ex1_21.sce b/2672/CH1/EX1.21/Ex1_21.sce
new file mode 100755
index 000000000..47b23475f
--- /dev/null
+++ b/2672/CH1/EX1.21/Ex1_21.sce
@@ -0,0 +1,26 @@
+//Example 1_21
+clc;
+clear;
+close;
+format('v',5);
+//given data :
+V1=90;//V
+V2=50;//V
+V3=100;//V
+R1=60;//ohm
+R2=40;//ohm
+R3=30;//ohm
+R4=60;//ohm
+R=6:36;//ohm
+//Open circuit AB
+I1=V1/(R1+R3);//A
+I2=V3/(R2+R4);//A
+//Potential of point A
+VA=I1*R3+V2;//V
+//Potential of point B
+VB=I2*R4;//V
+VOC=VA-VB;//V
+Req=R1*R3/(R1+R3)+R2*R4/(R2+R4);//ohm
+Imin=VOC/(Req+max(R));//A
+Imax=VOC/(Req+min(R));//A
+disp("The current through resistor R will vary from "+string(Imin)+" A to "+string(Imax)+" A.");