fortran程序运行为什么出现file not found? 20
PROGRAMMAINIMPLICITNONEINTEGERNX,NY,NZ,NRES,NFREINTEGERTTcharacter*20filenameWRITE(*,...
PROGRAM MAIN
IMPLICIT NONE
INTEGER NX,NY,NZ,NRES,NFRE
INTEGER TT
character *20 filename
WRITE(*,*)"请输入模型参数文件名"
READ(*,*)FILENAME
OPEN(15,FILE=FILENAME,STATUS='OLD',ACCESS='SEQUENTIAL',FORM='F&
ORMATTED')
READ(15,*) TT
READ(15,*) NFRE !循环计算的频点个数
READ(15,*) NX
READ(15,*) NY
READ(15,*) NZ
READ(15,*)NRES
CLOSE(15)
END PROGRAM MAIN
运行时就出现
forrtl: severe (29): file not found, unit 15, file E:\11\8
Image PC Routine Line Source
11.exe 0040A459 Unknown Unknown Unknown
11.exe 0040A2B7 Unknown Unknown Unknown
Incrementally linked image--PC correlation disabled.
fortran大神快来帮忙啊 展开
IMPLICIT NONE
INTEGER NX,NY,NZ,NRES,NFRE
INTEGER TT
character *20 filename
WRITE(*,*)"请输入模型参数文件名"
READ(*,*)FILENAME
OPEN(15,FILE=FILENAME,STATUS='OLD',ACCESS='SEQUENTIAL',FORM='F&
ORMATTED')
READ(15,*) TT
READ(15,*) NFRE !循环计算的频点个数
READ(15,*) NX
READ(15,*) NY
READ(15,*) NZ
READ(15,*)NRES
CLOSE(15)
END PROGRAM MAIN
运行时就出现
forrtl: severe (29): file not found, unit 15, file E:\11\8
Image PC Routine Line Source
11.exe 0040A459 Unknown Unknown Unknown
11.exe 0040A2B7 Unknown Unknown Unknown
Incrementally linked image--PC correlation disabled.
fortran大神快来帮忙啊 展开
1个回答
2015-05-23
展开全部
在 Fortran 中,open 时没有指定文件名的话,就会打开名为 fort.<文件号> 的文件 找找 open(1, ... 之类的语句
追问
WRITE(*,*)"请输入模型参数文件名"
READ(*,*)FILENAME
OPEN(15,FILE=FILENAME,STATUS='OLD',ACCESS='SEQUENTIAL',FORM='F&
ORMATTED')
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
启帆信息
2024-11-19 广告
2024-11-19 广告
启帆信息是英伟达中国区代理商,原厂授权代理,提供全面的软件技术解决方案以及NVIDIA以太网产品、交换机等产品,欢迎前来咨询!...
点击进入详情页
本回答由启帆信息提供
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询