summaryrefslogtreecommitdiff
path: root/2705/CH5/EX5.14
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /2705/CH5/EX5.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 '2705/CH5/EX5.14')
-rwxr-xr-x2705/CH5/EX5.14/Ex5_14.sce54
1 files changed, 54 insertions, 0 deletions
diff --git a/2705/CH5/EX5.14/Ex5_14.sce b/2705/CH5/EX5.14/Ex5_14.sce
new file mode 100755
index 000000000..25771ce9f
--- /dev/null
+++ b/2705/CH5/EX5.14/Ex5_14.sce
@@ -0,0 +1,54 @@
+clear;
+clc;
+disp('Example 5.14');
+
+// aim : To determine the
+// (a)heat transfer
+// (b)change of internal energy
+// (c)mass of gas
+
+// Given values
+V1 = .4;// initial volume, [m^3]
+P1 = 100;// initial pressure, [kN/m^2]
+T1 = 273+20;// temperature, [K]
+P2 = 450;// final pressure,[kN/m^2]
+cp = 1.0;// [kJ/kg K]
+Gamma = 1.4; // heat capacity ratio
+
+// solution
+
+// (a)
+// for the isothermal compression,P*V=constant,so
+V2 = V1*P1/P2;// [m^3]
+W = P1*V1*log(P1/P2);// formula of workdone for isothermal process,[kJ]
+
+// for isothermal process, del_U=0;so
+Q = W;
+mprintf('\n (a) The heat transferred during compression is Q = %f kJ\n',Q);
+
+
+// (b)
+V3 = V1;
+// for adiabatic expansion
+// also
+
+P3 = P2*(V2/V3)^Gamma;// [kN/m^2]
+W = -(P3*V3-P2*V2)/(Gamma-1);// work done formula for adiabatic process,[kJ]
+// also, Q=0,so using Q=del_U+W
+del_U = -W;// [kJ]
+mprintf('\n (b) The change of the internal energy during the expansion is,del_U = %f kJ\n',del_U);
+
+// (c)
+// for ideal gas
+// cp-cv=R, and cp/cv=gamma, hence
+R = cp*(1-1/Gamma);// [kj/kg K]
+
+// now using ideal gas equation
+m = P1*V1/(R*T1);// mass of the gas,[kg]
+mprintf('\n (c) The mass of the gas is,m = %f kg\n',m);
+
+// There is calculation mistake in the book
+
+
+// End
+