- Timestamp:
- 2016-11-30T15:44:11+01:00 (8 years ago)
- Location:
- branches/2015/dev_r5003_MERCATOR6_CRS/NEMOGCM/NEMO/OPA_SRC
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2015/dev_r5003_MERCATOR6_CRS/NEMOGCM/NEMO/OPA_SRC/CRS/crs.F90
r7312 r7398 74 74 75 75 INTEGER, DIMENSION(:), ALLOCATABLE :: mis_crs, mie_crs, mis2_crs, mie2_crs ! starting and ending i-indices of parent subset 76 INTEGER, DIMENSION(:), ALLOCATABLE :: mjs_crs, mje_crs, mjs2_crs, mje2_crs ! starting and ending j-indices of parent subset76 INTEGER, DIMENSION(:), ALLOCATABLE :: mjs_crs, mje_crs, mjs2_crs, mje2_crs ! starting and ending j-indices of parent subset 77 77 INTEGER, DIMENSION(:), ALLOCATABLE :: mjg_crs, mig_crs 78 78 INTEGER, DIMENSION(:), ALLOCATABLE :: mi0_crs, mi1_crs, mj0_crs, mj1_crs 79 INTEGER :: mxbinctr, mybinctr! central point in grid box80 INTEGER, DIMENSION(:), ALLOCATABLE :: nlcit_crs, nlcit_full !:dimensions of every subdomain81 INTEGER, DIMENSION(:), ALLOCATABLE :: nldit_crs, nldit_full !:first, last indoor index for each i-domain82 INTEGER, DIMENSION(:), ALLOCATABLE :: nleit_crs, nleit_full !:first, last indoor index for each j-domain83 INTEGER, DIMENSION(:), ALLOCATABLE :: nimppt_crs, nimppt_full !:first, last indoor index for each j-domain84 INTEGER, DIMENSION(:), ALLOCATABLE :: nlcjt_crs, nlcjt_full !:dimensions of every subdomain85 INTEGER, DIMENSION(:), ALLOCATABLE :: nldjt_crs, nldjt_full !:first, last indoor index for each i-domain86 INTEGER, DIMENSION(:), ALLOCATABLE :: nlejt_crs, nlejt_full !:first, last indoor index for each j-domain87 INTEGER, DIMENSION(:), ALLOCATABLE :: njmppt_crs, njmppt_full !:first, last indoor index for each j-domain79 INTEGER :: mxbinctr, mybinctr ! central point in grid box 80 INTEGER, DIMENSION(:), ALLOCATABLE :: nlcit_crs, nlcit_full ! dimensions of every subdomain 81 INTEGER, DIMENSION(:), ALLOCATABLE :: nldit_crs, nldit_full ! first, last indoor index for each i-domain 82 INTEGER, DIMENSION(:), ALLOCATABLE :: nleit_crs, nleit_full ! first, last indoor index for each j-domain 83 INTEGER, DIMENSION(:), ALLOCATABLE :: nimppt_crs, nimppt_full ! first, last indoor index for each j-domain 84 INTEGER, DIMENSION(:), ALLOCATABLE :: nlcjt_crs, nlcjt_full ! dimensions of every subdomain 85 INTEGER, DIMENSION(:), ALLOCATABLE :: nldjt_crs, nldjt_full ! first, last indoor index for each i-domain 86 INTEGER, DIMENSION(:), ALLOCATABLE :: nlejt_crs, nlejt_full ! first, last indoor index for each j-domain 87 INTEGER, DIMENSION(:), ALLOCATABLE :: njmppt_crs, njmppt_full ! first, last indoor index for each j-domain 88 88 89 89 INTEGER, DIMENSION(:,:), ALLOCATABLE :: nfiimpp_full … … 94 94 REAL(wp), DIMENSION(:,:) , ALLOCATABLE,SAVE :: tmask_i_crs, rnfmsk_crs, tpol_crs, fpol_crs 95 95 96 ! REAL(wp), DIMENSION(:,:), ALLOCATABLE :: tmask_i_crs, tpol, fpol97 98 96 ! Scale factors 99 97 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1t_crs, e2t_crs, e1e2t_crs ! horizontal scale factors grid type T 100 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1u_crs, e2u_crs ! horizontal scale factors grid type U101 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1v_crs, e2v_crs ! horizontal scale factors grid type V102 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1f_crs, e2f_crs ! horizontal scale factors grid type F103 104 REAL(wp), DIMENSION(:,:) , ALLOCATABLE :: ht_0_crs98 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1u_crs, e2u_crs ! horizontal scale factors grid type U 99 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1v_crs, e2v_crs ! horizontal scale factors grid type V 100 REAL(wp), DIMENSION(:,:), ALLOCATABLE :: e1f_crs, e2f_crs ! horizontal scale factors grid type F 101 102 REAL(wp), DIMENSION(:,:) , ALLOCATABLE :: ht_0_crs 105 103 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e3t_0_crs, e3u_0_crs, e3v_0_crs, e3f_0_crs, e3w_0_crs 106 104 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e3t_max_0_crs, e3u_max_0_crs, e3v_max_0_crs, e3f_max_0_crs, e3w_max_0_crs … … 110 108 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e3t_n_crs, e3u_n_crs, e3v_n_crs, e3f_n_crs, e3w_n_crs 111 109 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e3t_a_crs, e3u_a_crs, e3v_a_crs, e3f_a_crs, e3w_a_crs 112 113 110 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e3t_max_n_crs, e3u_max_n_crs, e3v_max_n_crs, e3f_max_n_crs, e3w_max_n_crs 114 111 #endif 115 112 116 117 113 ! Surface 118 114 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e1e2w_crs, e2e3u_crs, e1e3v_crs 119 115 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: e1e2w_msk, e2e3u_msk, e1e3v_msk 120 ! vertical scale factors116 121 117 ! Coordinates 122 118 REAL(wp), DIMENSION(:,:), ALLOCATABLE,SAVE :: gphit_crs, glamt_crs, gphif_crs, glamf_crs … … 135 131 REAL(wp), DIMENSION(:,:,:), ALLOCATABLE :: crs_surfu_wgt, crs_surfv_wgt, crs_surfw_wgt, crs_volt_wgt 136 132 137 ! CRSNamelist133 ! Namelist 138 134 INTEGER :: nn_factx = 3 !: reduction factor of x-dimension of the parent grid 139 135 INTEGER :: nn_facty = 3 !: reduction factor of y-dimension of the parent grid 140 !: 1 = binning centers at equator (north fold my have artifacts)141 !: for even reduction factors, equator placed in bin biased south142 136 INTEGER :: nn_msh_crs = 1 !: Organization of mesh mask output 143 137 !: 0 = no mesh mask output … … 147 141 INTEGER :: nn_crs_kz = 0 !: type of Kz coarsening ( =0->VOL ; =1->MAX ; =2->MIN) 148 142 LOGICAL :: ln_crs_wn = .FALSE. !: coarsening wn or computation using horizontal divergence 149 LOGICAL, PUBLIC :: ln_crs_top = .FALSE.!:coarsening online for the bio143 LOGICAL, PUBLIC :: ln_crs_top = .FALSE. !:coarsening online for the bio 150 144 ! 151 INTEGER :: nrestx, nresty !: for determining odd or even reduction factor152 153 145 154 146 ! Grid reduction factors … … 156 148 REAL(wp) :: rfacty_r !: inverse of y-dim reduction factor 157 149 REAL(wp) :: rfactxy 158 159 INTEGER, DIMENSION(:) 150 INTEGER :: nrestx, nresty !: for determining odd or even reduction factor 151 INTEGER, DIMENSION(:), ALLOCATABLE :: nfactx,nfacty 160 152 161 153 … … 175 167 REAL(wp), PUBLIC, DIMENSION(:,:) , ALLOCATABLE :: fmmflx_crs 176 168 REAL(wp), PUBLIC, DIMENSION(:,:) , ALLOCATABLE :: utau_crs, vtau_crs, taum_crs 177 REAL(wp), PUBLIC, DIMENSION(:,:) , ALLOCATABLE :: rnf_crs,rnf_b_crs 169 REAL(wp), PUBLIC, DIMENSION(:,:) , ALLOCATABLE :: rnf_crs,rnf_b_crs,h_rnf_crs 170 INTEGER , PUBLIC, DIMENSION(:,:) , ALLOCATABLE :: nk_rnf_crs 178 171 REAL(wp), PUBLIC, DIMENSION(:,:,:), ALLOCATABLE :: trc_i_crs,trc_o_crs 179 172 REAL(wp), PUBLIC, DIMENSION(:,:,:), ALLOCATABLE :: sbc_trc_crs, sbc_trc_b_crs 180 173 181 REAL(wp), PUBLIC, DIMENSION(:,:,:) , ALLOCATABLE ::uslp_crs, wslpi_crs !: i_slope at U- and W-points182 REAL(wp), PUBLIC, DIMENSION(:,:,:) , ALLOCATABLE ::vslp_crs, wslpj_crs !: j-slope at V- and W-points174 REAL(wp), PUBLIC, DIMENSION(:,:,:), ALLOCATABLE :: uslp_crs, wslpi_crs !: i_slope at U- and W-points 175 REAL(wp), PUBLIC, DIMENSION(:,:,:), ALLOCATABLE :: vslp_crs, wslpj_crs !: j-slope at V- and W-points 183 176 184 177 ! Horizontal diffusion … … 315 308 & qsr_crs(jpi_crs ,jpj_crs), wndm_crs(jpi_crs,jpj_crs), utau_crs(jpi_crs,jpj_crs) , & 316 309 & vtau_crs(jpi_crs,jpj_crs), taum_crs(jpi_crs,jpj_crs), & 317 & rnf_crs (jpi_crs,jpj_crs), rnf_b_crs(jpi_crs ,jpj_crs), &310 & rnf_crs (jpi_crs,jpj_crs), rnf_b_crs(jpi_crs ,jpj_crs), nk_rnf_crs(jpi_crs ,jpj_crs), h_rnf_crs(jpi_crs ,jpj_crs), & 318 311 & emp_crs (jpi_crs,jpj_crs), emp_b_crs(jpi_crs,jpj_crs), & 319 312 & sbc_trc_crs (jpi_crs,jpj_crs,jpts), sbc_trc_b_crs(jpi_crs,jpj_crs,jpts), & -
branches/2015/dev_r5003_MERCATOR6_CRS/NEMOGCM/NEMO/OPA_SRC/CRS/crsfld.F90
r7256 r7398 15 15 USE ldftra_oce ! ocean active tracers: lateral physics 16 16 USE sbc_oce ! Surface boundary condition: ocean fields 17 USE sbcrnf 17 18 USE zdf_oce ! vertical physics: ocean fields 18 19 USE zdfddm ! vertical physics: double diffusion … … 308 309 CALL crs_dom_ope( wndm , 'SUM', 'T', tmask, wndm_crs , p_e12=e1e2t, p_surf_crs=e1e2t_crs, psgn=1.0 ) 309 310 CALL crs_dom_ope( rnf , 'MAX', 'T', tmask, rnf_crs , psgn=1.0 ) 311 CALL crs_dom_ope( h_rnf, 'MAX', 'T', tmask, h_rnf_crs , psgn=1.0 ) 312 313 z2d=REAL(nk_rnf,wp) 314 CALL crs_dom_ope( z2d , 'MAX', 'T', tmask, z2d_crs , p_e12=e1e2t, p_surf_crs=e1e2t_crs, psgn=1.0 ) 315 nk_rnf_crs=INT(z2d_crs) 316 310 317 CALL crs_dom_ope( qsr , 'SUM', 'T', tmask, qsr_crs , p_e12=e1e2t, p_surf_crs=e1e2t_crs, psgn=1.0 ) 311 318 #if defined key_vvl -
branches/2015/dev_r5003_MERCATOR6_CRS/NEMOGCM/NEMO/OPA_SRC/CRS/crsini.F90
r7320 r7398 237 237 WHERE(e3v_max_0_crs == 0._wp) e3v_max_0_crs=r_inf 238 238 WHERE(e3w_max_0_crs == 0._wp) e3w_max_0_crs=r_inf 239 DO jk = 1, jpk 240 DO ji = 1, jpi_crs 241 DO jj = 1, jpj_crs 242 IF( e3t_max_0_crs(ji,jj,jk) == 0._wp ) e3t_max_0_crs(ji,jj,jk) = e3t_1d(jk) 243 IF( e3w_max_0_crs(ji,jj,jk) == 0._wp ) e3w_max_0_crs(ji,jj,jk) = e3w_1d(jk) 244 IF( e3u_max_0_crs(ji,jj,jk) == 0._wp ) e3u_max_0_crs(ji,jj,jk) = e3t_1d(jk) 245 IF( e3v_max_0_crs(ji,jj,jk) == 0._wp ) e3v_max_0_crs(ji,jj,jk) = e3t_1d(jk) 246 ENDDO 247 ENDDO 248 ENDDO 239 249 240 250 #if defined key_vvl … … 290 300 CALL crs_dom_ope( gdept_0, 'MAX', 'T', tmask, gdept_0_crs, p_e3=zfse3t, psgn=1.0 ) 291 301 CALL crs_dom_ope( gdepw_0, 'MAX', 'W', tmask, gdepw_0_crs, p_e3=zfse3w, psgn=1.0 ) 302 303 DO jk = 1, jpk 304 DO ji = 1, jpi_crs 305 DO jj = 1, jpj_crs 306 IF( gdept_0_crs(ji,jj,jk) .LE. 0._wp ) gdept_0_crs(ji,jj,jk) = gdept_1d(jk) 307 IF( gdepw_0_crs(ji,jj,jk) .LE. 0._wp ) gdepw_0_crs(ji,jj,jk) = gdepw_1d(jk) 308 ENDDO 309 ENDDO 310 ENDDO 311 292 312 #if defined key_vvl 293 313 gdept_n_crs(:,:,:) = gdept_0_crs(:,:,:) -
branches/2015/dev_r5003_MERCATOR6_CRS/NEMOGCM/NEMO/OPA_SRC/IOM/iom.F90
r7256 r7398 50 50 USE ioipsl, ONLY : ju2ymds ! for calendar 51 51 USE crs ! Grid coarsening 52 USE crslbclnk 52 53 53 54 IMPLICIT NONE … … 823 824 jstartrow = MAX(1,jstartrow) 824 825 ENDIF 825 istart(1:2) = (/ mig(1), mjg(1) + jstartrow - 1 /) ! icnt(1:2) done below 826 IF( lk_crs .AND. jpi == jpi_crs .AND. jpi .NE. 0 )THEN 827 istart(1:2) = (/ mig_crs(1), mjg_crs(1) + jstartrow - 1 /) ! icnt(1:2) done below 828 ELSE 829 istart(1:2) = (/ mig(1), mjg(1) + jstartrow - 1 /) ! icnt(1:2) done below 830 ENDIF 826 831 ELSEIF( idom == jpdom_global ) THEN ; istart(1:2) = (/ nimpp , njmpp /) ! icnt(1:2) done below 827 832 ENDIF … … 922 927 !--- overlap areas and extra hallows (mpp) 923 928 IF( PRESENT(pv_r2d) .AND. idom /= jpdom_unknown ) THEN 924 CALL lbc_lnk( pv_r2d,'Z',-999.,'no0' ) 929 IF( lk_crs .AND. jpi == jpi_crs .AND. jpi .NE. 0 )THEN 930 CALL crs_lbc_lnk( pv_r2d,'Z',-999.,'no0') 931 ELSE 932 CALL lbc_lnk( pv_r2d,'Z',-999.,'no0' ) 933 ENDIF 925 934 ELSEIF( PRESENT(pv_r3d) .AND. idom /= jpdom_unknown ) THEN 926 935 ! this if could be simplified with the new lbc_lnk that works with any size of the 3rd dimension 927 936 IF( icnt(3) == jpk ) THEN 928 CALL lbc_lnk( pv_r3d,'Z',-999.,'no0' ) 937 IF( lk_crs .AND. jpi == jpi_crs .AND. jpi .NE. 0 )THEN 938 CALL crs_lbc_lnk( pv_r3d,'Z',-999.,'no0') 939 ELSE 940 CALL lbc_lnk( pv_r3d,'Z',-999.,'no0' ) 941 ENDIF 929 942 ELSE ! put some arbitrary value (a call to lbc_lnk will be done later...) 930 943 DO jj = nlcj+1, jpj ; pv_r3d(1:nlci, jj, :) = pv_r3d(1:nlci, nlej, :) ; END DO -
branches/2015/dev_r5003_MERCATOR6_CRS/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfmxl_crs.F90
r7207 r7398 78 78 79 79 ! w-level of the turbocline 80 imld(:,:)= 080 imld(:,:)=1 81 81 DO jk = jpkm1, nlb10, -1 ! from the bottom to nlb10 82 82 DO jj = 1, jpj_crs … … 101 101 END DO 102 102 ! 103 IF( lk_crs ) CALL iom_swap( "nemo_crs" ) 104 CALL iom_put( "mldkz5" , hmld_crs ) 105 IF( lk_crs ) CALL iom_swap( "nemo" ) 106 ! 103 107 CALL wrk_dealloc( jpi_crs,jpj_crs, imld ) 104 108 !
Note: See TracChangeset
for help on using the changeset viewer.