- Timestamp:
- 2015-02-11T11:50:34+01:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2014/dev_r4650_UKMO7_STARTHOUR/NEMOGCM/NEMO/OPA_SRC/ASM/asminc.F90
r4811 r5075 56 56 LOGICAL, PUBLIC, PARAMETER :: lk_asminc = .FALSE. !: No assimilation increments 57 57 #endif 58 LOGICAL, PUBLIC :: ln_bkgwri !: No output of the background state fields59 LOGICAL, PUBLIC :: ln_asmiau !: No applying forcing with an assimilation increment60 LOGICAL, PUBLIC :: ln_asmdin !: No direct initialization61 LOGICAL, PUBLIC :: ln_trainc !: No tracer (T and S) assimilation increments62 LOGICAL, PUBLIC :: ln_dyninc !: No dynamics (u and v) assimilation increments63 LOGICAL, PUBLIC :: ln_sshinc !: No sea surface height assimilation increment64 LOGICAL, PUBLIC :: ln_seaiceinc !: No sea ice concentration increment65 LOGICAL, PUBLIC :: ln_salfix !: Apply minimum salinity check58 LOGICAL, PUBLIC :: ln_bkgwri = .FALSE. !: No output of the background state fields 59 LOGICAL, PUBLIC :: ln_asmiau = .FALSE. !: No applying forcing with an assimilation increment 60 LOGICAL, PUBLIC :: ln_asmdin = .FALSE. !: No direct initialization 61 LOGICAL, PUBLIC :: ln_trainc = .FALSE. !: No tracer (T and S) assimilation increments 62 LOGICAL, PUBLIC :: ln_dyninc = .FALSE. !: No dynamics (u and v) assimilation increments 63 LOGICAL, PUBLIC :: ln_sshinc = .FALSE. !: No sea surface height assimilation increment 64 LOGICAL, PUBLIC :: ln_seaiceinc !: No sea ice concentration increment 65 LOGICAL, PUBLIC :: ln_salfix = .FALSE. !: Apply minimum salinity check 66 66 LOGICAL, PUBLIC :: ln_temnofreeze = .FALSE. !: Don't allow the temperature to drop below freezing 67 INTEGER, PUBLIC :: nn_divdmp !: Apply divergence damping filter nn_divdmp times67 INTEGER, PUBLIC :: nn_divdmp !: Apply divergence damping filter nn_divdmp times 68 68 69 69 REAL(wp), PUBLIC, DIMENSION(:,:,:), ALLOCATABLE :: t_bkg , s_bkg !: Background temperature and salinity … … 109 109 !! ** Action : 110 110 !!---------------------------------------------------------------------- 111 INTEGER :: ji, jj, jk 112 INTEGER :: jt 113 INTEGER :: imid 114 INTEGER :: inum 111 INTEGER :: ji, jj, jk, jt ! dummy loop indices 112 INTEGER :: imid, inum ! local integers 113 INTEGER :: ios ! Local integer output status for namelist read 115 114 INTEGER :: iiauper ! Number of time steps in the IAU period 116 115 INTEGER :: icycper ! Number of time steps in the cycle 117 INTEGER :: ios ! Local integer output status for namelist read118 119 116 REAL(KIND=dp) :: ditend_date ! Date YYYYMMDD.HHMMSS of final time step 120 117 REAL(KIND=dp) :: ditbkg_date ! Date YYYYMMDD.HHMMSS of background time step for Jb term … … 124 121 125 122 REAL(wp) :: znorm ! Normalization factor for IAU weights 126 REAL(wp) :: ztotwgt ! Value of time-integrated IAU weights 127 ! (should be equal to one) 123 REAL(wp) :: ztotwgt ! Value of time-integrated IAU weights (should be equal to one) 128 124 REAL(wp) :: z_inc_dateb ! Start date of interval on which increment is valid 129 125 REAL(wp) :: z_inc_datef ! End date of interval on which increment is valid 130 126 REAL(wp) :: zdate_bkg ! Date in background state file for DI 131 127 REAL(wp) :: zdate_inc ! Time axis in increments file 132 133 REAL(wp), POINTER, DIMENSION(:,:) :: hdiv128 ! 129 REAL(wp), POINTER, DIMENSION(:,:) :: hdiv ! 2D workspace 134 130 !! 135 131 NAMELIST/nam_asminc/ ln_bkgwri, & … … 137 133 & ln_asmdin, ln_asmiau, & 138 134 & nitbkg, nitdin, nitiaustr, nitiaufin, niaufn, & 139 & ln_salfix, salfixmin, & 140 & nn_divdmp 135 & ln_salfix, salfixmin, nn_divdmp 141 136 !!---------------------------------------------------------------------- 142 137 … … 144 139 ! Read Namelist nam_asminc : assimilation increment interface 145 140 !----------------------------------------------------------------------- 146 147 141 ln_seaiceinc = .FALSE. 148 142 ln_temnofreeze = .FALSE. … … 570 564 ! used to prevent the applied increments taking the temperature below the local freezing point 571 565 572 DO jk =1, jpkm1573 fzptnz (:,:,jk) = tfreez( tsn(:,:,jk,jp_sal), fsdept(:,:,jk) )574 END DO566 DO jk = 1, jpkm1 567 fzptnz(:,:,jk) = eos_fzp( tsn(:,:,jk,jp_sal), fsdept(:,:,jk) ) 568 END DO 575 569 576 570 IF ( ln_asmiau ) THEN … … 587 581 IF(lwp) THEN 588 582 WRITE(numout,*) 589 WRITE(numout,*) 'tra_asm_inc : Tracer IAU at time step = ', & 590 & kt,' with IAU weight = ', wgtiau(it) 583 WRITE(numout,*) 'tra_asm_inc : Tracer IAU at time step = ', kt,' with IAU weight = ', wgtiau(it) 591 584 WRITE(numout,*) '~~~~~~~~~~~~' 592 585 ENDIF … … 636 629 IF (ln_temnofreeze) THEN 637 630 ! Do not apply negative increments if the temperature will fall below freezing 638 WHERE(t_bkginc(:,:,:) > 0.0_wp .OR. & 639 & tsn(:,:,:,jp_tem) + t_bkginc(:,:,:) > fzptnz(:,:,:) ) 631 WHERE( t_bkginc(:,:,:) > 0.0_wp .OR. tsn(:,:,:,jp_tem) + t_bkginc(:,:,:) > fzptnz(:,:,:) ) 640 632 tsn(:,:,:,jp_tem) = t_bkg(:,:,:) + t_bkginc(:,:,:) 641 633 END WHERE … … 646 638 ! Do not apply negative increments if the salinity will fall below a specified 647 639 ! minimum value salfixmin 648 WHERE(s_bkginc(:,:,:) > 0.0_wp .OR. & 649 & tsn(:,:,:,jp_sal) + s_bkginc(:,:,:) > salfixmin ) 640 WHERE( s_bkginc(:,:,:) > 0.0_wp .OR. tsn(:,:,:,jp_sal) + s_bkginc(:,:,:) > salfixmin ) 650 641 tsn(:,:,:,jp_sal) = s_bkg(:,:,:) + s_bkginc(:,:,:) 651 642 END WHERE … … 654 645 ENDIF 655 646 656 tsb(:,:,:,:) = tsn(:,:,:,:) ! Update before fields 657 658 CALL eos( tsb, rhd, rhop, gdept_0(:,:,:) ) ! Before potential and in situ densities 659 647 tsb(:,:,:,:) = tsn(:,:,:,:) ! Update before fields 648 649 CALL eos( tsb, rhd, rhop, gdept_0(:,:,:) ) ! Before potential and in situ densities 650 !!gm fabien 651 ! CALL eos( tsb, rhd, rhop ) ! Before potential and in situ densities 652 !!gm 653 654 660 655 IF( ln_zps .AND. .NOT. lk_c1d ) & 661 & CALL zps_hde( nit000, jpts, tsb, & ! Partial steps: before horizontal derivative662 & gtsu, gtsv, rhd, & ! of T, S, rd at the bottom ocean level663 & g ru , grv )656 & CALL zps_hde( nit000, jpts, tsb, gtsu, gtsv, & ! Partial steps: before horizontal gradient 657 & rhd, gru , grv, aru, arv, gzu, gzv, ge3ru, ge3rv, & ! 658 & gtui, gtvi, grui, grvi, arui, arvi, gzui, gzvi, ge3rui, ge3rvi ) ! of t, s, rd at the last ocean level 664 659 665 660 #if defined key_zdfkpp 666 661 CALL eos( tsn, rhd, fsdept_n(:,:,:) ) ! Compute rhd 662 !!gm fabien CALL eos( tsn, rhd ) ! Compute rhd 667 663 #endif 668 664
Note: See TracChangeset
for help on using the changeset viewer.