/[lmdze]/trunk/Sources/phylmd/Orography/start_init_orog_m.f
ViewVC logotype

Diff of /trunk/Sources/phylmd/Orography/start_init_orog_m.f

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

trunk/libf/dyn3d/start_init_orog_m.f90 revision 3 by guez, Wed Feb 27 13:16:39 2008 UTC trunk/libf/phylmd/Orography/start_init_orog_m.f90 revision 32 by guez, Tue Apr 6 17:52:58 2010 UTC
# Line 5  MODULE start_init_orog_m Line 5  MODULE start_init_orog_m
5    
6    IMPLICIT NONE    IMPLICIT NONE
7    
8    REAL, ALLOCATABLE, SAVE:: masque(:, :) ! fraction of land (iim + 1, jjm + 1)    REAL, ALLOCATABLE, SAVE:: mask(:, :) ! fraction of land (iim + 1, jjm + 1)
9    REAL, ALLOCATABLE, SAVE:: phis(:, :) ! surface geopotential, in m2 s-2    REAL, ALLOCATABLE, SAVE:: phis(:, :) ! surface geopotential, in m2 s-2
10    
11  CONTAINS  CONTAINS
# Line 13  CONTAINS Line 13  CONTAINS
13    SUBROUTINE start_init_orog(relief, zstd_2d, zsig_2d, zgam_2d, zthe_2d, &    SUBROUTINE start_init_orog(relief, zstd_2d, zsig_2d, zgam_2d, zthe_2d, &
14         zpic_2d, zval_2d)         zpic_2d, zval_2d)
15    
16      USE ioipsl, only: flininfo, flinopen_nozoom, flinget, flinclo      USE flincom, only: flininfo, flinopen_nozoom, flinclo
17        use flinget_m, only: flinget
18      use conf_dat2d_m, only: conf_dat2d      use conf_dat2d_m, only: conf_dat2d
19      use comgeom, only: rlatu, rlonv      use comgeom, only: rlatu, rlonv
20      use dimens_m, only: iim, jjm      use dimens_m, only: iim, jjm
# Line 73  CONTAINS Line 74  CONTAINS
74      ALLOCATE(lon_rel(iml_rel, jml_rel))      ALLOCATE(lon_rel(iml_rel, jml_rel))
75      ALLOCATE(relief_hi(iml_rel, jml_rel))      ALLOCATE(relief_hi(iml_rel, jml_rel))
76    
77      CALL flinopen_nozoom(orogfname, iml_rel, jml_rel, llm_tmp, &      CALL flinopen_nozoom(iml_rel, jml_rel, llm_tmp, &
78           lon_rel, lat_rel, lev, ttm_tmp, itau, date, dt, fid)           lon_rel, lat_rel, lev, ttm_tmp, itau, date, dt, fid)
79      ! 'RELIEF': high resolution orography      ! 'RELIEF': high resolution orography
80      CALL flinget(fid, 'RELIEF', iml_rel, jml_rel, llm_tmp, ttm_tmp, 1, 1, &      CALL flinget(fid, 'RELIEF', iml_rel, jml_rel, llm_tmp, ttm_tmp, 1, 1, &
# Line 107  CONTAINS Line 108  CONTAINS
108    
109      ! Allocate the data we need to put in the interpolated fields:      ! Allocate the data we need to put in the interpolated fields:
110      ALLOCATE(phis(iim + 1, jjm + 1))      ALLOCATE(phis(iim + 1, jjm + 1))
111      ALLOCATE(masque(iim + 1, jjm + 1))      ALLOCATE(mask(iim + 1, jjm + 1))
112    
113      CALL grid_noro(lon_rad, lat_rad, relief_hi, rlonv, rlatu, phis, relief, &      CALL grid_noro(lon_rad, lat_rad, relief_hi, rlonv, rlatu, phis, relief, &
114           zstd_2d, zsig_2d, zgam_2d, zthe_2d, zpic_2d, zval_2d, masque)           zstd_2d, zsig_2d, zgam_2d, zthe_2d, zpic_2d, zval_2d, mask)
115    
116      phis(iim + 1, :) = phis(1, :)      phis(iim + 1, :) = phis(1, :)
117      phis(:, :) = phis(:, :) * 9.81      phis(:, :) = phis(:, :) * 9.81
118    
119      masque(2:, 1) = masque(1, 1) ! north pole      mask(2:, 1) = mask(1, 1) ! north pole
120      masque(2:, jjm + 1) = masque(1, jjm + 1) ! south pole      mask(2:, jjm + 1) = mask(1, jjm + 1) ! south pole
121      masque(iim + 1, 2:jjm) = masque(1, 2:jjm) ! Greenwich      mask(iim + 1, 2:jjm) = mask(1, 2:jjm) ! Greenwich
122      WHERE (masque < EPSFRA)      WHERE (mask < EPSFRA)
123         masque = 0.         mask = 0.
124      elsewhere (1. - masque < EPSFRA)      elsewhere (1. - mask < EPSFRA)
125         masque = 1.         mask = 1.
126      endwhere      endwhere
127    
128    END SUBROUTINE start_init_orog    END SUBROUTINE start_init_orog

Legend:
Removed from v.3  
changed lines
  Added in v.32

  ViewVC Help
Powered by ViewVC 1.1.21