Ignore:
Timestamp:
Jun 18, 2022, 1:32:25 AM (2 years ago)
Author:
lguez
Message:

Use an external updated NetCDF95 library

Remove NetCDF95 from source files. We want to use an up-to-date
NetCDF95 library to read a NetCDF file containing groups, for aerosol
optical properties. It seems complicated to keep the NetCDF95 library
inside LMDZ because:

  • NetCDF95 now also needs a C compiler. I do not know how to make this work with FCM.


  • NetCDF95 cannot be compiled with the -r8 option: some specific procedures in a generic interface become identical.


  • Secondarily, we would have to change the names of files to adhere to the LMDZ standard. We are not glad to do that every time we update.


For now, we can compile using the options -include and -link of
makelmdz_fcm.

As we use an updated NetCDF95 library, we have to update some of the
calls in LMDZ. Those are the calls to nf95_inquire_variable and
nf95_gw_var which used to take a pointer argument and now take an
allocatable argument.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/branches/LMDZ_ECRad/libf/phylmd/regr_lat_time_coefoz_m.F90

    r2788 r4179  
    5555    integer n_lat! number of latitudes in the input data
    5656
    57     real, pointer:: latitude(:)
     57    real, allocatable:: latitude(:)
    5858    ! (of input data, converted to rad, sorted in strictly ascending order)
    5959
     
    6262    ! ascending order)
    6363
    64     real, pointer:: plev(:) ! pressure level of input data
     64    real, allocatable:: plev(:) ! pressure level of input data
    6565    logical desc_lat ! latitude in descending order in the input file
    6666
     
    172172    forall (j = 2:n_lat) lat_in_edg(j) = (latitude(j - 1) + latitude(j)) / 2
    173173    lat_in_edg(n_lat + 1) = pi / 2
    174     deallocate(latitude) ! pointer
     174    deallocate(latitude)
    175175
    176176    call nf95_inq_varid(ncid_in, "plev", varid)
     
    192192    call nf95_put_var(ncid_out, varid_plev, plev)
    193193
    194     deallocate(plev) ! pointer
     194    deallocate(plev)
    195195
    196196    allocate(o3_par_in(n_lat, n_plev, 12))
Note: See TracChangeset for help on using the changeset viewer.