New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 7328 – NEMO

Changeset 7328


Ignore:
Timestamp:
2016-11-24T14:20:15+01:00 (7 years ago)
Author:
isabella
Message:

Added parameters in namelist
, plus few more corrections

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/UKMO/dev_r5518_pcbias_ipc/NEMOGCM/NEMO/OPA_SRC/ASM/bias.F90

    r7292 r7328  
    134134      & fctamp,               &  !: amplification factor for T if inertial 
    135135      & rn_maxlat_bias,       &  !: Max lat for latitudinal ramp 
    136       & rn_minlat_bias           !: Min lat for latitudinal ramp 
     136      & rn_minlat_bias,       &  !: Min lat for latitudinal ramp 
     137      & zwgt,                 &  !: weight for IPC 
     138      & ztscale                  !: decay rate for IPC 
    137139 
    138140   LOGICAL,  PRIVATE :: lalloc 
     
    224226         & cn_bias_tot, cn_bias_asm, cn_dir, sn_tbias_ofl, sn_sbias_ofl,  & 
    225227         & ln_bsyncro, fctamp, rn_maxlat_bias, rn_minlat_bias,            & 
    226          & nn_bias_itwrt, ln_itdecay, ln_incpc 
     228         & nn_bias_itwrt, ln_itdecay, ln_incpc, ztscale, zwgt 
    227229  
    228230 
     
    284286    WRITE(numout,*) '     evolve pcbias at each timestep ln_itdecay     = ',ln_itdecay 
    285287    WRITE(numout,*) '     incremental press. correction  ln_incpc       = ',ln_incpc 
     288    WRITE(numout,*) '     incremental press. correction  zwgt           = ',zwgt 
     289    WRITE(numout,*) '     incremental press. correction  ztscale        = ',ztscale 
    286290         WRITE(numout,*) '  Parameters for parition of bias term ' 
    287291         WRITE(numout,*) '                                    fb_t_rlx       = ',fb_t_rlx 
     
    306310            &   CALL ctl_stop (' lk_dtatem, lk_dtasal and lk_tradmp need to be true with ln_bias_rlx' ) 
    307311 
     312         IF ( (.NOT. ln_itdecay) .AND. ln_incpc) &    
     313            &   CALL ctl_stop (' if you set ln_incpc to .true. then you need to set ln_itdecay to .true. as well' ) 
     314 
    308315      ENDIF 
    309316      IF( .NOT. ln_bias ) RETURN 
     
    328335                                      sbias_asm_out(jpi,jpj,jpk), &   
    329336                                      tbias_p_out(jpi,jpj,jpk),   &               
    330                                       sbias_p_out(jpi,jpj,jpk),   & 
    331                                       tbias_i_out(jpi,jpj,jpk),   &   
    332                                       sbias_i_out(jpi,jpj,jpk)   ) 
     337                                      sbias_p_out(jpi,jpj,jpk)    ) 
    333338 
    334339         IF( ln_bias_rlx ) ALLOCATE(  tbias_rlx(jpi,jpj,jpk),     & 
     
    340345            &                         sbias_asm_stscale(jpi,jpj,jpk), & 
    341346                                      tbias_asm_stscale_out(jpi,jpj,jpk), & 
    342                                       sbias_asm_stscale_out(jpi,jpj,jpk)) 
     347                                      sbias_asm_stscale_out(jpi,jpj,jpk), & 
     348                                      tbias_i_out(jpi,jpj,jpk),   &   
     349                                      sbias_i_out(jpi,jpj,jpk)   ) 
    343350 
    344351         lalloc = .TRUE. 
     
    432439                  CALL ctl_stop( 'Bias assim variables not found in ',cn_bias_tot ) 
    433440               ENDIF 
    434  
    435  
    436                IF ( ln_incpc ) THEN 
    437                   IF(lwp) WRITE(numout,*) 'Reading short time scale bias correction fields for bias asm from file ',cn_bias_tot 
    438                   IF( iom_varid( numbias_tot, 'tbias_asm_stscale' ) > 0 ) THEN 
    439                      ! Get the T and S bias data 
    440                      CALL iom_get( numbias_tot, jpdom_autoglo, 'tbias_asm_stscale', tbias_asm_stscale ) 
     441            ENDIF 
     442 
     443            IF ( ln_incpc .and. .not.ln_bsyncro ) THEN 
     444               IF(lwp) WRITE(numout,*) 'Reading short time scale bias correction fields for bias asm from file ',cn_bias_tot 
     445               IF( iom_varid( numbias_tot, 'tbias_asm_stscale' ) > 0 ) THEN 
     446                  ! Get the T and S bias data 
     447                  CALL iom_get( numbias_tot, jpdom_autoglo, 'tbias_asm_stscale', tbias_asm_stscale ) 
    441448                     CALL iom_get( numbias_tot, jpdom_autoglo, 'sbias_asm_stscale', sbias_asm_stscale ) 
    442                   ELSE 
     449               ELSE 
    443450                     CALL ctl_stop( 'Short time scale bias assim variables not found in ',cn_bias_tot ) 
    444                   ENDIF 
    445                ENDIF   
    446  
    447             ENDIF 
     451               ENDIF 
     452            ENDIF   
    448453 
    449454 
     
    577582      REAL(wp)            ::   ztfrac, ztsday 
    578583      REAL(wp)            ::   zfrac, zfrac1 ! temporal weights for inst pcbias (names could be changed) 
    579       REAL(wp)            ::   ztscale       ! reduce the inst pcbias by this amount per 24 hours 
    580       REAL(wp)            ::   zwgt          ! Weight for the inst pcorr term 
    581584      REAL(wp)            ::   zdecay        ! used in inst pcorr 
    582585      REAL(wp), DIMENSION(jpi,jpj) :: zcof1, zcof2 
     
    593596      tbias_i(:,:,:) = 0.0_wp 
    594597      sbias_i(:,:,:) = 0.0_wp 
    595  
    596       ztscale = 0.1_wp 
    597       zwgt    = 0.8_wp 
    598598 
    599599      IF ( ln_bias_asm ) THEN 
     
    604604            &                              fbcoef(:,:)   * fb_t_asm_max ) 
    605605         zcof2(:,:) = ( 1.0_wp - fbcoef(:,:) ) * fb_p_asm 
    606        
     606      
     607 
    607608         IF ( ln_itdecay ) THEN   !decay the pressure correction at each time step 
    608609     
     
    902903         tbias_p_out(:,:,:)   = tbias_p(:,:,:) 
    903904         sbias_p_out(:,:,:)   = sbias_p(:,:,:) 
    904          tbias_i_out(:,:,:)   = tbias_i(:,:,:) 
    905          sbias_i_out(:,:,:)   = sbias_i(:,:,:) 
     905         IF (ln_incpc) THEN 
     906            tbias_i_out(:,:,:)   = tbias_i(:,:,:) 
     907            sbias_i_out(:,:,:)   = sbias_i(:,:,:) 
     908         ENDIF 
    906909      ENDIF 
    907910 
     
    10331036         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_asm' , sbias_asm_out )    
    10341037         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'tbias_p'   , tbias_p_out ) 
    1035          CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_p'   , sbias_p_out ) 
    1036          CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'tbias_i'   , tbias_i_out ) 
    1037          CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_i'   , sbias_i_out )           
     1038         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_p'   , sbias_p_out )          
    10381039      ENDIF 
    10391040 
    10401041      IF ( ln_incpc ) THEN 
    10411042         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'tbias_asm_stscale' , tbias_asm_stscale_out )    
    1042          CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_asm_stscale' , sbias_asm_stscale_out )    
     1043         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_asm_stscale' , sbias_asm_stscale_out )  
     1044         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'tbias_i'   , tbias_i_out ) 
     1045         CALL iom_rstput( nn_bias_itwrt, nn_bias_itwrt, numbias_tot, 'sbias_i'   , sbias_i_out )    
    10431046      ENDIF 
    10441047       
Note: See TracChangeset for help on using the changeset viewer.