summaryrefslogtreecommitdiff
path: root/3689/CH5/EX5.7/5_7.sce
diff options
context:
space:
mode:
Diffstat (limited to '3689/CH5/EX5.7/5_7.sce')
-rw-r--r--3689/CH5/EX5.7/5_7.sce22
1 files changed, 22 insertions, 0 deletions
diff --git a/3689/CH5/EX5.7/5_7.sce b/3689/CH5/EX5.7/5_7.sce
new file mode 100644
index 000000000..17be6288c
--- /dev/null
+++ b/3689/CH5/EX5.7/5_7.sce
@@ -0,0 +1,22 @@
+////
+//Variable Declaration
+n = 1.0 //Number of moles of CO2
+T = 300.0 //Temeperatures of Water bath, K
+vi = 25.0 //Initial and final state Volume of Ideal Gas, L
+vf = 10.0
+R = 8.314 //Ideal Gas Constant, J/(mol.K)
+
+//Calcualtions
+qrev = n*R*T*log(vf/vi)
+w = -qrev
+dSsys = qrev/T
+dSsur = -dSsys
+dS = dSsys + dSsur
+
+//Results
+printf("\n Entropy change of surrounding is %4.1f J/(mol.K)",dSsur)
+
+printf("\n Entropy change of system is %4.1f J/(mol.K)",dSsys)
+
+printf("\n Total Entropy change is %4.1f J/(mol.K)",dS)
+