Commit d788fff8 authored by Knut's avatar Knut

initialise z[u|v]b for gotm

parent ca25f8e7
...@@ -85,6 +85,10 @@ ...@@ -85,6 +85,10 @@
!$OMP FIRSTPRIVATE(j) & !$OMP FIRSTPRIVATE(j) &
!$OMP PRIVATE(i,vel,cd,it,z0d) !$OMP PRIVATE(i,vel,cd,it,z0d)
! KK-TODO: the present implementation sets normal velocity outside open
! bdy cell to zero (we need proper mirror)
! zonal velocity ! zonal velocity
!$OMP DO SCHEDULE(RUNTIME) !$OMP DO SCHEDULE(RUNTIME)
#ifndef SLICE_MODEL #ifndef SLICE_MODEL
......
...@@ -195,6 +195,7 @@ ...@@ -195,6 +195,7 @@
ssen = _ZERO_ ; ssun = _ZERO_ ; ssvn = _ZERO_ ssen = _ZERO_ ; ssun = _ZERO_ ; ssvn = _ZERO_
Dn = _ZERO_ ; Dun = _ZERO_ ; Dvn = _ZERO_ Dn = _ZERO_ ; Dun = _ZERO_ ; Dvn = _ZERO_
zub = -9999.0 ; zvb = -9999.0 ! must be initialised for gotm
if (bottfric_method .eq. 1) then if (bottfric_method .eq. 1) then
rru = rdrag rru = rdrag
rrv = rdrag rrv = rdrag
......
...@@ -395,6 +395,7 @@ ...@@ -395,6 +395,7 @@
call getm_error("init_domain()", & call getm_error("init_domain()", &
"non-positive bottom roughness"); "non-positive bottom roughness");
end if end if
z0 = z0_const
zub0 = z0_const zub0 = z0_const
zvb0 = z0_const zvb0 = z0_const
case(3) case(3)
...@@ -422,7 +423,7 @@ ...@@ -422,7 +423,7 @@
end do end do
case default case default
call getm_error("init_domain()", & call getm_error("init_domain()", &
"A non valid z0 method has been chosen"); "A non valid bottfric method has been chosen");
end select end select
if (bottfric_method.eq.2 .or. bottfric_method.eq.3) then if (bottfric_method.eq.2 .or. bottfric_method.eq.3) then
if (cd_min .gt. _ZERO_) then if (cd_min .gt. _ZERO_) then
...@@ -433,6 +434,11 @@ ...@@ -433,6 +434,11 @@
if (z0d_iters .gt. 0) then if (z0d_iters .gt. 0) then
LEVEL3 'iterations for dynamic bottom roughness: ',z0d_iters LEVEL3 'iterations for dynamic bottom roughness: ',z0d_iters
end if end if
else
#ifndef CONSTANT_VISCOSITY
call getm_error("init_domain()", &
"consistency with GOTM requires quadratic bottom friction");
#endif
end if end if
#ifdef DEBUG #ifdef DEBUG
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment