Recipe: Fortran program as OPeNDAP client: Difference between revisions

Pchakrab (talk | contribs)
Pchakrab (talk | contribs)
Line 197: Line 197:
# <code>T_file</code>: Instead of reading a downloaded NetCDF-4 file, we read an OPeNDAP URL.
# <code>T_file</code>: Instead of reading a downloaded NetCDF-4 file, we read an OPeNDAP URL.
# <code>start</code>: Via the OPeNDAP URL, we can now access all time levels. The hourly <code>inst</code> files are available starting at 2005/15/15 2200z. Our desired time, 2006/09/18 0900z is then the 11772<sup>th</sup> file.
# <code>start</code>: Via the OPeNDAP URL, we can now access all time levels. The hourly <code>inst</code> files are available starting at 2005/15/15 2200z. Our desired time, 2006/09/18 0900z is then the 11772<sup>th</sup> file.
# <code>nf90_inq_varid</code>: On the OPeNDAP servers, the variables are typically lowercase (see http://opendap.nccs.nasa.gov:9090/dods/OSSE/GEOS-5.12/BETA9/0.5000_deg/inst/inst01hr_3d_T_Cv) as opposed to the file where the variables name is in uppercase. This is reflected in the call to nf90_inq_varid.
# <code>nf90_inq_varid</code>: While in the downloaded file, the temperature variable appears in the uppercase (T), on the OPeNDAP server, this variable is in lowercase (see http://opendap.nccs.nasa.gov:9090/dods/OSSE/GEOS-5.12/BETA9/0.5000_deg/inst/inst01hr_3d_T_Cv). This is reflected in the call to nf90_inq_varid.


==== Compile and run ====
==== Compile and run ====