summaryrefslogtreecommitdiff
path: root/1808/CH2/EX2.4/Chapter2_Example4.sce
diff options
context:
space:
mode:
Diffstat (limited to '1808/CH2/EX2.4/Chapter2_Example4.sce')
-rw-r--r--1808/CH2/EX2.4/Chapter2_Example4.sce20
1 files changed, 20 insertions, 0 deletions
diff --git a/1808/CH2/EX2.4/Chapter2_Example4.sce b/1808/CH2/EX2.4/Chapter2_Example4.sce
new file mode 100644
index 000000000..cad029031
--- /dev/null
+++ b/1808/CH2/EX2.4/Chapter2_Example4.sce
@@ -0,0 +1,20 @@
+clc
+clear
+//INPUT DATA
+//C8H18 + 12.5 O2 + (12.5*3.76) N2 = 8 Co2 + 9 H2O + 47 N2// Stoichiometric equation for combustion of octane with 100 percent of air
+//C8H18 + 12.5 O2 + (12.5*3.76) N2 = 8 Co2 + 9 H2O + 47 N2// Stoichiometric equation for combustion of octane with 200 percent of air
+a=8;//Carbon balance
+b=9;//Hydrogen balance
+d=94;//Nitrogen balance
+c=12.5;//Oxygen balance
+
+//CALCULATIONS
+x=a+b+c+d;//Total moles of products
+x1=100*a/x;//Molal analysis of CO2
+x2=100*b/x;//Molal analysis of H20
+x3=100*c/x;//Molal analysis of O2
+x4=100*d/x;//Molal analysis of N2
+
+//OUTPUT
+printf('(i)Molal analysis of CO2 is %3.2f percentage \n (ii)Molal analysis of H2O is %3.2f percentage \n (iii)Molal analysis of O2 is %3.2f percentage \n (iv)Molal analysis of N2 is %3.2f percentage',x1,x2,x3,x4)
+