- #1
FortranFreaks
- 7
- 0
We made a program for our thermo class and when we go to run it, it tells us errors were encountered but will not display what errors it has. It won't print out anything. I appreciate any help you guys have to offer.
Print *, 'Nicholas Grover / Corey Demers'
Print *, 'Thermodynamics II FORTRAN problem'
C 4/16/06
C Program Thermo
Implicit None
Real T2, T3, T5, thN, Tpe
Real Wcs, Wts, Wc, Wt, Wnet, regN, Qh, Qr
Integer rv, T4
Print *, 'Pr Temp Nreg Nth Wnet'
Print *, '============================='
Do 10 rv = 4,4,2
Do 20 T4 = 1620, 4, 360
Do 30 regN = 0,.05,19
Call Compressor(Wc,rv,Wcs)
Call Turbine(Wts,Wt,T5,rv,regN,T4)
Call HighHEX(T3,T2,T5,Tpe,Qr,Qh,regN,rv)
Wnet = Wt - Wc
thN = Wnet/Qh
Print 40, rv,T4,regN,thN,Wnet
30 Continue
20 Continue
10 Continue
40 Format(1x,F1.0,F8.0,F7.2,F6.2,F7.2)
END
C *--------------------------------------------------------------*
Subroutine Compressor(Wc,rv,Wcs)
Real Wc,T2,Wcs
Integer rv
T2=540*rv**(.4/1.4)
Wcs= .24*(540-T2)
Wc=(Wcs/.81)
END
C *--------------------------------------------------------------*
C *--------------------------------------------------------------*
Subroutine Turbine(Wts,Wt,T5,rv,regN,T4)
Real Wts,Wt,T5,dP,regN
Integer T4,rv
dP=(.5*regN)/(1-regN)
P2=rv*14.7
P4=dP+P2
P5=14.7+dP
T5=T4*(P5/P4)**(.4/1.4)
Wts=(-.24)*(T5-T4)
Wt=Wts*.87
END
C *--------------------------------------------------------------*
Subroutine HighHEX(T3,T2,T5,Tpe,Qr,Qh,regN,rv)
Real T3,T2,T5,Tpe,Qr,Qh,regN
integer rv
T2=540*rv**(.4/1.4)
T3=T2+(T5-T2)*regN
Tpe=T3+180
Qr=(-.24)*(Tpe-3060)
Qh=Qr*(-1)
END
C *---------------------------------------------------------------*
Thanks again!
Print *, 'Nicholas Grover / Corey Demers'
Print *, 'Thermodynamics II FORTRAN problem'
C 4/16/06
C Program Thermo
Implicit None
Real T2, T3, T5, thN, Tpe
Real Wcs, Wts, Wc, Wt, Wnet, regN, Qh, Qr
Integer rv, T4
Print *, 'Pr Temp Nreg Nth Wnet'
Print *, '============================='
Do 10 rv = 4,4,2
Do 20 T4 = 1620, 4, 360
Do 30 regN = 0,.05,19
Call Compressor(Wc,rv,Wcs)
Call Turbine(Wts,Wt,T5,rv,regN,T4)
Call HighHEX(T3,T2,T5,Tpe,Qr,Qh,regN,rv)
Wnet = Wt - Wc
thN = Wnet/Qh
Print 40, rv,T4,regN,thN,Wnet
30 Continue
20 Continue
10 Continue
40 Format(1x,F1.0,F8.0,F7.2,F6.2,F7.2)
END
C *--------------------------------------------------------------*
Subroutine Compressor(Wc,rv,Wcs)
Real Wc,T2,Wcs
Integer rv
T2=540*rv**(.4/1.4)
Wcs= .24*(540-T2)
Wc=(Wcs/.81)
END
C *--------------------------------------------------------------*
C *--------------------------------------------------------------*
Subroutine Turbine(Wts,Wt,T5,rv,regN,T4)
Real Wts,Wt,T5,dP,regN
Integer T4,rv
dP=(.5*regN)/(1-regN)
P2=rv*14.7
P4=dP+P2
P5=14.7+dP
T5=T4*(P5/P4)**(.4/1.4)
Wts=(-.24)*(T5-T4)
Wt=Wts*.87
END
C *--------------------------------------------------------------*
Subroutine HighHEX(T3,T2,T5,Tpe,Qr,Qh,regN,rv)
Real T3,T2,T5,Tpe,Qr,Qh,regN
integer rv
T2=540*rv**(.4/1.4)
T3=T2+(T5-T2)*regN
Tpe=T3+180
Qr=(-.24)*(Tpe-3060)
Qh=Qr*(-1)
END
C *---------------------------------------------------------------*
Thanks again!