From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 2339/CH3/EX3.17.1/Ex3_17.sce | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100755 2339/CH3/EX3.17.1/Ex3_17.sce (limited to '2339/CH3/EX3.17.1') diff --git a/2339/CH3/EX3.17.1/Ex3_17.sce b/2339/CH3/EX3.17.1/Ex3_17.sce new file mode 100755 index 000000000..3ceec93cc --- /dev/null +++ b/2339/CH3/EX3.17.1/Ex3_17.sce @@ -0,0 +1,32 @@ +clc +clear + +//Inputs +//The Values in the program are as follows: +//Temperature in Celcius converted to Kelvin(by adding 273) +//Pressure in bar converted to kPa (by multiplying 100) +//Volume in m^3 +//Value of R,Cp and Cv in kJ/kg K +P1=1.5; +V1=3; +T1=27+273; +P2=30; +T2=60+273; +R=0.287; + +m1=(P1*100*V1)/(R*T1); +m2=(P2*100*V1)/(R*T2); + +m=m2-m1; +printf('The mass pumped: %2.2f kg',m); +printf('\n'); +V=(m*R*(17+273))/(1*100); + +printf('Volume: %2.2f m^3',V); +printf('\n'); + +T3=27+273; +P3=(T3*P2)/T2; + +printf('Final air pressure in the vessel: %2.2f bar',P3); +printf('\n'); -- cgit