summaryrefslogtreecommitdiff
path: root/3825/CH5/EX5.2/Ex5_2.sce
diff options
context:
space:
mode:
Diffstat (limited to '3825/CH5/EX5.2/Ex5_2.sce')
-rw-r--r--3825/CH5/EX5.2/Ex5_2.sce18
1 files changed, 18 insertions, 0 deletions
diff --git a/3825/CH5/EX5.2/Ex5_2.sce b/3825/CH5/EX5.2/Ex5_2.sce
new file mode 100644
index 000000000..b4c309aa3
--- /dev/null
+++ b/3825/CH5/EX5.2/Ex5_2.sce
@@ -0,0 +1,18 @@
+clc
+P1=100 //pressure in kPa
+V1=1 //volume in metre-cube
+T1=20 //temperature in celsius
+R=8.314*10^3
+T2=60 //temperature in celsius
+N=(P1*10^3*V1)/(R*(T1+273.15))//conversion of celsius to kelvin
+mprintf("N=%fkmol\n",N)//ans ma vary due to roundoff error
+Cv=12.4717 //in kJ/kmolK
+deltaT=T2-T1
+deltaU=N*Cv*deltaT
+mprintf("DeltaU=%fkJ\n",deltaU)//ans vary due to roundoff error
+W=-deltaU
+mprintf("w=%fkJ\n",W)//ans vary due to roundoff error
+P2=P1*(T2+273.15)/(T1+273.15)//conversion of degree to kelvin
+mprintf("P2=%fkPa",P2)//ans in the textbook is wrong
+
+