Transpose 发表于 2021-3-24 18:00
simply fortran 编译选项加上 -fcheck=all(我没有simply fortran ,用的是同为gfortran的code::blocks)
报 ...
Transpose 发表于 2021-3-24 18:15
好像是gfortran的问题,输出那个位置的n,并没有数组越界发生,用ivf运行之后没有问题,用release运行也没 ...
SUBROUTINE FUN(X,Y,A,B)
DOUBLE PRECISION X,Y,A,B
Double COMPLEX ss,ff,lamda
double COMPLEX pt,fenzi,fenmu
DOUBLE PRECISION a0,r
a0=10.0
r=5.0
ss=CMPLX(X,Y) !+(r-a0)/cp
lamda=sqrt(ss**2*(ss+2)/(1+ss))
fenzi=cosh(lamda*(r-a0))
fenmu=cosh(lamda*a0)
c pt=-0.04*(1/ss-exp(-6.25*ss)/ss)
pt=(54-58*exp(-12.5*ss)+4*exp(-125*ss))/(4500*ss**2)
WRITE(10,*)pt !NEW CODE
ff=pt*fenzi/fenmu
a= real(ff)
b= imag(ff)
! RETURN
END
忧伤 发表于 2021-3-24 20:26
[mw_shl_code=fortran,true] SUBROUTINE FUN(X,Y,A,B)
DOUBLE PRECISION X,Y,A,B
Double ...
欢迎光临 Fortran Coder (http://bbs.fcode.cn/) | Powered by Discuz! X3.2 |