summaryrefslogtreecommitdiff
path: root/2417/CH6/EX6.31/Ex6_31.sce
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /2417/CH6/EX6.31/Ex6_31.sce
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '2417/CH6/EX6.31/Ex6_31.sce')
-rwxr-xr-x2417/CH6/EX6.31/Ex6_31.sce18
1 files changed, 18 insertions, 0 deletions
diff --git a/2417/CH6/EX6.31/Ex6_31.sce b/2417/CH6/EX6.31/Ex6_31.sce
new file mode 100755
index 000000000..3409ecb82
--- /dev/null
+++ b/2417/CH6/EX6.31/Ex6_31.sce
@@ -0,0 +1,18 @@
+clear;
+clc;
+printf("\t\t\tProblem Number 6.31\n\n\n");
+// Chapter 6: The Ideal Gas
+// Problem 6.31 (page no. 275)
+// Solution
+
+//data given
+T1=800+273; //Celsius temperature converted to Kelvin //initial temperature
+T2=500+273; //Celsius temperature converted to Kelvin //final temperature
+p2=1; //atm //absolute final pressure
+p1=5; //atm //absolute initial pressure
+//A gas expands isentropically
+//From the equation,
+//T2/T1=((p2/p1)^((k-1)/k));
+//rearranging,
+k=inv(1-((log(T2/T1)/log(p2/p1)))); //k=cp/cv //Ratio of specific heats
+printf("Ratio of specific heats (k) is %f\n",k);