1 Introduction

In the atmospheric boundary layer (ABL) viscous effects are negligible due to ubiquitous rough surfaces and high Reynolds numbers and a rough-wall model is needed (Raupach et al. 1991). The model relates the surface flux to the aerodynamic roughness length giving the well-known logarithmic law of the wall that is strictly valid only for the neutrally-stratified ABL and vanishing pressure gradient.

For numerical computations the first grid point is commonly placed inside the logarithmic layer. Close to the surface buoyancy effects are usually negligible and turbulence is predominantly produced by shear effects. This makes the logarithmic law for a neutrally-stratified environment applicable, thus relating the surface flux to the mean wind speed in a simple form. Above this lower part of the logarithmic layer, turbulence can be strongly affected by buoyancy forces, and in this case corrections to the logarithmic law are introduced through the non-dimensional functions proposed in the well-known Monin–Obukhov similarity theory (MOST) (Monin and Obukhov 1954). These functions are empirically determined from atmospheric measurements, as in Businger et al. (1971) and Högström (1988), and generalize the logarithmic law for stratified flows. There have been numerous atmospheric experiments, see Foken (2006) for a review, proposing different functions relating the surface fluxes to the mean wind speed and potential temperature profiles.

Turbulence models, used for computations in the ABL, are categorized according to their complexity regarding the methods used to solve the closure problem (Mellor and Yamada 1974). Regardless of the complexity, all turbulence models require boundary conditions that influence the solution in the surface layer. Models with detailed physical descriptions, such as Reynolds-stress transport models, can be corrupted by poor boundary-condition treatment. On the other hand, proper boundary conditions cannot make up for poor turbulence modelling. Implementing empirical relations in the boundary condition (e.g. MOST functions) for improving the model solution in the stratified surface layer is not straightforward. In numerous models of the ABL, e.g. Freedman and Jacobson (2003) and Alinot and Masson (2005), the near-surface behaviour in the model was adjusted in order to give behaviour according to MOST. However, ABL models are often not fully consistent with MOST (van der Laan et al. 2017) leading to deviations between the model solution and profiles obtained by using MOST. This raises a question as to whether the use of MOST in boundary conditions is the right approach for ABL turbulence models that cannot reproduce the MOST behaviour. In Richards and Hoxey (1993) and Richards and Norris (2011) boundary conditions for the neutrally-stratified ABL were presented that should produce the logarithmic law but results showed anomalous behaviour near the surface, illustrating that the boundary conditions are not fully consistent with the turbulence parametrization used for the ABL. The authors explain that these deviations are due to the discretization of the shear production term in the equation for turbulent kinetic energy.

In the present study we aim to develop a new and consistent treatment for the boundary conditions. By consistency we mean that the boundary conditions are consistent with the parametrized relations used in the ABL model and that the boundary conditions together with the ABL model produce the correct stable and grid-independent near-surface solution. The requirement of our approach is that the grid resolution is fine enough to resolve the near-surface layer where buoyancy effects can be neglected. The boundary-condition treatment that we propose does not involve MOST or other empirically-derived relations.

The boundary-condition treatment is developed for the recently proposed explicit algebraic Reynolds-stress (EARS) model. The model has been developed in Lazeroms et al. (2013) and applied in the simulation of the stratified ABL and an ABL involving a diurnal cycle (Lazeroms et al. 2015, 2016). The EARS model is based on algebraic relations that follow from the Reynolds-averaged Navier–Stokes (RANS) equations, ensuring that the model is less dependent on empirical functions and ad hoc corrections than many other ABL turbulence models. We validate the consistency of the boundary-condition treatment and investigate if the EARS model with these boundary conditions is consistent with MOST without a priori involving MOST in the model and boundary-condition development. The complexity of the model requires careful formulations for consistency in the surface layer. The resulting boundary-condition treatment can be implemented in a similar way to simpler ABL turbulence models, for example, models that use the transport equation for the turbulent kinetic energy (TKE).

The following section gives a short model description, while a more detailed derivation of the EARS model is given in the Appendices. Section 3 covers the derivation of the boundary conditions that are responsible for the model’s behaviour near the surface. In Sect. 4 the set-up of the numerical simulation is explained. Finally, in Sect. 5 results are presented in both qualitative and quantitative ways and also a new scaling length is introduced that we refer to as the physical Obukhov length. A summary and discussion are given in Sect. 6.

2 Description of the Turbulence Model

This section gives a description of a single-column model (SCM) version of the recently derived EARS model for the ABL. The description is based on Lazeroms et al. (2016), where the EARS model is derived from the full Reynolds-stress model. Further details about the model derivation are given in Appendices 1 and 2. The so-called, weak-equilibrium assumption is applied that makes the model explicit and somewhat similar to the Mellor and Yamada level-3 model. However, there are significant differences between these two models that are explained in Lazeroms et al. (2016).

The SCM approach is commonly used to model a vertical column of the ABL where statistical variations in the horizontal directions are neglected. The solution is considered to be spatially averaged in the horizontal directions. In the current form, where the flow is considered to be incompressible and molecular diffusion is neglected, the main quantities are the mean horizontal wind velocity \(\mathbf {V} = (U,V)\) and the mean potential temperature \(\varTheta \). The main equations are

$$\begin{aligned} \frac{\text {D}{U}}{\text {D}t}&= -\frac{\partial \,\overline{u'w'}}{\partial z} - f(V_g-V), \end{aligned}$$
(1a)
$$\begin{aligned} \frac{\text {D}{V}}{\text {D}t}&= -\frac{\partial \,\overline{v'w'}}{\partial z} + f(U_g-U), \end{aligned}$$
(1b)
$$\begin{aligned} \frac{\text {D} \varTheta }{\text {D}t}&= - \frac{\partial \,\overline{w'\theta '}}{\partial z}, \end{aligned}$$
(1c)

where \(\text {D}/\text {D}t \equiv \partial /\partial t + \mathbf {V} \cdot \nabla \) is the material derivative in the direction of the mean flow, \(\mathbf {V}_g=(U_g,V_g)\) is the geostrophic velocity, \(f\!=\!2\,\varOmega \sin \phi \) is the Coriolis parameter depending on the rotation rate \(\varOmega \) of the Earth and \(\phi \) is the latitude. The quantities \(\overline{u'w'}\) and \(\overline{v'w'}\) are the vertical components of the turbulent momentum flux and \(\overline{w'\theta '}\) is the vertical component of the turbulent heat flux.

All turbulent fluxes are expressed in terms of correlations of the velocity fluctuations \((u',v',w')\) and temperature fluctuation \(\theta '\), which are parametrized in terms of the mean wind speed and mean potential temperature. The EARS model is an advanced turbulence model that predicts the full Reynolds-stress tensor and heat-flux vector thereby, e.g. being able to account for anisotropy and horizontal fluxes. More information about the horizontal turbulent fluxes and model details can be found in Appendix 1. Using the SCM approach the vertical fluxes appearing in (1) are more important than the horizontal fluxes, and are expressed as

$$\begin{aligned} \overline{u'w'}&= -\nu _t \frac{\partial U}{\partial z}, \end{aligned}$$
(2a)
$$\begin{aligned} \overline{v'w'}&= -\nu _t \frac{\partial V}{\partial z}, \end{aligned}$$
(2b)
$$\begin{aligned} \overline{w'\theta '}&= -\kappa _t \frac{\partial \varTheta }{\partial z}+\varPhi , \end{aligned}$$
(2c)

where \(\nu _t\) and \(\kappa _t\) are the eddy viscosity and eddy diffusivity (the latter is also known as the eddy thermal diffusivity), respectively, and \(\varPhi \) is an additional term. These terms can be expressed as

$$\begin{aligned} \nu _t&= \frac{K^2}{\epsilon } f_\text {m}, \end{aligned}$$
(3a)
$$\begin{aligned} \kappa _t&= \frac{K^2}{\epsilon } f_\text {h}, \end{aligned}$$
(3b)
$$\begin{aligned} \varPhi&= \frac{g}{T_0}\frac{K K_\theta }{\epsilon } f_{\varPhi }, \end{aligned}$$
(3c)

where \(K = (\overline{u'u'}+\overline{v'v'}+\overline{w'w'})/2\) is the TKE, \(K_\theta = \overline{\theta '\theta '}/2\) is half the potential temperature variance, \(\epsilon \) is the dissipation rate of TKE, \(T_0\) is the reference temperature, g is the acceleration due to gravity and \(f_\text {m}, f_\text {h}, f_{\varPhi }\) are the core functions of the model.

Instead of relying on empirical model constants as in many eddy-viscosity and eddy-diffusivity models derived using the Boussinesq approximation (Boussinesq 1897) or K-theory closure, the EARS model has non-constant core functions following directly from the model derivation. These are derived from the algebraic approximations of the transport equations for the normalized Reynolds-stress tensor and normalized turbulent heat-flux vector. Core functions contain model parameters that have been calibrated for various generic flow cases and not only atmospheric flows (Wallin and Johansson 2000; Wikström et al. 2000; Lazeroms et al. 2013, 2016), which makes the EARS model more general and applicable to different stratified and non-stratified turbulent flows. Full details on core functions are found in Lazeroms et al. (2015, 2016) and in Appendix 1.

In order to close the expressions in (3) the \(K-\epsilon \) model together with a prognostic equation for \(K_\theta \) are used, leading to three additional transport equations

$$\begin{aligned} \frac{\text {D} K}{\text {D} t} =&\underbrace{-\overline{u'w'}\frac{\partial U}{\partial z} -\overline{v'w'}\frac{\partial V}{\partial z}}_{\mathcal {P}} -{\epsilon } + \underbrace{\frac{g}{T_0} \overline{w'\theta '}}_{{\mathcal {G}}}+\underbrace{\frac{\partial }{\partial z} \left( \frac{\nu _t}{\sigma _K}\frac{\partial K}{\partial z} \right) }_{\mathcal {D}_K}, \end{aligned}$$
(4a)
$$\begin{aligned} \frac{\text {D} \epsilon }{\text {D} t} =&\,{C_{\epsilon 1} \frac{\epsilon }{K}{\mathcal {P}}}-{C_{\epsilon 2} \frac{\epsilon }{K} \epsilon }+ {C_{\epsilon 3} \frac{\epsilon }{K}{\mathcal {G}}}+\underbrace{\frac{\partial }{\partial z} \left( \frac{\nu _t}{\sigma _\epsilon }\frac{\partial \,\epsilon }{\partial z} \right) }_{\mathcal {D}_\epsilon } , \end{aligned}$$
(4b)
$$\begin{aligned} \frac{\text {D} K_\theta }{\text {D} t} =&\underbrace{-\overline{w'\theta '}\frac{\partial \varTheta }{\partial z}}_ {{\mathcal {P}}_{\theta }}-\underbrace{\frac{K_\theta }{rK}\epsilon }_{\epsilon _{\theta }}+\underbrace{\frac{\partial }{\partial z} \left( \frac{\nu _t}{\sigma _{K_{\theta }}}\frac{\partial K_{\theta }}{\partial z} \right) }_{\mathcal {D}_{K_\theta }} , \end{aligned}$$
(4c)

where \(K/\epsilon \) represents the time scale for turbulence and r is the ratio between the two time scales \(K_\theta /\epsilon _{\theta }\) and \(K/\epsilon \). The terms \({\mathcal {P}}\) and \({\mathcal {G}}\) represent the production of TKE due to shear and buoyancy effects (source terms), \(\epsilon \) is a sink term, \(\mathcal {D}_{K,\epsilon ,K_\theta }\) is diffusion (transport terms) and \({\mathcal {P}}_{\theta }\) production of \(K_\theta \) due to buoyancy and atmospheric stratification. In the EARS model the source terms \({\mathcal {P}}\) and \({\mathcal {G}}\) are given in closed form, which implies that these terms are exactly represented without further modelling, and in contrast with simpler turbulence models. The model parameters follow from earlier studies: \(C_{\epsilon 1}=1.44\), \(C_{\epsilon 2}=1.92\), \(C_{\epsilon 3}=-0.8\), \(\sigma _K=\sigma _{K_{\theta }}=1.0\), \(\sigma _{\epsilon }=1.3\) and \(r=0.55\).

Many other turbulence models use the eddy-viscosity/eddy-diffusivity (EVD) hypothesis together with empirical functions in order to determine the turbulence length scale, as in Blackadar (1962). A group of more advanced EVD models such as the Mellor–Yamada 2.5-level model (Mellor and Yamada 1982) can be derived from simplifying the RANS equation. Besides a transport equation for TKE this model uses a prognostic equation for the length scale that contains an empirical correction term. Another EVD approach based on two-equation modelling, used in ABL modelling for wind-energy applications, is to use the \(K-\epsilon \) model. The model behaviour is controlled by tuning the coefficients and modelling them as empirical functions of Richardson number and a length scale limiter (Koblitz et al. 2015; Rodrigo et al. 2017). Such models are to a large extent empirical and typically use integral relations. They are derived and calibrated for statistically quasi-steady situations, and are unable to capture the effects of local turbulence in more general cases, for example during the morning and evening transition periods with residual turbulence and turbulence in a growing layer. Compared to these models, the EARS model is not based on the EVD hypothesis and has less dependence on empirical functions.

3 Boundary-Condition Treatment

Close to the surface, the turbulent length scale is smaller than the Ozmidov scale (Zonta and Soldati 2018). Therefore, neutral conditions used for setting the boundary-condition treatment are locally neutral in the sense that the buoyancy effects vanish close to the surface, also in the stratified ABL. It is common practice to use the roughness length for boundary-condition treatment in the ABL. The surface influence on the flow is modelled by the roughness lengths \(z_0\) and \(z_{0_h}\) for vertical profiles of the wind speed and potential temperature (Wyngaard 2010; Foken and Nappo 2008), i.e.

$$\begin{aligned} \frac{{\mathbb {V}}(z)}{u_*} = \frac{1}{\varkappa } \ln {\frac{z}{z_0}}, \end{aligned}$$
(5)

for the mean wind speed, where \(u_*\) is the friction velocity, \({\mathbb {V}}=\sqrt{U^2+V^2}\) and \(\varkappa = 0.4\) is the von Kármán constant according to Högström (1996), and

$$\begin{aligned} \frac{\varTheta (z)-\varTheta (z_{0_h})}{\theta _*} = \frac{Pr_t}{\varkappa }\ln {\frac{z}{z_{0_h}}} , \end{aligned}$$
(6)

for the mean potential temperature profile, where \(\theta _*\) is the characteristic temperature scale, \(\varTheta (z_{0_h})\) is the potential temperature at height \(z_{0_h}\) and \(Pr_t\) is the turbulent Prandtl number defined as the ratio between the eddy viscosity and eddy diffusivity, \(\nu _t\) and \(\kappa _t\) respectively.

The boundary conditions are prescribed at \(z_0\), and in order to have a consistent model both boundary conditions and modelled solution must satisfy the proper logarithmic law at the points closest to the ground. Having consistent boundary conditions, however, is not straightforward due to the strong non-linear coupling between the solution, boundary conditions, surface fluxes and model \(K - \epsilon - K_{\theta }\) equations. Aside from the solution being consistent with the logarithmic law it also should be grid independent and the formulation must be numerically stable in all parameter regimes.

The boundary conditions influence the model solution in the surface layer, and a consistent treatment is crucial for obtaining an accurate solution. The boundary conditions are imposed at the boundary height \(z_0\) as

$$\begin{aligned} U(z_0)&= V(z_0) = 0, \end{aligned}$$
(7)
$$\begin{aligned} \qquad \qquad \varTheta (z_0) =&\,\, \varTheta _{\mathrm {S}}(t) +\frac{Pr_t \, \theta _*}{\varkappa }\ln \frac{z_0}{z_{0_h}}, \end{aligned}$$
(8)

where \(z_0\) is defined as the location where the artificially extended logarithmic profile for wind speed reaches zero. Similarly, \(\varTheta _S\) is the temperature at \(z_{0_h}\), representing the surface temperature. The temperature offset between \(z=z_{0_h}\) and \(z_0\) is given by the last term in (8), following the logarithmic law for \(\varTheta (z)\). In the present study a time-dependent function \(\varTheta _{\mathrm {S}}\) represents the surface forcing of the ABL.

From the transport equations for TKE and \(K_{\theta }\), (4a) and (4c), and assuming that the ABL is in quasi-stationary state so that the time and advective derivatives as well as the diffusion terms can be neglected, and by using the logarithmic law for neutrally-stratified boundary layer, \({\mathcal {P}} = \epsilon \) and \(\mathcal {P_{\theta }} = \epsilon _\theta \), we can derive the following boundary conditions

$$\begin{aligned} K(z_0)&= \frac{{u_*}\!^2}{\sqrt{{f_\text {m}^{}}}}, \end{aligned}$$
(9)
$$\begin{aligned} K_{\theta }(z_0)&= \frac{r Pr_t}{\sqrt{f_\text {m}^{}}}{\theta _*}\!^2. \end{aligned}$$
(10)

The core function \(f_\text {m}\) in the EARS model acts as a generalization of the coefficient \(C_\mu \) used in standard eddy-viscosity models (Richards and Hoxey 1993; Richards and Norris 2011). Usually, \(Pr_t\) is given as an explicit constant but in the EARS model it is expressed as a part of the solution using \(Pr_t = f_\text {m}/f_\text {h}\). For neutral stratification it can be shown that the EARS model predicts \(f_\mathrm{m} = 0.087\) and \(Pr_t = 0.75\). Therefore, these constants are used for setting the boundary conditions in order to have a consistent solution in the interior and at the boundaries.

In the following, details of the numerical implementation of the boundary conditions are given for a cell-centred scheme in a finite volume context. Surface-flux related quantities \(u_*\) and \(\theta _*\) are estimated at the height of the first cell centre \(z_1\) respectively from the logarithmic law for \({\mathbb {V}}(z)\) (Eq. 5) and the surface-heat-flux scaling relation as

$$\begin{aligned} u_*&= \frac{\varkappa }{\ln {z_1}/{z_{0}}}{\mathbb {V}}(z_1), \end{aligned}$$
(11)
$$\begin{aligned} \theta _*&= -\frac{\overline{w'\theta '}_s}{u_*}, \end{aligned}$$
(12)

where \(\overline{w'\theta '}_s\) is the kinematic heat flux obtained by using (2c). Finally, the boundary condition for \(\epsilon \) is derived from the balance relation between the dissipation and production terms in the logarithmic layer

$$\begin{aligned} \epsilon = {\mathcal {P}} = {u_*}\!^2 \frac{\text {d}{\mathbb {V}}}{\text {d}z}, \end{aligned}$$
(13)

where the last step is an approximation of the production term that is valid only in the surface layer. Together with the differential form of (5), expanded in finite differences at the height \(z_1\), and (11) it gives

$$\begin{aligned} \epsilon (z_0) = \frac{{u_*}\!^3}{\varkappa (z_1-z_0)} \ln {\frac{z_1}{z_0}}. \end{aligned}$$
(14)

Equation 14 is an approximation of the standard logarithmic law and using L’Hôpital’s rule it can be shown that, in the limiting case \(z_1 \rightarrow z_0\), it becomes \(\epsilon =u_*^3/\varkappa z_0\). This ensures a balance between the production term and dissipation at the height where the boundary conditions are set. The boundary conditions in (7)–(10) and (14), combined with surface fluxes through \(u_*\) and \(\theta _*\) from (11) and (12), are not sufficient to ensure that the solution has the correct physical behaviour near the surface and gives \({\mathcal {P}} = \epsilon \). Therefore, the transport equations (4) need to be modified for the first cell centre to correct the solution in that region. We use

$$\begin{aligned} \frac{\text {D}K}{\text {D}t}&= b({\mathcal {P}}_{log}-\epsilon )+(1-b)\left( {\mathcal {P}}-\epsilon + {\mathcal {G}} + \mathcal {D}_K\right) , \end{aligned}$$
(15a)
$$\begin{aligned} \frac{\text {D}\epsilon }{\text {D}t}&= b({\epsilon }_{log}-\epsilon )p+(1-b)\left( \frac{\epsilon }{K} \left( C_{\epsilon 1}{\mathcal {P}}-C_{\epsilon 2}\epsilon +C_{\epsilon 3}{\mathcal {G}}\right) + \mathcal {D}_\epsilon \right) , \end{aligned}$$
(15b)
$$\begin{aligned} \frac{\text {D}K_{\theta }}{\text {D}t}&= b({\mathcal {P}}_{\theta }-\epsilon _{\theta })+(1-b)\left( {\mathcal {P}}_{\theta } -\epsilon _{\theta } + \mathcal {D}_{K_\theta }\right) , \end{aligned}$$
(15c)

where \(b = 1\) in the first cell centre and \(b = 0\) everywhere else. This approach eliminates the diffusion terms in (15a) and (15c) for the first cell, making the solution in the first cell centre consistent with the prescribed boundary conditions in (9) and (10). The source term that is responsible for the total production of TKE in the first cell centre is

$$\begin{aligned} {\mathcal {P}}_{log} = \epsilon _{log} = \frac{{u_*}\!^3}{\varkappa z_1} = \frac{{u_*}\!^4}{\varkappa {f_\text {m}}^{\frac{1}{4}}K^{\frac{1}{2}}z_1}, \end{aligned}$$
(16)

where the last step is added using relation (9) for improved numerical stability. The first term in (15b) is introduced to relax the value of dissipation rate in the first cell towards

$$\begin{aligned} \epsilon _{log} = \frac{{u_*}\!^3}{\varkappa z_1} = \frac{{f_\text {m}}^\frac{3}{4}K^{\frac{3}{2}}}{\varkappa z_1}, \end{aligned}$$
(17)

where the value \(p = 0.5/\varDelta t\) ensures that in the first cell \(\epsilon = \epsilon _{log}\) is valid at every timestep. Introducing the parameters b and p in the transport equations is a way of predefining the solution for turbulent properties in the first cell according to the logarithmic law. The current method is very similar to that in Sørensen (1995) for non-stratified flows where \({\mathcal {P}}\) and \(\epsilon \) are predefined according to the logarithmic-law relation \({\mathcal {P}}=\epsilon \) and diffusion terms are neglected. Equations 16 and 17 share the same form, because they have to be consistent with the predefined boundary conditions \({\mathcal {P}} = \epsilon \) near the surface (when \({\mathcal {G}}\rightarrow 0\)), although numerically they are expected to behave differently. For numerical stability reasons it is convenient to express these equations as a function of K, with the source term inversely proportional to TKE and the sink term directly proportional to TKE. This implies that for larger values of K the system tends to limit the growth of TKE, which leads to improved stability of the simulations. Although this is a somewhat hand-waving argument, a full numerical stability treatment is beyond the scope of the present study. The scheme of the proposed boundary-condition treatment, following the description, is illustrated in Fig. 1.

Fig. 1
figure 1

Scheme of the boundary-condition treatment applied on a stretched grid. The height of \(z_0\) is exaggerated in order to visualize the scheme

4 Case Description

The boundary-condition treatment is tested in the idealized version of the second Global Energy and Water cycle Experiment (GEWEX) Atmospheric Boundary Layer Study (GABLS2) case, which is based on the recent intercomparison study (Svensson et al. 2011). Compared to the original GABLS2 case, for the sake of simplicity we have adapted the approach used in Rodrigo et al. (2017) and neglected the small subsidence that linearly increases with height, as well as humidity since its effect on the mean wind speed and potential temperature is not significant due to the very dry environment. Simulating the transition between the stable and unstable stratifications is an ideal case to test the consistency and stability of the new boundary-condition treatment.

The diurnal cycle is considered for three levels of grid refinement, with the size of the first grid cell \(\varDelta = (0.5, \, 1, \, 1.75)\;\text {m}\) and a total of \(N= (60, \, 40, \, 22)\) grid points between the ground and the height of \(65\;\text {m}\). The grids are log-linearly distributed (stretched) with finer resolution near the surface and coarser higher up in the atmosphere. The geostrophic velocity is considered to be constant during the whole simulation and is taken to be \(U_g\!=3\;{\text {m s}}^{-1}\) in the x-direction and \(V_g\!=9\;\text {m s}^{-1}\) in the y-direction. The diurnal cycle is driven by the change in surface temperature \(\varTheta _{\mathrm {S}}\), which forces the ABL to be stably or unstably stratified. Figure 2 shows the variation of the surface temperature during the simulation at the roughness length for the temperature \(z_{0_h}\!=0.1z_0\). The model domain is bounded between the roughness length \(z_0\!=0.03\;\text {m}\) and \(H\!=4000\;\text {m}\). Initial profiles of K, \(\epsilon \) and \(K_\theta \) correspond to an ABL with low turbulence levels. For other initial profiles and parameters we refer to Svensson et al. (2011). Furthermore, the first three hours of the simulation are regarded as the spin-up period of the model and are not considered. The timestep in all simulations is \(\varDelta t = 60\) s.

Since the aim is to test the new treatment of the boundary conditions and not model performance we will not make a comparison with observations and the large-eddy simulations (LES) of GABLS2. Instead, we compare results to theoretical predictions, which are known to be valid in the surface layer. Since MOST functions are not explicitly used in the boundary condition for estimating the surface fluxes, the consistency with these is investigated as well.

Fig. 2
figure 2

Forcing function that is used in the lower boundary condition for \(\varTheta _S\) as a function of time, see Svensson et al. (2011). Results from the time intervals coloured with red and blue are used for the analysis during the unstable and stable part of the day respectively

5 Results

5.1 General Behaviour of Surface Fluxes and Mean Profiles

Fig. 3
figure 3

Time evolution of (a) characteristic temperature and b friction velocity for the grid resolution \(\varDelta = 0.5\;\text {m}\) () , \(1\;\text {m}\) (- - -), and \(1.75\;\text {m}\) ( )

Figure 3 shows the time evolution of \(u_*\) and \(\theta _*\). Although \(u_*\) is explicitly dependent on the height of the first cell centre (\(z_1\approx \varDelta /2\)), the solution is basically grid independent due to the use of proper boundary conditions and their consistency with the turbulence model. When a coarser grid is used \(\theta _*\) slightly deviates during the transition periods of the day. The deviations occur in periods when \(u_*\) is low and \(|\,\theta _*|\) is high; however, they converge to a unique solution as the grid is refined. The deviations are probably related to the strong imbalance between the turbulence momentum and heat flux.

Fig. 4
figure 4

Vertical profiles of (a), b horizontal wind speed and c scaled horizontal wind speed. Results at 0200 LT stable (blue) and 1400 LT unstable (red) ABL correspond to the periods marked in Fig. 2. Legend as in Fig. 3, with the addition of green points at the height of first cell centre \(z_1\) for different grid resolutions and (- - -) representing a \(1/\varkappa \) slope for the neutrally-stratified ABL

Figures 4 and 5 show \({\mathbb {V}}(z)\) and \(\varTheta (z)\) at 1400 LT and 0200 LT in the near-surface region from the periods marked in red and blue in Fig. 2 when the ABL is unstably and stably stratified, respectively. The results are shown starting from the height \(z_0\) where the boundary conditions are set. The results for different grid resolutions coincide well, showing that the profiles for \({\mathbb {V}} \) and \(\varTheta \) are grid independent. Figure 4c shows that the slope of the non-dimensional wind-speed profile \({\mathbb {V}}/u_*\) in the first several grid points is \(1/ \varkappa \), in accordance with the logarithmic law for neutrally-stratified conditions given by (5). Similarly in Fig. 5c, the slope of the non-dimensional potential temperature profile \(\bigr (\varTheta (z)-\varTheta (z_0)\bigr )/ \theta _*\) in the lowest cell centres is in good agreement with the logarithmic law given by (6).

In Richards and Norris (2011) a good agreement is obtained with the logarithmic law but with a slight deviation in the lowest grid points, considered to be a result of an inconsistency in the discretization of the production term. Results in the first few cell centres obtained with the present boundary-condition treatment, presented in Fig. 4c, are closer to the values predicted by (5) than those presented in Richards and Norris (2011). To show the influence of boundary conditions on the model solution at the lowest grid points, our results are plotted from the height \(z_0\) at which at the boundary conditions are set. In Richards and Norris (2011) the results are not shown at the height where the boundary conditions are set, therefore it is unclear if their boundary-condition treatment leads to the correct asymptotic near-surface behaviour.

Fig. 5
figure 5

Vertical profiles of (a), b potential temperature and c scaled difference between the potential temperature and surface temperature. Results at 0200 LT stable (blue) and 1400 LT unstable (red) ABL correspond to the periods marked in Fig. 2. Legend as in Fig. 4, with a difference that ( ) represents the \(Pr_{t}/\varkappa \) slope for the neutrally-stratified ABL

Figures 4c and 5c indicate that the buoyancy effects are negligible close to the wall and that turbulence in this region is driven mainly by the wind shear. Further away from the surface, in the region where the buoyancy effects strongly influence the TKE, \({\mathbb {V}}\) and \(\varTheta \) deviate from the slope that is characteristic for the shear-driven logarithmic layer. The character of the deviation depends on the type of stratification in the ABL. In Fig. 5c the results in the first cell centre at the coarsest resolution for both the stable and unstable ABL deviate slightly from the neutral-stratification results since the production of TKE due to buoyancy at the height of \(z_1\) is not fully negligible.

Results for \({\mathbb {V}}(z)\) and \(\varTheta (z)\) for a stable atmosphere have also been reported in Lazeroms et al. (2016) using the EARS model but with other boundary conditions using a fixed value of \(Pr_t\), which is not consistent with the neutral limit of the EARS model, and \(\theta _*\) was obtained from (6) at the height of the first cell centre. This procedure resulted in an inconsistency between the surface momentum and heat flux causing the \(\varTheta (z)\) profile to deviate from the logarithmic law, and also (12) was not valid in the surface layer. The present formulation allows \(Pr_t = \nu _t / \kappa _t\) to change dynamically, while using (12) for \(\theta _*\) overcomes the previous inconsistency and produces much better results in the region near the surface.

Fig. 6
figure 6

Time evolution of the wind direction interpolated at the height \(z\!=\!1\,\text {m}\) (\(0^{\circ }\) mean that the mean flow is directed towards north and \(-90^{\circ }\) towards east). Legend is the same as in Fig. 3

Results for wind direction for different grids interpolated to the same height are shown in Fig. 6. When the solution is interpolated to the height \(z\!=\!1\,\text {m}\), which is lower than the height of the first cell in the case of the coarsest grid, the model results are still consistent with the results from the two finer grids. Also at other heights (not shown) the wind direction is independent of the grid resolution.

In the context of turbulence model behaviour, it is relevant to investigate the total vertical momentum flux in the direction of the horizontal mean flow \({\overline{u^{\prime } w^{\prime }}}^{T}\), i.e.

$$\begin{aligned} \overline{u^{\prime } w^{\prime }}^{T} = \overline{u^{\prime } w^{\prime }} \frac{U}{\sqrt{U^2 + V^2}}+ \overline{v^{\prime } w^{\prime }} \frac{V}{\sqrt{U^2 + V^2}}. \end{aligned}$$
(18)

Figure 7 shows that the scaled total vertical turbulent momentum-flux profile tends to \(-1\) when approaching the surface, which is consistent with the surface-layer scaling \(\overline{u^{\prime } w^{\prime }}^{T}\!/{u_*}\!^2=-1\). The deviations for different grid resolutions for the unstable surface layer are related to the deviation of \(u_*\) (Fig. 3) during the convective part of the day. Since the turbulent fluxes are scaled with \({u_*}^2\) this error is emphasized. Figure 7 illustrates that the turbulence modelling is consistent with the boundary-condition treatment and the way \(u_*\) is computed using the roughness-length model.

Aside from the quantities presented above, the EARS model also predicts turbulence properties such as anisotropy and horizontal fluxes for the SCM solution. For instance, Fig. 8 shows not only that the EARS model predicts anisotropy but also that it predicts suppressed and increased vertical mixing, respectively, for the stably- and unstably-stratified ABL. The boundary-condition treatment controls the solution of the EARS model at the points closest to the ground making \(\overline{u^{\prime } u^{\prime }}, \, \overline{v^{\prime } v^{\prime }}\) and \(\overline{w^{\prime } w^{\prime }}\) profiles consistent and grid independent (not shown). An important difference as compared to EVD models is that these simpler models predict horizontal and vertical correlations \(\overline{u^{\prime } u^{\prime }} = \overline{v^{\prime } v^{\prime }} = \overline{w^{\prime } w^{\prime }} = (2/3) K\).

Additionally, the EARS model with the improved boundary-condition treatment was tested for the GABLS2 case using the offshore values of roughness length \(z_0=10^{-4}\) m. The results show the same grid-independent behaviour as the results for the original GABLS2 test case reported in this section.

Fig. 7
figure 7

Vertical profiles of \(\overline{u^{\prime } w^{\prime }}^{T}\) for a 0200 LT stable, and b 1400 LT unstable ABL. Time instances correspond to the periods marked in Fig. 2. Legends as in Fig. 3

Fig. 8
figure 8

Vertical profiles of non-dimensional \(\overline{u^{\prime } u^{\prime }}, \, \overline{v^{\prime } v^{\prime }}\) and \(\overline{w^{\prime } w^{\prime }}\) for a 0200 LT stable and b 1400 LT unstable ABL. Time instances correspond to the periods marked in Fig. 2

5.2 Monin–Obukhov Similarity Theory

The accuracy of the EARS model with the previously proposed boundary-condition treatment is tested by comparing the results with experimentally obtained MOST profiles (Businger et al. 1971; Högström 1988). MOST postulates the existence of dimensionless universal functions, \(\phi _\text {M}\) and \(\phi _\text {H}\), for the \({\mathbb {V}}(z)\) and \(\varTheta (z)\), i.e.

$$\begin{aligned} \frac{\partial {\mathbb {V}}}{\partial z}&= \frac{u_*}{\varkappa z} \phi _\text {M}\left( \frac{z}{L}\right) , \end{aligned}$$
(19a)
$$\begin{aligned} \frac{\partial \varTheta }{\partial z}&= \frac{\theta _*}{\varkappa z} \phi _\text {H}\left( \frac{z}{L}\right) . \end{aligned}$$
(19b)

Usually, it is assumed that the universal functions depend on only one dimensionless groupFootnote 1\(\xi = z/L\), where L is the Obukhov length defined as

$$\begin{aligned} L = - \frac{u_*^3T_0}{\varkappa g\overline{w^{\prime }\theta ^{\prime }}_s} = \frac{u_*^2T_0}{\varkappa g\theta _*}, \end{aligned}$$
(20)

where the latter form is obtained by using (12). MOST has been validated by numerous atmospheric experiments, and the functions \(\phi _\text {M}\) and \(\phi _\text {H}\) have been determined from atmospheric measurements (Foken 2006) and more recently from high-resolution LES of the ABL (Maronga 2014; Maronga and Reuder 2017). Most commonly referred shapes of the universal functions are given in Businger et al. (1971), which were obtained from the Kansas experiment, and in Högström (1988).

Fig. 9
figure 9

Scaled profiles showing stability function for a horizontal wind speed, and b potential temperature plotted against the stability parameter, obtained by scaling the height with the physical Obukhov length \(L_{\varDelta }\) (blue) and classical Obukhov length L (yellow); Experimental data: (- - -) from Businger et al. (1971) and ( ) from Högström (1988)

Results of the simulation with the finest grid resolution, corresponding to the marked periods in Fig. 2, are cast in form of dimensionless functions \(\phi _\text {M}\) and \(\phi _\text {H}\) using (19). The dimensionless group \(\xi \) was obtained by scaling the height at which the results were taken by the Obukhov length. In the present analysis, two different formulations for the Obukhov length are used: the classical formulation for defining L from (20) in terms of near-surface local conditions, and the presently introduced physical Obukhov length\(L_{\varDelta }\) defined as the height where the buoyancy term \({\mathcal {G}}(z)\) in (4a) equals the shear production. Appendix 3 contains a detailed explanation of \(L_{\varDelta }\). It should be pointed out that the calculation of \(L_\varDelta \) would require an analysis of the boundary layer in the vertical direction. The classical Obukhov length, on the other hand, is completely expressed in terms of surface fluxes.

Figure 9 shows that the model results in the surface layer agree with the scaling predictions of MOST. That is to say, when \({\mathbb {V}}\) and \(\varTheta \) are scaled appropriately, as in (19), the results collapse and form functional dependences. Thus, the results in Fig. 9 indicate a realistic physical treatment of the turbulence in the EARS model. The results for the stably-stratified surface layer (\(\xi >0\)) agree well with the experimental data. The results scaled with L follow Businger’s data, while the results scaled with \(L_{\varDelta }\) are closer to Högström’s data. Results for the unstably-stratified surface layer (\(\xi <0\)) deviate substantially from the experimental data for both \(\phi _\text {M}\) and \(\phi _\text {H}\), but the prediction is slightly improved for \(\phi _\text {H}\). In Mellor and Yamada (1982) a similar underestimation of \(\phi _\text {M}\) was obtained with the level-2.5 closure model.

In the simulated ideal diurnal cycle the boundary layer undergoes transition from stable to unstable conditions and vice versa, and does not remain neutrally stratified. Consequently, part of the results corresponding to the neutral region (\(z/L \!=\! 0\)) is missing from Fig. 9. In order to obtain results in the near-neutral limit, data are taken near the surface where \(z/L \rightarrow 0\). This requires caution because MOST is not valid on the scale of the roughness length \(z_0\), see discussion in Basu and Lacser (2017). The results are obtained without any tuning of model coefficients with the given experimental data, in contrast to Mellor (1973) where the model coefficients were tuned to match the data. Furthermore, the present model does not rely on MOST functions for calculating \(u_*\) and \(\theta _*\), meaning that MOST is not predefined in the EARS model. This is not so in Chang et al. (2018), where MOST was used as a wall function for estimating \(u_*\) and \(\theta _*\) and then for comparing the profiles of \({\mathbb {V}}(z)\) and \(\varTheta (z)\) predicted by MOST to the model result. Hence, their model results cannot be considered to be independent of the imposed MOST functions.

6 Discussion and Conclusions

New boundary conditions for the recently developed EARS model are proposed. The boundary conditions require that the grid is fine enough for the model to capture the region near the surface where buoyancy effects can be neglected. The surface fluxes are estimated according to the logarithmic law valid for neutral stratification. In order to ensure that the neutral logarithmic law is valid at the height of the first cell centre the conditions \(z_1 < 0.05 L\) and \(z_1 < 0.17 L\) for the finest and coarsest resolution respectively were imposed in the simulation. Our approach is different from that commonly used where surface fluxes are estimated from the empirical Monin–Obukhov functions. The proposed boundary conditions lead to results that agree well with the standard logarithmic law very near the surface. The general approach in this new boundary-condition treatment could also be applied to simpler eddy-viscosity/eddy-diffusivity models, and should be expected to give improvements also there.

Simulations of an idealized diurnal cycle were carried out with different grid resolutions. Results of the vertical profiles for the stable and unstable surface layer indicate that the EARS model with these new boundary conditions predicts the stratified logarithmic law for the mean horizontal wind-speed and mean potential-temperature profiles without using empirical functions. It is shown that the boundary conditions are consistent with turbulence modelling in the EARS model and MOST functions for the stable ABL, and gives a grid-independent solution, with accurate prediction of the surface fluxes, despite the explicit dependence on the height of the first cell centre. Results for the wind direction also give a grid-independent solution even when interpolation is done to a height below the height of the first cell. We emphasize that the present boundary treatment is basically driven by the behaviour of the modelling in the interior and no inconsistency was observed with MOST in Figs. 4 and 5 for stable and unstable conditions. Moreover, in the transition phases between stable and unstable conditions, when the assumptions of MOST are not strictly valid, the boundary conditions are consistent with the interior modelling. This is not explicitly shown but indicated by the grid independence shown in Figs. 3 and 6. Another limitation is that the MOST formulation is not applicable in cases with strong lateral inhomogeneity when there are rapid variations in atmospheric conditions or surface topography. Such conditions should not cause major inconsistencies with the present boundary formulation, although not tested yet.

When expressed in dimensionless MOST form the model results collapsed on to a single curve, forming a clear functional dependence and indicating that the physics is well described by the turbulence model. The comparison with experimentally observed MOST profiles shows good agreement for the stably-stratified surface layer, but there are discrepancies in the unstably-stratified surface layer.