- Timestamp:
- 2021-08-12T15:18:46+02:00 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/branches/UKMO/NEMO_4.0.4_CO9_OBS_ASM/src/OCE/ASM/asminc.F90
r14075 r15183 31 31 USE zpshde ! Partial step : Horizontal Derivative 32 32 USE asmpar ! Parameters for the assmilation interface 33 USE asmbkg !34 33 USE c1d ! 1D initialization 35 34 USE sbc_oce ! Surface boundary condition variables. … … 59 58 #endif 60 59 LOGICAL, PUBLIC :: ln_bkgwri !: No output of the background state fields 60 LOGICAL, PUBLIC :: ln_avgbkg !: No output of the mean background state fields 61 61 LOGICAL, PUBLIC :: ln_asmiau !: No applying forcing with an assimilation increment 62 62 LOGICAL, PUBLIC :: ln_asmdin !: No direct initialization … … 82 82 INTEGER , PUBLIC :: nitiaustr !: Time step of the start of the IAU interval 83 83 INTEGER , PUBLIC :: nitiaufin !: Time step of the end of the IAU interval 84 INTEGER , PUBLIC :: nitavgbkg !: Number of timesteps to average assim bkg [0,nitavgbkg] 84 85 ! 85 86 INTEGER , PUBLIC :: niaufn !: Type of IAU weighing function: = 0 Constant weighting … … 122 123 REAL(KIND=dp) :: ditiaustr_date ! Date YYYYMMDD.HHMMSS of IAU interval start time step 123 124 REAL(KIND=dp) :: ditiaufin_date ! Date YYYYMMDD.HHMMSS of IAU interval final time step 125 REAL(KIND=dp) :: ditavgbkg_date ! Date YYYYMMDD.HHMMSS of end of assim bkg averaging period 124 126 125 127 REAL(wp) :: znorm ! Normalization factor for IAU weights … … 132 134 REAL(wp), ALLOCATABLE, DIMENSION(:,:) :: zhdiv ! 2D workspace 133 135 !! 134 NAMELIST/nam_asminc/ ln_bkgwri, 136 NAMELIST/nam_asminc/ ln_bkgwri, ln_avgbkg, & 135 137 & ln_trainc, ln_dyninc, ln_sshinc, & 136 138 & ln_asmdin, ln_asmiau, & 137 139 & nitbkg, nitdin, nitiaustr, nitiaufin, niaufn, & 138 & ln_salfix, salfixmin, nn_divdmp 140 & ln_salfix, salfixmin, nn_divdmp, nitavgbkg 139 141 !!---------------------------------------------------------------------- 140 142 … … 142 144 ! Read Namelist nam_asminc : assimilation increment interface 143 145 !----------------------------------------------------------------------- 144 ln_seaiceinc = .FALSE. 146 ! Set default values 147 ln_bkgwri = .FALSE. 148 ln_avgbkg = .FALSE. 149 ln_trainc = .FALSE. 150 ln_dyninc = .FALSE. 151 ln_sshinc = .FALSE. 152 ln_asmdin = .FALSE. 153 ln_asmiau = .TRUE. 154 ln_salfix = .FALSE. 155 ln_seaiceinc = .FALSE. 145 156 ln_temnofreeze = .FALSE. 157 nitbkg = 0 158 nitdin = 0 159 nitiaustr = 1 160 nitiaufin = 150 161 niaufn = 0 162 salfixmin = -9999 163 nitavgbkg = 1 146 164 147 165 REWIND( numnam_ref ) ! Namelist nam_asminc in reference namelist : Assimilation increment … … 160 178 WRITE(numout,*) ' Namelist namasm : set assimilation increment parameters' 161 179 WRITE(numout,*) ' Logical switch for writing out background state ln_bkgwri = ', ln_bkgwri 180 WRITE(numout,*) ' Logical switch for writing mean background state ln_avgbkg = ', ln_avgbkg 162 181 WRITE(numout,*) ' Logical switch for applying tracer increments ln_trainc = ', ln_trainc 163 182 WRITE(numout,*) ' Logical switch for applying velocity increments ln_dyninc = ', ln_dyninc … … 170 189 WRITE(numout,*) ' Timestep of start of IAU interval in [0,nitend-nit000-1] nitiaustr = ', nitiaustr 171 190 WRITE(numout,*) ' Timestep of end of IAU interval in [0,nitend-nit000-1] nitiaufin = ', nitiaufin 191 WRITE(numout,*) ' Number of timesteps to average assim bkg [0,nitavgbkg] nitavgbkg = ', nitavgbkg 172 192 WRITE(numout,*) ' Type of IAU weighting function niaufn = ', niaufn 173 193 WRITE(numout,*) ' Logical switch for ensuring that the sa > salfixmin ln_salfix = ', ln_salfix … … 179 199 nitiaustr_r = nitiaustr + nit000 - 1 ! Start of IAU interval referenced to nit000 180 200 nitiaufin_r = nitiaufin + nit000 - 1 ! End of IAU interval referenced to nit000 201 nitavgbkg_r = nitavgbkg + nit000 - 1 ! Averaging period referenced to nit000 181 202 182 203 iiauper = nitiaufin_r - nitiaustr_r + 1 ! IAU interval length … … 188 209 CALL calc_date( nitiaustr_r, ditiaustr_date ) ! IAU start time referenced to ndate0 189 210 CALL calc_date( nitiaufin_r, ditiaufin_date ) ! IAU end time referenced to ndate0 211 CALL calc_date( nitavgbkg_r, ditavgbkg_date ) ! End of assim bkg averaging period referenced to ndate0 190 212 191 213 IF(lwp) THEN … … 199 221 WRITE(numout,*) ' nitiaustr_r = ', nitiaustr_r 200 222 WRITE(numout,*) ' nitiaufin_r = ', nitiaufin_r 223 WRITE(numout,*) ' nitavgbkg_r = ', nitavgbkg_r 201 224 WRITE(numout,*) 202 225 WRITE(numout,*) ' Dates referenced to current cycle:' … … 209 232 WRITE(numout,*) ' ditiaustr_date = ', ditiaustr_date 210 233 WRITE(numout,*) ' ditiaufin_date = ', ditiaufin_date 234 WRITE(numout,*) ' ditavgbkg_date = ', ditavgbkg_date 211 235 ENDIF 212 236 … … 249 273 & ' the cycle interval') 250 274 275 IF ( nitavgbkg_r > nitend ) & 276 & CALL ctl_stop( ' nitavgbkg_r :', & 277 & ' Assim bkg averaging period is outside', & 278 & ' the cycle interval') 279 251 280 IF ( nstop > 0 ) RETURN ! if there are any errors then go no further 252 281 … … 494 523 ! 495 524 IF( lk_asminc ) THEN !== data assimilation ==! 496 IF( ln_bkgwri ) CALL asm_bkg_wri( nit000 - 1 ) ! Output background fields525 ! IF( ln_bkgwri ) CALL asm_bkg_wri( nit000 - 1 ) ! Output background fields 497 526 IF( ln_asmdin ) THEN ! Direct initialization 498 527 IF( ln_trainc ) CALL tra_asm_inc( nit000 - 1 ) ! Tracers
Note: See TracChangeset
for help on using the changeset viewer.