1.出现该错误提示,以下是源代码
remark #8291: Recommended relationship between field width 'W' and the number of fractional digits 'D' in this edit descriptor is 'W>=D+7'
Do i=1,nx-1
If(mod(j,10)==0.and.mod(i,10)==0)Then
Write(TPFILE,'(a5,1x,E14.9,a1,E14.9,1x)') 'point',xx(i,j),',',yy(i,j)
Write(TPFILE,'(a4,1x,a1,1x,E14.9,a1,E14.9,1x,i2,1x,i1,1x,i3)') 'text','c',xx(i,j),',',yy(i,j),50,0,j
Endif
EndDo
程序在vs低版本可正常运行,在2022年版本出现该提示,主要原因在于数据格式定义中(EW,D)需满足(W>=D+7)
正确代码为:
Do i=1,nx-1
If(mod(j,10)==0.and.mod(i,10)==0)Then
Write(TPFILE,'(a5,1x,E16.9,a1,E16.9,1x)') 'point',xx(i,j),',',yy(i,j)
Write(TPFILE,'(a4,1x,a1,1x,E16.9,a1,E16.9,1x,i2,1x,i1,1x,i3)') 'text','c',xx(i,j),',',yy(i,j),50,0,j
Endif
EndDo