作者ihaveaids ()
看板Fortran
标题[问题] fortran当中使用netcdf
时间Fri Jan 24 17:56:15 2014
我在fortran程式中想写一些读取nc档的程式
简易程式码如下
program
use netcdf
implicit none
integer :: year=2007,doy=349,hh=2
integer :: ios
integer :: ncid,state
character(len=128) :: filename = 'flist_storm'
state = nf90_open(trim(file_pwd),nf90_nowrite, ncid)
end program
以上只是开启的程式 但compile一直没过 猜测是use netcdf这行
要把netcdf这个 moduleu一起compile
在网路上找了下面这个指令
ifort -c -I/home/mydir/netcdf/include yyyyy.f90 -o yyyyy.x
虽然有跑出执行档 但是执行时出现
-bash: ./podTec_GlobalMap.x: cannot execute binary file
有确认都是在64位元
想问问大家 fortran compilenetcdf的方法还有其他的吗
或者我用法哪里错误
谢谢
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.116.24.15
1F:推 george1224:应该还有oPTION吧。。。跟NCARGF77一样 01/24 18:46
3F:→ gilocustom:etcdf-f90/Compiling-and-Linking-with-the-NetCDF-Lib 01/24 19:09
4F:→ gilocustom:rary.html 01/24 19:09
5F:→ ihaveaids:一楼大大 那是什麽?? 二楼大大的连结跟我找的一样 01/25 12:31
6F:→ ihaveaids:但无法执行@@ 01/25 12:31
7F:推 george1224:用Z大下面的那行试看看哩? 01/27 21:31