SURFEX v8.1
General documentation of Surfex
Surfex_Git2
src
SURFEX
get_z0rel.F90
Go to the documentation of this file.
1
!SFX_LIC Copyright 1994-2014 CNRS, Meteo-France and Universite Paul Sabatier
2
!SFX_LIC This is part of the SURFEX software governed by the CeCILL-C licence
3
!SFX_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
4
!SFX_LIC for details. version 1.
5
! ######spl
6
SUBROUTINE
get_z0rel
(ISS,OMASK )
7
! ######################################################################
8
!
9
!* 0. DECLARATION
10
! -----------
11
!
12
USE
modd_csts
, ONLY
:
xkarman
13
USE
modd_isba_par
, ONLY
: xcdz0eff
14
USE
modd_surf_par
, ONLY
:
xundef
15
!
16
USE
modd_sso_n
, ONLY
:
sso_t
17
!
18
USE
yomhook
,ONLY
:
lhook
,
dr_hook
19
USE
parkind1
,ONLY
:
jprb
20
!
21
IMPLICIT NONE
22
!
23
!* 0.1 Declaration of dummy arguments
24
! ------------------------------
25
!
26
TYPE
(
sso_t
),
INTENT(INOUT)
:: ISS
27
!
28
LOGICAL
,
DIMENSION(:)
,
INTENT(IN)
,
OPTIONAL
:: OMASK
! mask where computations
29
! are done
30
!
31
!* 0.2 Declaration of other local variables
32
! ------------------------------------
33
!
34
REAL
,
DIMENSION(SIZE(ISS%XAOSIP))
:: ZLOC
35
LOGICAL
,
DIMENSION(SIZE(ISS%XAOSIP))
:: GMASK
36
!
37
INTEGER
:: JJ
! loop counter on points
38
REAL(KIND=JPRB)
:: ZHOOK_HANDLE
39
!----------------------------------------------------------------------------
40
!
41
IF
(
lhook
)
CALL
dr_hook
(
'GET_Z0REL'
,0,zhook_handle)
42
!
43
IF
(
PRESENT
(omask))
THEN
44
gmask=omask
45
ELSE
46
gmask=(iss%XAOSIP/=
xundef
)
47
END IF
48
!
49
iss%XZ0REL=
xundef
50
!
51
zloc(:) = 0.
52
!
53
WHERE
(gmask(:))
54
zloc(:) = 0.25 * xcdz0eff/(2.*
xkarman
**2) &
55
* (iss%XAOSIP(:) + iss%XAOSIM(:) + iss%XAOSJP(:) + iss%XAOSJM
(:))
56
WHERE
( zloc(:) > 0. )
57
iss%XZ0REL(:) = 0.25 * (iss%XHO2IP(:) + iss%XHO2IM(:) + iss%XHO2JP(:
) + iss%XHO2JM(:)) &
58
* exp(-sqrt(1./zloc(:)))
59
iss%XZ0REL(:) = max(iss%XZ0REL(:),1e-10)
60
ELSEWHERE
61
iss%XZ0REL(:) = 0.
62
END WHERE
63
END WHERE
64
!
65
IF
(
lhook
)
CALL
dr_hook
(
'GET_Z0REL'
,1,zhook_handle)
66
!
67
!-------------------------------------------------------------------------------
68
!
69
END SUBROUTINE
get_z0rel
70
!
modd_surf_par
Definition:
modd_surf_par.F90:6
modd_sso_n
Definition:
modd_sson.F90:6
yomhook::dr_hook
Definition:
yomhook.F90:20
modd_csts::xkarman
real, save xkarman
Definition:
modd_csts.F90:48
modd_surf_par::xundef
real, parameter xundef
Definition:
modd_surf_par.F90:43
parkind1::jprb
integer, parameter jprb
Definition:
parkind1.F90:32
yomhook::lhook
logical lhook
Definition:
yomhook.F90:15
modd_sso_n::sso_t
Definition:
modd_sson.F90:41
parkind1
Definition:
parkind1.F90:1
modd_csts
Definition:
modd_csts.F90:6
get_z0rel
subroutine get_z0rel(ISS, OMASK)
Definition:
get_z0rel.F90:7
yomhook
Definition:
yomhook.F90:1
Generated on Tue Jan 16 2018 16:23:28 for SURFEX v8.1 by
1.8.13