From f35ea80659b6a49d1bb2ce1d7d002583f3f40947 Mon Sep 17 00:00:00 2001 From: prashantsinalkar Date: Tue, 10 Oct 2017 12:38:01 +0530 Subject: updated the code --- 914/CH7/EX7.22/ex7_22.sce | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) (limited to '914/CH7/EX7.22') diff --git a/914/CH7/EX7.22/ex7_22.sce b/914/CH7/EX7.22/ex7_22.sce index 58cd4271f..3e72f71d4 100755 --- a/914/CH7/EX7.22/ex7_22.sce +++ b/914/CH7/EX7.22/ex7_22.sce @@ -1,15 +1,16 @@ -clc; -warning("off"); -printf("\n\n example7.22 - pg321"); -// given -To=545.67; //[degR] - air temperature at beach level -betaa=-0.00357; //[degR/ft] - constant -R=1545; //[Torr*ft^3/degR*mole] - gas constant -M=29; -deltaz=25000; //[ft] -// using the equation ln(p/po)=((M)/(R*betaa))*ln(To/(To+betaa*deltaz) -p=po*exp(((M)/(R*betaa))*log(To/(To+betaa*deltaz))); -printf("\n\n p=%fTorr",p); -// using the equation T=To+betaa*deltaz -T=To+betaa*deltaz; -printf("\n\n T=%fdegR",T); +clc; +warning("off"); +printf("\n\n example7.22 - pg321"); +// given +To=545.67; //[degR] - air temperature at beach level +po = 760; //torr +betaa=-0.00357; //[degR/ft] - constant +R=1545; //[Torr*ft^3/degR*mole] - gas constant +M=29; +deltaz=25000; //[ft] +// using the equation ln(p/po)=((M)/(R*betaa))*ln(To/(To+betaa*deltaz) +p=po*exp(((M)/(R*betaa))*log(To/(To+betaa*deltaz))); +printf("\n\n p=%fTorr",p); +// using the equation T=To+betaa*deltaz +T=To+betaa*deltaz; +printf("\n\n T=%fdegR",T); \ No newline at end of file -- cgit