summaryrefslogtreecommitdiff
path: root/608/CH2/EX2.14
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /608/CH2/EX2.14
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 '608/CH2/EX2.14')
-rwxr-xr-x608/CH2/EX2.14/2_14.sce16
1 files changed, 16 insertions, 0 deletions
diff --git a/608/CH2/EX2.14/2_14.sce b/608/CH2/EX2.14/2_14.sce
new file mode 100755
index 000000000..f2c22469e
--- /dev/null
+++ b/608/CH2/EX2.14/2_14.sce
@@ -0,0 +1,16 @@
+//Problem 2.14: A 12 V battery is connected across a load having a resistance of 40ohms. Determine the current flowing in the load, the power consumed and the energy dissipated in 2 minutes.
+
+//initializing the variables:
+V = 12; // in Volts
+R = 40; // in ohms
+t = 120; // in sec
+
+//calculation:
+I = V/R
+P = I*V
+E = P*t
+
+printf("\n\nResult\n\n")
+printf("\nCurrent(I): %.1f Ampere(A)",I)
+printf("\nPower(P): %.1f Watt(W)",P)
+printf("\nEnergy(E): %.0f Joule(J)\n",E) \ No newline at end of file