summaryrefslogtreecommitdiff
path: root/1445/CH1/EX1.47/Ex1_47.sce
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /1445/CH1/EX1.47/Ex1_47.sce
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 '1445/CH1/EX1.47/Ex1_47.sce')
-rw-r--r--1445/CH1/EX1.47/Ex1_47.sce32
1 files changed, 32 insertions, 0 deletions
diff --git a/1445/CH1/EX1.47/Ex1_47.sce b/1445/CH1/EX1.47/Ex1_47.sce
new file mode 100644
index 000000000..9b53f1882
--- /dev/null
+++ b/1445/CH1/EX1.47/Ex1_47.sce
@@ -0,0 +1,32 @@
+//CHAPTER 1- D.C. CIRCUIT ANALYSIS AND NETWORK THEOREMS
+//Example 47
+
+disp("CHAPTER 1");
+disp("EXAMPLE 47");
+
+//VARIABLE INITIALIZATION
+lc=20; //length of copper wire in m
+dc=0.015/100; //diameter of copper wire in m
+rhoc=1.7; //specific resistance for copper
+lp=15; //length of platinum silver wire in m
+dp=0.015/100; //diameter of platinum silver wire in m
+rhop=2.43; //specific resistance for platinum silver
+
+//SOLUTION
+
+//for copper wire
+sc=(%pi/4)*(dc^2); //area
+rc=rhoc*(lc/sc);
+
+//for platinum silver
+sp=(%pi/4)*(dp^2); //area
+rp=rhop*(lp/sp);
+
+
+if(rc>rp) then
+disp("Copper wire has greater resistance");
+else
+disp("Platinum silver wire has greater resistance");
+end;
+
+//END