12 #include "inc_openmp.h" 47 real(RP),
intent(out) :: Z0M_t(IA,JA)
48 real(RP),
intent(out) :: Z0H_t(IA,JA)
49 real(RP),
intent(out) :: Z0E_t(IA,JA)
51 real(RP),
intent(in) :: Z0M(IA,JA)
52 real(RP),
intent(in) :: Z0H(IA,JA)
53 real(RP),
intent(in) :: Z0E(IA,JA)
54 real(RP),
intent(in) :: UA (IA,JA)
55 real(RP),
intent(in) :: VA (IA,JA)
56 real(RP),
intent(in) :: Z1 (IA,JA)
57 real(DP),
intent(in) :: dt
72 private :: roughness_miller92_setup
73 private :: roughness_moon07_setup
74 private :: roughness_const_setup
75 private :: roughness_miller92
76 private :: roughness_moon07
77 private :: roughness_const
83 character(len=H_SHORT),
private :: roughness_type =
'MOON07' 85 real(RP),
private :: roughness_visck = 1.5e-5_rp
86 real(RP),
private :: roughness_ustar_min = 1.0e-3_rp
87 real(RP),
private :: roughness_z0m_min = 1.0e-5_rp
88 real(RP),
private :: roughness_z0h_min = 1.0e-5_rp
89 real(RP),
private :: roughness_z0e_min = 1.0e-5_rp
91 real(RP),
private :: roughness_miller92_cm0 = 1.0e-3_rp
92 real(RP),
private :: roughness_miller92_z0mi = 0.0e-0_rp
93 real(RP),
private :: roughness_miller92_z0mr = 1.8e-2_rp
94 real(RP),
private :: roughness_miller92_z0ms = 1.1e-1_rp
95 real(RP),
private :: roughness_miller92_z0hi = 1.4e-5_rp
96 real(RP),
private :: roughness_miller92_z0hr = 0.0e-0_rp
97 real(RP),
private :: roughness_miller92_z0hs = 4.0e-1_rp
98 real(RP),
private :: roughness_miller92_z0ei = 1.3e-4_rp
99 real(RP),
private :: roughness_miller92_z0er = 0.0e-0_rp
100 real(RP),
private :: roughness_miller92_z0es = 6.2e-1_rp
102 integer,
private :: roughness_moon07_itelim = 10
112 namelist / param_roughness / &
115 roughness_ustar_min, &
124 if(
io_l )
write(
io_fid_log,*)
'++++++ Module[ROUGHNESS] / Categ[COUPLER] / Origin[SCALElib]' 130 if(
io_l )
write(
io_fid_log,*)
'*** Not found namelist. Default used.' 131 elseif( ierr > 0 )
then 132 write(*,*)
'xxx Not appropriate names in namelist PARAM_ROUGHNESS. Check!' 138 if(
io_l )
write(
io_fid_log,*)
'*** Scheme for ocean roughness length : ', trim(roughness_type)
139 select case(roughness_type)
143 call roughness_miller92_setup
147 call roughness_moon07_setup
151 call roughness_const_setup
153 write(*,*)
'xxx Unsupported ROUGHNESS_type. STOP' 161 subroutine roughness_miller92_setup
166 namelist / param_roughness_miller92 / &
167 roughness_miller92_cm0, &
168 roughness_miller92_z0mi, &
169 roughness_miller92_z0mr, &
170 roughness_miller92_z0ms, &
171 roughness_miller92_z0hi, &
172 roughness_miller92_z0hr, &
173 roughness_miller92_z0hs, &
174 roughness_miller92_z0ei, &
175 roughness_miller92_z0er, &
176 roughness_miller92_z0es
183 read(
io_fid_conf,nml=param_roughness_miller92,iostat=ierr)
185 if(
io_l )
write(
io_fid_log,*)
'*** Not found namelist. Default used.' 186 elseif( ierr > 0 )
then 187 write(*,*)
'xxx Not appropriate names in namelist PARAM_ROUGHNESS_MILLER92. Check!' 193 end subroutine roughness_miller92_setup
196 subroutine roughness_moon07_setup
201 namelist / param_roughness_moon07 / &
202 roughness_moon07_itelim
209 read(
io_fid_conf,nml=param_roughness_moon07,iostat=ierr)
211 if(
io_l )
write(
io_fid_log,*)
'*** Not found namelist. Default used.' 212 elseif( ierr > 0 )
then 213 write(*,*)
'xxx Not appropriate names in namelist PARAM_ROUGHNESS_MOON07. Check!' 219 end subroutine roughness_moon07_setup
222 subroutine roughness_const_setup
227 end subroutine roughness_const_setup
230 subroutine roughness_miller92( &
246 real(RP),
intent(out) :: z0m_t(
ia,
ja)
247 real(RP),
intent(out) :: z0h_t(
ia,
ja)
248 real(RP),
intent(out) :: z0e_t(
ia,
ja)
250 real(RP),
intent(in) :: z0m(
ia,
ja)
251 real(RP),
intent(in) :: z0h(
ia,
ja)
252 real(RP),
intent(in) :: z0e(
ia,
ja)
253 real(RP),
intent(in) :: ua (
ia,
ja)
254 real(RP),
intent(in) :: va (
ia,
ja)
255 real(RP),
intent(in) :: z1 (
ia,
ja)
256 real(DP),
intent(in) :: dt
259 real(RP) :: z0m1(
ia,
ja)
260 real(RP) :: z0h1(
ia,
ja)
261 real(RP) :: z0e1(
ia,
ja)
263 real(RP) :: uabs, ustar
271 uabs = sqrt( ua(i,j)**2 + va(i,j)**2 )
272 ustar = max( sqrt( roughness_miller92_cm0 ) * uabs, roughness_ustar_min )
274 z0m1(i,j) = max( roughness_miller92_z0mi &
275 + roughness_miller92_z0mr / grav * ustar * ustar &
276 + roughness_miller92_z0ms * roughness_visck / ustar, &
278 z0h1(i,j) = max( roughness_miller92_z0hi &
279 + roughness_miller92_z0hr / grav * ustar * ustar &
280 + roughness_miller92_z0hs * roughness_visck / ustar, &
282 z0e1(i,j) = max( roughness_miller92_z0ei &
283 + roughness_miller92_z0er / grav * ustar * ustar &
284 + roughness_miller92_z0es * roughness_visck / ustar, &
288 z0m_t(i,j) = ( z0m1(i,j) - z0m(i,j) ) / dt
289 z0h_t(i,j) = ( z0h1(i,j) - z0h(i,j) ) / dt
290 z0e_t(i,j) = ( z0e1(i,j) - z0e(i,j) ) / dt
296 end subroutine roughness_miller92
302 subroutine roughness_moon07( &
319 real(RP),
intent(out) :: z0m_t(
ia,
ja)
320 real(RP),
intent(out) :: z0h_t(
ia,
ja)
321 real(RP),
intent(out) :: z0e_t(
ia,
ja)
323 real(RP),
intent(in) :: z0m(
ia,
ja)
324 real(RP),
intent(in) :: z0h(
ia,
ja)
325 real(RP),
intent(in) :: z0e(
ia,
ja)
326 real(RP),
intent(in) :: ua (
ia,
ja)
327 real(RP),
intent(in) :: va (
ia,
ja)
328 real(RP),
intent(in) :: z1 (
ia,
ja)
329 real(DP),
intent(in) :: dt
332 real(RP) :: z0m1(
ia,
ja)
333 real(RP) :: z0h1(
ia,
ja)
334 real(RP) :: z0e1(
ia,
ja)
336 real(RP) :: ustar(
ia,
ja)
337 real(RP) :: uabs (
ia,
ja)
346 z0m1(i,j) = max( z0m(i,j), roughness_z0m_min )
347 uabs(i,j) = sqrt( ua(i,j)**2 + va(i,j)**2 )
351 do ite = 1, roughness_moon07_itelim
357 ustar(i,j) = max( karman * uabs(i,j) / log( z1(i,j)/z0m1(i,j) ), roughness_ustar_min )
358 u10m = ustar(i,j) / karman * log( 10.0_rp/z0m1(i,j) )
360 if ( u10m <= 12.5_rp )
then 361 z0m1(i,j) = max( 0.0185_rp * ustar(i,j)**2 / grav, roughness_z0m_min )
363 z0m1(i,j) = 1.0e-3_rp * ( 0.085_rp * ( -0.56_rp*ustar(i,j)**2 &
364 + 20.255_rp*ustar(i,j) &
365 + 2.458_rp ) - 0.58_rp )
375 z0h1(i,j) = min( 5.5e-5_rp / ( z0m1(i,j) * ustar(i,j) / roughness_visck )**0.6_rp, 1.1e-4_rp )
376 z0e1(i,j) = z0h1(i,j)
383 z0m1(i,j) = max( z0m1(i,j), roughness_z0m_min )
384 z0h1(i,j) = max( z0h1(i,j), roughness_z0h_min )
385 z0e1(i,j) = max( z0e1(i,j), roughness_z0e_min )
388 z0m_t(i,j) = ( z0m1(i,j) - z0m(i,j) ) / dt
389 z0h_t(i,j) = ( z0h1(i,j) - z0h(i,j) ) / dt
390 z0e_t(i,j) = ( z0e1(i,j) - z0e(i,j) ) / dt
395 end subroutine roughness_moon07
398 subroutine roughness_const( &
412 real(RP),
intent(out) :: z0m_t(
ia,
ja)
413 real(RP),
intent(out) :: z0h_t(
ia,
ja)
414 real(RP),
intent(out) :: z0e_t(
ia,
ja)
416 real(RP),
intent(in) :: z0m(
ia,
ja)
417 real(RP),
intent(in) :: z0h(
ia,
ja)
418 real(RP),
intent(in) :: z0e(
ia,
ja)
419 real(RP),
intent(in) :: ua (
ia,
ja)
420 real(RP),
intent(in) :: va (
ia,
ja)
421 real(RP),
intent(in) :: z1 (
ia,
ja)
422 real(DP),
intent(in) :: dt
429 end subroutine roughness_const
integer, public is
start point of inner domain: x, local
integer, public je
end point of inner domain: y, local
subroutine, public prc_mpistop
Abort MPI.
logical, public io_l
output log or not? (this process)
subroutine, public roughness_setup
real(rp), parameter, public const_karman
von Karman constant
logical, public io_nml
output log or not? (for namelist, this process)
integer, public ia
of whole cells: x, local, with HALO
real(rp), public const_grav
standard acceleration of gravity [m/s2]
integer, public js
start point of inner domain: y, local
procedure(rl), pointer, public roughness
integer, public ie
end point of inner domain: x, local
module Surface roughness length
integer, public io_fid_conf
Config file ID.
integer, public io_fid_log
Log file ID.
integer, public io_fid_nml
Log file ID (only for output namelist)
integer, public ja
of whole cells: y, local, with HALO