diff options
Diffstat (limited to '172/CH12')
-rwxr-xr-x | 172/CH12/EX12.1/ex1.sce | 37 | ||||
-rwxr-xr-x | 172/CH12/EX12.2/ex2.sce | 43 | ||||
-rwxr-xr-x | 172/CH12/EX12.3/ex3.sce | 12 | ||||
-rwxr-xr-x | 172/CH12/EX12.4/ex4.sce | 13 | ||||
-rwxr-xr-x | 172/CH12/EX12.5/ex5.sce | 26 | ||||
-rwxr-xr-x | 172/CH12/EX12.6/ex6.sce | 24 | ||||
-rwxr-xr-x | 172/CH12/EX12.7/ex7.sce | 36 | ||||
-rwxr-xr-x | 172/CH12/EX12.8/ex8.sce | 36 |
8 files changed, 227 insertions, 0 deletions
diff --git a/172/CH12/EX12.1/ex1.sce b/172/CH12/EX12.1/ex1.sce new file mode 100755 index 000000000..334158848 --- /dev/null +++ b/172/CH12/EX12.1/ex1.sce @@ -0,0 +1,37 @@ +//ques1
+//Standard brayton cycle
+clc
+clear
+//1-Inlet for compressor
+//2-Exit for compressor
+//T-Temperature at a state
+//P-Pressure at a state
+T1=288.2;//K
+P2=1000;//kPa
+P1=100;//kPa
+k=1.4;
+T2=T1*(P2/P1)^(1-1/k);//K
+Cp=1.004;//Specific heat at constant pressure in kJ/kg
+wc=Cp*(T2-T1);//compressor work in kJ/kg;
+printf('Temperature T2 = %.1f K\n',T2);
+printf(' Compressor work = %.1f kJ/kg \n',wc);
+//3-Turbine Inlet
+//4-Turbine Exit
+P4=P1;
+P3=P2;
+T3=1373.2;//K
+T4=T3*(P4/P3)^(1-1/k);//K
+wt=Cp*(T3-T4);
+wnet=wt-wc;
+printf(' Temperature T3 = %.1f K\n',T3);
+printf(' Temperature T4 = %.1f K\n',T4);
+printf(' Turbine work = %.1f kJ/kg\n',wt);
+printf(' Net work = %.1f kJ/kg\n',wt-wc);
+//2-Also high temperature heat exchanger Inlet
+//3-(-do-) Exit
+qh=Cp*(T3-T2);//Heat of source in kJ/kg
+//4-high temp heat exchanger inlet
+//1-(-do-) Exit
+ql=Cp*(T4-T1);//Heat of sink in kJ/kg
+nth=wnet/qh;
+printf(' Thermal Efficiency of cycle = %.1f percent',nth*100);
\ No newline at end of file diff --git a/172/CH12/EX12.2/ex2.sce b/172/CH12/EX12.2/ex2.sce new file mode 100755 index 000000000..4c0325a98 --- /dev/null +++ b/172/CH12/EX12.2/ex2.sce @@ -0,0 +1,43 @@ +//Calculation mistake in book
+//ques2
+//Standard brayton cycle
+clc
+clear
+//Calculation mistake in book
+//1-Inlet for compressor
+//2-Exit for compressor
+//T-Temperature at a state
+//P-Pressure at a state
+T1=288.2;//K
+P2=1000;//kPa
+P1=100;//kPa
+k=1.4;
+T2s=T1*(P2/P1)^(1-1/k);//K
+nc=.80;//Compressor Efficiency
+T2=T1+(T2s-T1)/0.80;
+Cp=1.004;//Specific heat at constant pressure in kJ/kg
+wc=Cp*(T2-T1);//compressor work in kJ/kg;
+printf('Temperature T2 = %.1f K\n',T2);
+printf(' Compressor work = %.1f kJ/kg \n',wc);
+//3-Turbine Inlet
+//4-Turbine Exit
+P4=P1;
+P3=P2;
+T3=1373.2;//K
+T4s=T3*(P4/P3)^(1-1/k);//K
+nt=0.85;//turbine Efficiency
+T4=T3-(T3-T4s)*0.85;
+wt=Cp*(T3-T4);
+wnet=wt-wc;
+printf(' Temperature T3 = %.1f K\n',T3);
+printf(' Temperature T4 = %.1f K\n',T4);
+printf(' Turbine work = %.1f kJ/kg\n',wt);
+printf(' Net work = %.1f kJ/kg\n',wt-wc);
+//2-Also high temperature heat exchanger Inlet
+//3-(-do-) Exit
+qh=Cp*(T3-T2);//Heat of source in kJ/kg
+//4-high temp heat exchanger inlet
+//1-(-do-) Exit
+ql=Cp*(T4-T1);//Heat of sink in kJ/kg
+nth=wnet/qh;
+printf(' Thermal Efficiency of cycle = %.1f percent',nth*100);
\ No newline at end of file diff --git a/172/CH12/EX12.3/ex3.sce b/172/CH12/EX12.3/ex3.sce new file mode 100755 index 000000000..34e28fddb --- /dev/null +++ b/172/CH12/EX12.3/ex3.sce @@ -0,0 +1,12 @@ +//ques3
+//efficiency of the cycle
+clc
+clear
+wnet=395.2;//kJ/kg from example no 1
+//Tx=T4
+Tx=710.8;//K from example no 1
+T3=1373.2;//K from example no 1
+Cp=1.004;//specific heat in kJ/kg
+qh=Cp*(T3-Tx);
+nth=wnet/qh;
+printf('Thermal efficiency = %.1f percent',nth*100);
\ No newline at end of file diff --git a/172/CH12/EX12.4/ex4.sce b/172/CH12/EX12.4/ex4.sce new file mode 100755 index 000000000..58b5c9499 --- /dev/null +++ b/172/CH12/EX12.4/ex4.sce @@ -0,0 +1,13 @@ +//ques4
+//Calculation of work in the given cycle
+clear
+clc
+R=0.287;//gas constant
+T1=288.2;//compressor temperature K
+T2=1373.2;//K turbine temperature K
+//Pe/Pi=c=10, Pi/Pe=1/c from example 12.1
+c=10;
+wc=-R*T1*log(c);
+printf('Isothermal work in compressor = %.1f kJ/kg \n',wc);
+wt=-R*T2*log(1/c);
+printf(' Isothermal work in turbine = %.1f kJ/kg\n',wt);
\ No newline at end of file diff --git a/172/CH12/EX12.5/ex5.sce b/172/CH12/EX12.5/ex5.sce new file mode 100755 index 000000000..3d52c5815 --- /dev/null +++ b/172/CH12/EX12.5/ex5.sce @@ -0,0 +1,26 @@ +//ques5
+//air standard cycle for jet repulsion
+clear
+clc
+//1-compressor inlet
+//2-Compressor exit
+//P-Pressure at given point
+//T-Temperature at given point
+P1=100;//kPa
+P2=1000;//kPa
+T1=288.2;//K
+T2=556.8;//K
+wc=269.5;//from ex 12.1 work done in compressor in kJ/kg
+//2-Burner inlet
+//3-Burner exit
+P3=1000;//kPa
+T3=1373.2;//K
+//wc=wt
+Cp=1.004;//specific enthalpy of heat at constant pressure in kJ/kg
+k=1.4;
+T4=T3-wc/Cp;
+P4=P3*(T4/T3)^(1-1/k);
+//from s4=s5 and h4=h5+v2/2 we get
+T5=710.8//K, from second law
+v=sqrt(2*Cp*1000*(T4-T5));//m/s
+printf('Velocity of air leaving the nozel = %.0f m/s',v);
\ No newline at end of file diff --git a/172/CH12/EX12.6/ex6.sce b/172/CH12/EX12.6/ex6.sce new file mode 100755 index 000000000..8de46cb53 --- /dev/null +++ b/172/CH12/EX12.6/ex6.sce @@ -0,0 +1,24 @@ +//ques6
+//air standard refrigeration cycle
+clear
+clc
+//1-compressor inlet
+//2-compressor exit
+P1=100;//kPa
+P2=500;//kPa
+k=1.4;
+rp=P2/P1;
+cop=(rp^(1-1/k)-1)^-1;
+printf('Coefficient of performance = %.3f \n',cop);
+//3-Expander inlet
+//4-Expander exit
+P3=P2;
+P4=P1;
+T3=288.23;//K, given and fixed
+T4=T3/(P3/P4)^(1-1/k);
+T1=253.2;//K, given
+Cp=1.004;//Specific heat at cons pressure in kJ/kg
+ql=Cp*(T1-T4);//heat released in kJ/kg
+P=1//power required in kW
+ms=P/ql;//kg/s
+printf(' Rate at which the air enter the compressor = %.3f kg/s ',ms);
\ No newline at end of file diff --git a/172/CH12/EX12.7/ex7.sce b/172/CH12/EX12.7/ex7.sce new file mode 100755 index 000000000..91f621436 --- /dev/null +++ b/172/CH12/EX12.7/ex7.sce @@ -0,0 +1,36 @@ +//ques7
+//the otto cycle
+clear
+clc
+//1-compressor inlet
+//2-compressor exit
+P1=100;//kPa
+T1=288.2;//K
+R=0.287;//gas constant
+v1=R*T1/P1;//specific volume at inlet in m^3/kg
+rv=10;//compression ratio given
+k=1.4;//constant
+T2=T1*rv^(k-1);//K
+printf('Temperature at compressor exit, T2 = %.1f K \n',T2);
+P2=P1*rv^k;//kPa
+printf(' Pressure at compressor exit, P2 = %.3f MPa \n ',P2/1000);
+v2=v1/rv;//specific heat at exit in m^3/kg
+//23-heat addition process
+//q23=Cv*(T3-T2)=1800 kJ/kg given
+q23=1800;//kJ/kg heat addition, given
+Cv=0.717;//specific heat at constant volume in kJ/kg
+T3=T2+q23/Cv;//K
+printf('\n Initial Temperature during heat additon process, T3 = %.0f K \n',T3);
+P3=P2*(T3/T2);//kPa
+printf( ' Initial pressure during heat addition process, P3 = %.3f MPa \n',P3/1000);
+r=10;//k=V4/V3=P3/P4
+T4=T3*(1/r)^(k-1);
+printf(' \n Final temperature during heat addition process, T4 = %.1f K \n',T4);
+P4=P3/r^k;//kPa
+printf(' Final pressure during heat addition process, P4 = %.4f MPa \n',P4/1000);
+nth=1-1/r^k;//thermal efficiency
+printf('\n Thermal efficiency = %.1f percent \n',nth*100);
+q41=Cv*(T1-T4);///heat for process 4-1 in kJ/kg
+wnet=q23+q41;
+mep=wnet/(v1-v2);//effective mean pressure n kPa
+printf('\n Mean effective pressure = %.0f kPa \n',mep);
\ No newline at end of file diff --git a/172/CH12/EX12.8/ex8.sce b/172/CH12/EX12.8/ex8.sce new file mode 100755 index 000000000..861478b8a --- /dev/null +++ b/172/CH12/EX12.8/ex8.sce @@ -0,0 +1,36 @@ +//ques7
+//the diesel cycle
+clear
+clc
+//1-compressor inlet
+//2-compressor exit
+P1=100;//kPa
+T1=288.2;//K
+R=0.287;//gas constant
+v1=R*T1/P1;//specific volume at inlet in m^3/kg
+rv=20;//compression ratio given
+k=1.4;//constant
+T2=T1*rv^(k-1);//K
+printf('Temperature at compressor exit, T2 = %.1f K \n',T2);
+P2=P1*rv^k;//kPa
+printf(' Pressure at compressor exit, P2 = %.3f MPa \n ',P2/1000);
+v2=v1/rv;//specific heat at exit in m^3/kg
+//23-heat addition process
+//q23=Cv*(T3-T2)=1800 kJ/kg given
+q23=1800;//kJ/kg heat addition, given
+Cv=.717;
+Cp=1.004;//specific heat at constant pressure in kJ/kg
+T3=T2+q23/Cp;//K
+printf('\n Initial Temperature during heat addition process, T3 = %.0f K \n',T3);
+r=T3/T2;//T3/T2=V3/V2=r
+v3=r*v2;
+T4=T3/(v1/v3)^(k-1);
+printf(' Final temperature during heat addition process, T4 = %.0f K \n',T4);
+q41=Cv*(T1-T4);///heat for process 4-1 in kJ/kg
+wnet=q23+q41;
+mep=wnet/(v1-v2);//effective mean pressure in kPa
+qh=1800;//heat transfer in kJ/kg
+nth=wnet/qh;//thermal efficiency
+
+printf('\n Thermal efficiency = %.1f percent \n',nth*100);
+printf('\n Mean effective pressure = %.0f kPa \n',mep);
\ No newline at end of file |