C Program :
Write a prog. to calculate outlet temp and efficiency of a compressor where
to= ti(po/pi)^((g-l)/g) and e= 1-(Pi/po )^((g-1)/g)
ti- inlet temp, po,pi- outlet & inlet pressure. g=1.4
C Programming -->
/* PROG. TO FIND EFFICIENCY AND OUTLET TEMP OF COMPRESSOR */
#include<stdio.h>
#include<conio.h>
#include<math.h>
main()
{
float ti,to,pi,po,e,g=1.4;
clrscr();
printf("enter ti,pi,and po");
scanf("%f%f%f",&ti,&pi,&po);
to=ti *pow(po/pi,(g-1)/ g);
e=l-pow(pi/po,(g-1 )/g);
printf("outlet temp=%f efficiency=%f" ,to,e);
getch();
}
|