[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[netCDF #NVX-737073]: Reporting a solution: FORTRAN static/dynamic variables



> This is a report of a simple solution to  a problem - a solution that may be
> obvious to experienced netCDF programmers, but which caused us a lot of
> grief.
> 
<snip>

> Referring to simple_xy_rd.f90:
> 
> instead of
> 
> integer :: data_in(NY, NX)
> 
> use
> 
> integer,dimension(:,:), allocatable :: data_in
> allocate data_in(NY,NX)
> 

Howdy Sandy!

Thanks very much for point this out. I agree that, though technically correct 
(because of the small size of their arrays) the F90 example programs would show 
better programming style by using allocatable arrays, since these will be 
required for many users.

I have modified the F90 example programs (there are 6) to use allocatable 
arrays for all the data variables. This change will appear in the next netCDF 
daily snapshot.

Thanks!

Ed

Ticket Details
===================
Ticket ID: NVX-737073
Department: Support netCDF
Priority: Normal
Status: Closed