summaryrefslogtreecommitdiff
path: root/3831/CH8/EX8.9/Ex8_9.sce
diff options
context:
space:
mode:
Diffstat (limited to '3831/CH8/EX8.9/Ex8_9.sce')
-rw-r--r--3831/CH8/EX8.9/Ex8_9.sce20
1 files changed, 20 insertions, 0 deletions
diff --git a/3831/CH8/EX8.9/Ex8_9.sce b/3831/CH8/EX8.9/Ex8_9.sce
new file mode 100644
index 000000000..82ca4a7ae
--- /dev/null
+++ b/3831/CH8/EX8.9/Ex8_9.sce
@@ -0,0 +1,20 @@
+// Example 8_9
+clc;funcprot(0);
+// Given data
+V_2=0.0400;// m^3
+T_1=20.0;// °C
+p_1=0.0100;// MPa
+Q_12=0.100;// kJ
+V_1=0.0100;// m^3
+R=0.208;// kJ/kg.K
+T_w=400;// K
+c_p=0.523;// kJ/kg.K
+c_v=0.315;// kJ/kg.K
+
+// Calculation
+m=((p_1*10^3)*V_1)/(R*(T_1+273.15));// kg
+T_2=T_1+(Q_12/(m*c_v));// K
+p_2=(m*R*(T_2+273.15))/V_2;// kPa
+S_p12=(m*[(c_p*log((T_2+273.15)/(T_1+273.15)))-(R*log(p_2/(p_1*10^3)))])-(Q_12/T_w);// kJ/K
+S_p12=S_p12*10^3;// J/K
+printf('\nThe pressure and temperature inside the box after the balloon bursts p_2=%1.2f kPa and T_2=%3.0f°C \nThe entropy produced,1(S_P)2=%0.3f J/K',p_2,T_2,S_p12);