summaryrefslogtreecommitdiff
path: root/24/CH20/EX20.1/Example20_1.sce
diff options
context:
space:
mode:
Diffstat (limited to '24/CH20/EX20.1/Example20_1.sce')
-rwxr-xr-x24/CH20/EX20.1/Example20_1.sce12
1 files changed, 12 insertions, 0 deletions
diff --git a/24/CH20/EX20.1/Example20_1.sce b/24/CH20/EX20.1/Example20_1.sce
new file mode 100755
index 000000000..3f93ad9e8
--- /dev/null
+++ b/24/CH20/EX20.1/Example20_1.sce
@@ -0,0 +1,12 @@
+//Given that
+Vi = 12 //in L
+Ti = 20+273 //in K
+Pi = 15 //in atm
+Tf = 35+273 //in K
+Vf = 8.5 //in L
+R = .0821 //in atm.lit/(mol.K)
+
+//Sample Problem 20-1
+printf("**Sample Problem 20-1**\n")
+Pf = (Pi*Vi/(R*Ti))/(Vf/(R*Tf))
+printf("The final pressure of the gas is %fatm", Pf) \ No newline at end of file