The dynamic q2/2-equation (Source File: q2over2eq.F90)


    subroutine q2over2eq(nlev,dt,u_taus,u_taub,z0s,z0b,h,NN,SS)

The transport equation for the TKE $ q^2/2=k$ can be written as

$\displaystyle \dot{\overline{q^2/2}} = {\cal D}_q + P + G - \epsilon \; , \quad$ (154)

where $ \dot{\overline{q^2/2}}$ denotes the material derivative of $ q^2/2$. With $ P$ and $ G$ following from (152), evidently, this equation is formally identical to (150). The only reason why it is discretized seperately here, is the slightly different down-gradient model for the transport term,

$\displaystyle {\cal D}_q = \dfrac{\partial}{\partial {z}} \left( q l S_q \dfrac{\partial {q^2/2}}{\partial {z}} \right) \; , \quad$ (155)

where $ S_q$ is a model constant. The notation has been chosen according to that introduced by Mellor and Yamada (1982). Using their notation, also (153) can be expressed in mathematically identical form as

$\displaystyle \epsilon = \frac{q^3}{B_1 l} \; , \quad$ (156)

where $ B_1$ is a constant of the model. Note, that the equivalence of (153) and (156) requires that

$\displaystyle (c_\mu^0)^{-2} = \frac{1}{2} B_1^\frac{2}{3} \quad .$ (157)


    use turbulence,   only: P,B
    use turbulence,   only: tke,tkeo,k_min,eps,L
    use turbulence,   only: q2over2_bc, k_ubc, k_lbc, ubc_type, lbc_type
    use turbulence,   only: sq
    use util,         only: Dirichlet,Neumann
    number of vertical layers
    integer,  intent(in)                :: nlev
    time step (s)
    REALTYPE, intent(in)                :: dt
    surface and bottom
    friction velocity (m/s)
    REALTYPE, intent(in)                :: u_taus,u_taub
    surface and bottom
    roughness length (m)
    REALTYPE, intent(in)                :: z0s,z0b
    layer thickness (m)
    REALTYPE, intent(in)                :: h(0:nlev)
    square of shear and buoyancy
    frequency (1/s^2)
    REALTYPE, intent(in)                :: NN(0:nlev),SS(0:nlev)
    Original author(s): Lars Umlauf
    $Log: q2over2eq.F90,v $
    Revision 1.6  2010-09-17 12:53:52  jorn
    extensive code clean-up to ensure proper initialization and clean-up of all variables
    Revision 1.5  2005-12-28 09:42:33  hb
    Patankar trick reverted to older versions for stabilising 3D computations
    Revision 1.4  2005/06/27 13:44:07  kbk
    modified + removed traling blanks
    Revision 1.3  2003/03/28 09:20:35  kbk
    added new copyright to files
    Revision 1.2  2003/03/10 09:04:04  gotm
    Fixed comment char
    Revision 1.1  2003/03/10 09:00:36  gotm
    Part of new generic turbulence model

Karsten Bolding 2012-01-24