diff options
author | priyanka | 2015-06-24 15:03:17 +0530 |
---|---|---|
committer | priyanka | 2015-06-24 15:03:17 +0530 |
commit | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch) | |
tree | ab291cffc65280e58ac82470ba63fbcca7805165 /1457/CH9/EX9.2 | |
download | Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2 Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip |
initial commit / add all books
Diffstat (limited to '1457/CH9/EX9.2')
-rwxr-xr-x | 1457/CH9/EX9.2/9_2.sce | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/1457/CH9/EX9.2/9_2.sce b/1457/CH9/EX9.2/9_2.sce new file mode 100755 index 000000000..ea9cdc615 --- /dev/null +++ b/1457/CH9/EX9.2/9_2.sce @@ -0,0 +1,22 @@ +clc
+//Initialization of variables
+cv=716
+m=15 //kg
+cp=1003
+T1=20+273 //K
+k=1.4
+ratio=0.4
+//calculations
+T2=(T1)*(1/ratio)^(k-1)
+P1=95 //kN/m^2
+P2=P1*T2/(T1)/ratio
+di=cv*(T2-T1)
+dU=di*m
+dh=cp*(T2-T1)
+dH=dh*m
+//results
+printf("Final temperature = %d K",T2)
+printf("\n Final pressure = %d kN/m^2",P2)
+printf("\n Change in Internal energy = %d N m",dU)
+printf("\n Change in Enthalpy = %d Nm",dH)
+//The answers are a bit different due to rounding off error.
|