Dear all,
I am very confused with this error in the following code. I've searched through the forums but I could'n find an answer, even a documentation about that error. As in the title, it says:
model project I.F95(49) : error 637 - Internal compiler error - floating point exception
The code is as followed, and [color=red:8330a2d139]error is on the first DO statement[/color:8330a2d139]:
!*************************************
!*******ChE 352 Term Project 1********
!*****Dynamics of Shell and Tube******
!***********Heat Exchanger************
!****with 3-pass Shell 1-pass Tube****
!*************************************
PROGRAM TERM_PROJECT1
IMPLICIT NONE
DOUBLE PRECISION :: PI,NT,U,MT,DTUBE,A,DENS_T,CPT,CONST1,CONST2,DSHELL,DENS_S,CPS,CONSS1,CONSS2
DOUBLE PRECISION, DIMENSION(10,50000) :: T1,T2,T3,TS,ERR1,ERR2,ERR3,ERRS
DOUBLE PRECISION :: TIME,EPS,DT,DX,MS,A_TUBE,A_SHELL,A_S
INTEGER, DIMENSION(0:10) :: I
INTEGER, DIMENSION(0:50000) :: J
PRINT*, 'Enter DeltaT?'
READ*, DT
! OPEN (20,file='Temp Distribution.xls') ! Open xls file to obtain temperature distribution
PI=4.0*ATAN(1.0)
NT=300
U=840
EPS=0.005
DX=0.4
! Define tube side properties and constants of equation
MT=31.4
DTUBE=0.02
A=PI*(NT/3.0)*(DTUBE**2)/4.0
DENS_T=800
CPT=2000
CONST1=MT/(A_TUBE*DENS_T)
CONST2=NT*U*PI*DTUBE/(3.0*A*DENS_T*CPT)
! Define shel side properties and constants of equation
MS=31.4
DSHELL=0.6
A_S=PI*(DSHELL**2)/4.0-(PI*NT*DTUBE**2)/4.0
DENS_S=1500
CPS=2200
CONSS1=MS/(A_S*DENS_S)
CONSS2=NT*U*PI*DSHELL/(3.0*A_S*DENS_S*CPS)
! Set initial temperatures of tubes and shell side along the system
DO I=0,10,1
T1(I,0)=295.0
T2(I,0)=295.0
T3(I,0)=295.0
TS(I,0)=295.0
END DO
DO J=1,50000,1
TS(10,J)=420.0
END DO
DO J=0,50000,1
! Calculate the temperature of pass 1
DO I=0,8,1
T1(I,J+1)=(-1.0)*CONST1*(DT/(2*DX))*((-1.0)*3.0*(T1(I,J))+4.0*(T1(I+1,J))-T1(I+2,J))+&
(DT*CONST2)*(TS(I,J)-T1(I,J))+T1(I,J)
END DO
DO I=9,10,1
T1(I,J+1)=(-1.0)*CONST1*(DT/(2*DX))*(3.0*(T1(I,J))-4.0*(T1(I-1,J))+T1(I-2,J))+&
(DT*CONST2)*(TS(I,J)-T1(I,J))+T1(I,J)
END DO
! Application of boundary condition 3
T2(10,J)=T1(10,J)
! Calculate the temperature of pass 2
DO I=10,2,-1
T2(I,J+1)=CONST1*(DT/(2*DX))*(3.0*(T2(I,J))-4.0*(T2(I-1,J))+T2(I-2,J))+&
(DT*CONST2)*(TS(I,J)-T2(I,J))+T2(I,J)
END DO
DO I=2,0,-1
T1(I,J+1)=CONST1*(DT/(2*DX))*((-1.0)*3.0*(T1(I,J))+4.0*(T1(I+1,J))-T1(I+2,J))+&
(DT*CONST2)*(TS(I,J)-T2(I,J))+T2(I,J)
END DO
! Application of boundary condition 2
T3(0,J)=T2(0,J)
! Calculate the temperature of pass 3
DO I=0,8,1
T3(I,J+1)=(-1.0)*CONST1*(DT/(2*DX))*((-1.0)*3.0*(T3(I,J))+4.0*(T3(I+1,J))-T3(I+2,J))+&
(DT*CONST2)*(TS(I,J)-T3(I,J))+T3(I,J)
END DO
DO I=9,10,1
T3(I,J+1)=(-1.0)*CONST1*(DT/(2*DX))*(3.0*(T3(I,J))-4.0*(T3(I-1,J))+T3(I-2,J))+&
(DT*CONST2)*(TS(I,J)-T3(I,J))+T3(I,J)
END DO