Skip to content
Snippets Groups Projects
Commit 25df1f82 authored by RODIER Quentin's avatar RODIER Quentin
Browse files

Quentin 28/02/2022: add REPRO48 bugfix from /mesonh/turb/mode_turb_ver_thermo_corr.F90 for PSIGS

parent 861feee2
No related branches found
No related tags found
No related merge requests found
...@@ -519,7 +519,7 @@ ENDIF ...@@ -519,7 +519,7 @@ ENDIF
PRTHLS,PRRS,ZTHLP,ZRP,PTP,PWTH,PWRC ) PRTHLS,PRRS,ZTHLP,ZRP,PTP,PWTH,PWRC )
! !
CALL TURB_VER_THERMO_CORR(KKA,KKU,KKL,KRR,KRRL,KRRI, & CALL TURB_VER_THERMO_CORR(KKA,KKU,KKL,KRR,KRRL,KRRI, &
OTURB_FLX,HTURBDIM,HTOM,OOCEAN, & OTURB_FLX,HTURBDIM,HTOM, &
PIMPL,PEXPL, & PIMPL,PEXPL, &
TPFILE, & TPFILE, &
PDXX,PDYY,PDZZ,PDZX,PDZY,PDIRCOSZW, & PDXX,PDYY,PDZZ,PDZX,PDZY,PDIRCOSZW, &
......
...@@ -6,7 +6,7 @@ MODULE MODE_TURB_VER_THERMO_CORR ...@@ -6,7 +6,7 @@ MODULE MODE_TURB_VER_THERMO_CORR
IMPLICIT NONE IMPLICIT NONE
CONTAINS CONTAINS
SUBROUTINE TURB_VER_THERMO_CORR(KKA,KKU,KKL,KRR,KRRL,KRRI, & SUBROUTINE TURB_VER_THERMO_CORR(KKA,KKU,KKL,KRR,KRRL,KRRI, &
OTURB_FLX,HTURBDIM,HTOM,OOCEAN, & OTURB_FLX,HTURBDIM,HTOM, &
PIMPL,PEXPL, & PIMPL,PEXPL, &
TPFILE, & TPFILE, &
PDXX,PDYY,PDZZ,PDZX,PDZY,PDIRCOSZW, & PDXX,PDYY,PDZZ,PDZX,PDZY,PDIRCOSZW, &
...@@ -238,7 +238,6 @@ INTEGER, INTENT(IN) :: KRRL ! number of liquid water v ...@@ -238,7 +238,6 @@ INTEGER, INTENT(IN) :: KRRL ! number of liquid water v
INTEGER, INTENT(IN) :: KRRI ! number of ice water var. INTEGER, INTENT(IN) :: KRRI ! number of ice water var.
LOGICAL, INTENT(IN) :: OTURB_FLX ! switch to write the LOGICAL, INTENT(IN) :: OTURB_FLX ! switch to write the
! turbulent fluxes in the syncronous FM-file ! turbulent fluxes in the syncronous FM-file
LOGICAL, INTENT(IN) :: OOCEAN ! switch for Ocean model version
CHARACTER(len=4), INTENT(IN) :: HTURBDIM ! dimensionality of the CHARACTER(len=4), INTENT(IN) :: HTURBDIM ! dimensionality of the
! turbulence scheme ! turbulence scheme
CHARACTER(len=4), INTENT(IN) :: HTOM ! type of Third Order Moment CHARACTER(len=4), INTENT(IN) :: HTOM ! type of Third Order Moment
...@@ -845,8 +844,12 @@ ENDIF ...@@ -845,8 +844,12 @@ ENDIF
! Extrapolate PSIGS at the ground and at the top ! Extrapolate PSIGS at the ground and at the top
PSIGS(:,:,KKA) = PSIGS(:,:,IKB) PSIGS(:,:,KKA) = PSIGS(:,:,IKB)
PSIGS(:,:,KKU) = PSIGS(:,:,IKE) PSIGS(:,:,KKU) = PSIGS(:,:,IKE)
PSIGS(:,:,:) = MAX (PSIGS(:,:,:) , 0.) #ifdef REPRO48
PSIGS(:,:,:) = MAX (PSIGS(:,:,:) , 0.)
PSIGS(:,:,:) = SQRT(PSIGS(:,:,:)) PSIGS(:,:,:) = SQRT(PSIGS(:,:,:))
#else
PSIGS(:,:,:) = SQRT( MAX (PSIGS(:,:,:) , 1.E-12) )
#endif
END IF END IF
! !
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment