/[lmdze]/trunk/phylmd/Mobidic/regr_pr_o3.f
ViewVC logotype

Diff of /trunk/phylmd/Mobidic/regr_pr_o3.f

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 97 by guez, Fri Apr 25 14:58:31 2014 UTC revision 254 by guez, Mon Feb 5 10:39:38 2018 UTC
# Line 22  contains Line 22  contains
22      ! We assume that, in the input file, the pressure levels are in      ! We assume that, in the input file, the pressure levels are in
23      ! hPa and strictly increasing.      ! hPa and strictly increasing.
24    
     use conf_gcm_m, only: dayref  
25      use dimens_m, only: iim, jjm, llm      use dimens_m, only: iim, jjm, llm
26        use dynetat0_m, only: day_ref
27        use grid_change, only: dyn_phy
28        use netcdf, only:  nf90_nowrite, nf90_get_var
29      use netcdf95, only: nf95_open, nf95_close, nf95_inq_varid, handle_err, &      use netcdf95, only: nf95_open, nf95_close, nf95_inq_varid, handle_err, &
30           nf95_gw_var           nf95_gw_var
     use netcdf, only:  nf90_nowrite, nf90_get_var  
31      use nr_util, only: assert      use nr_util, only: assert
     use grid_change, only: dyn_phy  
32      use numer_rec_95, only: regr1_step_av      use numer_rec_95, only: regr1_step_av
33    
34      REAL, intent(in):: p3d(:, :, :) ! (iim + 1, jjm + 1, llm+1)      REAL, intent(in):: p3d(:, :, :) ! (iim + 1, jjm + 1, llm+1)
# Line 43  contains Line 43  contains
43    
44      ! Variables local to the procedure:      ! Variables local to the procedure:
45    
46      real, pointer:: plev(:)      real, allocatable:: plev(:)
47      ! (pressure levels of Mobidic data, in Pa, in strictly increasing order)      ! (pressure levels of Mobidic data, in Pa, in strictly increasing order)
48    
49      real, allocatable:: press_in_edg(:)      real, allocatable:: press_in_edg(:)
# Line 55  contains Line 55  contains
55      integer i, j      integer i, j
56    
57      real, allocatable:: r_mob(:, :)! (jjm + 1, n_plev)      real, allocatable:: r_mob(:, :)! (jjm + 1, n_plev)
58      ! (ozone mole fraction from Mobidic at day "dayref")      ! (ozone mole fraction from Mobidic at day "day_ref")
59      ! (r_mob(j, k) is at latitude "rlatu(j)" and pressure level "plev(k)".)      ! (r_mob(j, k) is at latitude "rlatu(j)" and pressure level "plev(k)".)
60    
61      !------------------------------------------------------------      !------------------------------------------------------------
# Line 84  contains Line 84  contains
84      ! (infinity, but any value guaranteed to be greater than the      ! (infinity, but any value guaranteed to be greater than the
85      ! surface pressure would do)      ! surface pressure would do)
86    
     deallocate(plev) ! pointer  
   
87      call nf95_inq_varid(ncid, "r_Mob", varid)      call nf95_inq_varid(ncid, "r_Mob", varid)
88      allocate(r_mob(jjm + 1, n_plev))      allocate(r_mob(jjm + 1, n_plev))
89    
90      ! Get data at the right day from the input file:      ! Get data at the right day from the input file:
91      ncerr = nf90_get_var(ncid, varid, r_mob, start=(/1, 1, dayref/))      ncerr = nf90_get_var(ncid, varid, r_mob, start=(/1, 1, day_ref/))
92      call handle_err("nf90_get_var r_Mob", ncerr)      call handle_err("nf90_get_var r_Mob", ncerr)
93      ! Latitudes are in increasing order in the input file while      ! Latitudes are in increasing order in the input file while
94      ! "rlatu" is in decreasing order so we need to invert order:      ! "rlatu" is in decreasing order so we need to invert order:

Legend:
Removed from v.97  
changed lines
  Added in v.254

  ViewVC Help
Powered by ViewVC 1.1.21