The impact of valley geometry on daytime thermally driven flows and vertical transport processes

The influence of valley geometry on thermally driven flows is studied by means of high‐resolution simulations. An idealized valley–plain topography and a spatially constant but time‐dependent surface sensible heat flux are used to generate upslope, upvalley and plain‐to‐mountain winds. A systematic variation of valley depth, width and length induces differences in the cross‐ and along‐valley flow field and thermal structure of the boundary layer. The deeper the valley, the stronger the upvalley winds and the more favoured the formation of vertically stacked circulation cells and an elevated valley inversion layer. Upvalley winds become weaker for wide valleys. The development of plain‐to‐mountain circulations increases vertical exchange processes between the boundary layer and the free atmosphere considerably, compared with vertical transport processes over a plain. The analysis of mass‐flux budgets and forward trajectories indicates that mass is transported three to four times more effectively from the surface to the free atmosphere over valleys than over flat terrain. Vertical transport processes are strongest for deep and narrow valleys.


Introduction
Thermally driven winds are a well-known flow regime under fair-weather conditions. They develop due to differential heating of adjacent air masses and show regularly changing flow patterns during the day and the night. As the atmosphere is primarily heated or cooled by the Earth's surface, temperature contrasts in the boundary layer are mostly generated by inhomogeneous distributions of land properties (Whiteman, 2000). For example, land-sea breezes develop in regions with adjacent water and land surfaces, whereas mountain-plain circulations are found between flat plains and mountains. As about 50% of the land surface can be considered as complex , thermally driven flows occur over nearly all the world and play an important role for the atmospheric boundary layer. Generally, thermally driven flows over complex terrain can be divided into different types, such as slope flows, along-valley winds and plain-to-mountain circulations (Whiteman, 2000).
Due to their importance for regional weather and climate in complex terrain, thermally driven flows have been intensively studied in the past. The main focus was on the investigation of their dynamics. Here, a key issue was the understanding of differential heating mechanisms, which cause temperature contrasts and associated pressure gradients. By means of analytical methods, it was found that slope winds occur due to temperature differences and related buoyancy effects between heated or cooled air over slopes and adjacent unperturbed air (e.g. Prandtl, 1952). The development of along-valley winds is caused by temperature differences between valleys and adjacent plains. The investigation of the reason for stronger warming and cooling of valleys compared with plains (Vergeiner and Dreiseitl, 1987), during the day and the night respectively, led to different theories. One of the first explanations is the valley volume effect (Wagner, 1938), which attributes the faster heating and cooling of a valley compared with a plain for an equal energy input to the smaller air volume (Steinacker, 1984). Another theory is based on the combination of descending air in the valley centre during the day and generally stably stratified air in the atmosphere above valleys, which leads to warm air advection in the valley core (Rampanelli et al., 2004). In addition, the valley atmosphere is heated from the surface due to the development of a convective boundary layer at the valley floor (Serafin and Zardi, 2010). Schmidli (2013) studied the heating of an idealized valley by means of large eddy simulations (LES) and distinguished between local and bulk perspectives. According to his results, the temperature contrast between valleys and plains cannot be described by subsidence heating (cf. Rampanelli et al., 2004). An appropriate theory is the valley volume effect, which designates the upper limit for enhanced temperatures in valleys. In reality, heating of valleys will be lower, as the valley volume is not a closed system and heat is transported out of the valley volume by cross-and along-valley circulations.
An important feature of thermally driven flows is not only to reduce temperature contrasts, e.g. between a plain and a valley, but also to transport properties like heat, moisture and pollutants both horizontally and vertically over large distances in the boundary layer and to increase the exchange of air masses with the free troposphere aloft. Compared with pure turbulent exchange processes of a convective boundary layer with the free atmosphere over a flat plain, vertical transport mechanisms due to valley and slope winds can be much more effective (Weigel et al., 2007;Rotach et al., 2014). Therefore, thermally driven flows have a strong impact on weather and climate on both local and large scales. The role of thermally driven flows in transporting pollutants from the surface to elevated levels and the free atmosphere is analyzed in Gohm et al. (2009) and Henne et al. (2004) in Alpine valleys, based on measurements. It is shown that upslope winds, in particular, effectively transport pollutants to high levels in the atmosphere.
Thermally driven flows are, however, not only a local phenomenon, but can affect regions within a radius of up to 100 km. This is shown in the Vertical Transport and Orography project (VERTIKATOR: Weissmann et al., 2005), for example. In this investigation, the mountain-plain circulation and corresponding mass flux from the foreland to the mountains were measured. A large mountain range like the European Alps can produce a plain-to-mountain circulation during a summer day, which transports boundary-layer air up to 80-100 km over the foreland towards the Alps. These air masses are then transported vertically by slope winds to the free atmosphere. Weissmann et al. (2005) were able to measure this boundarylayer mass flux towards the Alps, the increasing boundary-layer depth over the mountain range and the return flow in the free atmosphere from the mountains to the foreland.
The appropriate simulation of thermally driven flows with today's operational global numerical weather prediction and regional climate models is not possible, as typical horizontal mesh sizes range from about 5-20 km, which is too coarse to resolve complex terrain with narrow and deep valleys properly (Rotach and Zardi, 2007). Differences in the valley boundarylayer structure, which arise if valleys are fully resolved, smoothed or not resolved by a numerical model, are shown in Wagner et al. (2014). Typical features like valley inversions and vertically stacked cross-valley circulation cells cannot be simulated properly if the valley is strongly smoothed.
In order to improve weather and climate models over mountainous regions, it is necessary to include effects of thermally driven flows in boundary-layer parametrizations. This can be done by quantifying vertical exchange processes over different valley geometries. In this study, a first step in this direction is taken by systematically investigating the impact of valley depth, width and length on the boundary-layer structure, vertical flux profiles and mass transport from the boundary layer to the free atmosphere. The investigations are based on high-resolution simulations to resolve the turbulent-energy-containing large eddies explicitly and to be independent of boundary-layer parametrizations. To demonstrate the effect of thermally driven flows on the boundary layer, average profiles over the valley region are compared with average profiles over the foreland.
The article is organized as follows: in section 2 the numerical model set-up is described, in section 3 the flow decomposition method into mean, resolved and subgrid-scale parts is demonstrated and in section 4 the boundary-layer heights used are defined. Section 5 exhibits the simulation results and a conclusion is given in section 6.
Abbreviations: x horizontal mesh size, VD valley depth, VW valley width, VL valley length, MAX-S maximum slope angle. In the VAL2D case, no foreland exists.
Forecasting model (WRF-ARW), version 3.4 (Skamarock et al., 2008). The WRF model has already been successfully applied for idealized simulations of thermally driven flows on the kilometre scale (Rampanelli et al., 2004;Schmidli et al., 2011;Wagner et al., 2014) and for LES studies (Catalano and Cenedese, 2010;Catalano and Moeng, 2010;Wagner et al., 2014). The WRF model is a non-hydrostatic, fully compressible numerical model, which uses a horizontally staggered Arakawa C grid with a terrain-following dry-hydrostatic pressure vertical coordinate (Skamarock et al., 2008). A third-order Runge-Kutta time integration scheme, fifth-order horizontal and third-order vertical advection scheme are adopted in this study. In LES mode, subgrid-scale turbulence is parametrized by a 1.5 order threedimensional turbulent kinetic energy (TKE) closure (Deardorff, 1980). At the surface, a Monin-Obukhov similarity scheme (Monin and Obukhov, 1954) using four stability regimes of Zhang and Anthes (1982) is applied to momentum and heat fluxes to couple the surface with the first model level. The decomposition of the turbulent flow into resolved and mean components is done according to the method described in Wagner et al. (2014). In order to reduce computational storage resources, a statistics module is implemented in the WRF model, which allows for online averaging and flux computation while the model is integrating.
The valley topography used is similar to the model terrain applied in Schmidli et al. (2011). The modelling domain of the reference set-up (H1500, see Table 1) has an extention of 200 km in the along-valley and 40 km in the cross-valley direction. The topography consists of a 1.5 km deep and 100 km long straight valley and a 100 km long flat foreland (see Figure 1).
The model grid has a horizontal mesh size of 200 m and vertically stretched levels with varying distances from 12 m near the ground to 75 m higher aloft. An additional sensitivity run with 100 m horizontal grid distance is performed to study the influence of horizontal mesh size on the simulation results. The integrating time step is 2.0 s. The model top is set to 8 km, with a Rayleigh damping layer covering the uppermost 2000 m. Solid-wall ('symmetric' in WRF) boundary conditions in the along-valley direction and periodic lateral boundary conditions in the cross-valley direction are applied, resulting in repeating parallel valleys. Solid-wall boundary conditions in the along-valley direction have the same effect as a valley that is twice as long and open on both sides (i.e. reflected in the along-valley direction at y = 100 km, cf. Schmidli and Rotunno, 2010;Schmidli et al., 2011). In both cases, the along-valley flow is decelerated near the end and middle of the valley, respectively, and forced to ascend. This can slow down the along-valley flow if the valley becomes very short. Solid-wall boundary conditions are chosen in this study to reduce the number of grid points in the along-valley direction.
All simulations are initialized with an atmosphere at rest, a constant potential temperature gradient of 3 K km −1 and a potential temperature of 297 K at a pressure of 1000 hPa. A moist unsaturated atmosphere with a constant relative humidity of 40% at the beginning of the simulations is chosen, following the setting of Schmidli (2013). As no clouds are forming with this initial humidity and as no radiation schemes are used in the simulations, a dry atmosphere with a relative humidity of 0% would not change the results significantly. The surface roughness is set to 0.16 m and the thermal forcing is defined by a spatially constant but time-dependent surface sensible heat flux (HFX) according to Rampanelli et al. (2004): with time t, maximum surface heat flux HFX max = 150 W m −2 and angular velocity of the Earth ω = 2π (24 h) −1 . The spatially constant heat flux forcing is used in order to be independent of a land-surface model and the predefinition of soil types, surface albedo and radiative forcing. In the recent study of Schmidli (2013), the flow structure of thermally driven flows driven by a constant surface heat flux is very similar to a flow driven by a variable surface heat flux. In order to trigger convection, randomly distributed potential temperature perturbations with an amplitude of 0.5 K are added to the five lowermost model levels at the beginning of the simulation. All simulations are run for 12 h, with a maximum surface heat flux forcing after 6 h.
As the aim of this study is to investigate the impact of valley depth, width and length on the flow evolution, different sensitivity runs are performed. The sensitivity runs can be divided into three groups: a systematic change of valley depth between 0 and 2000 m, a variation of the valley crest-to-crest width from 20-40 km and a variation of the valley length from 25-100 km. The size of the flat foreland is equal in all three-dimensional sensitivity runs. An additional simulation with a pure valley topography without an adjacent plain is performed to investigate the influence of alongvalley winds on the flow evolution. An overview of the different sensitivity runs is given in Table 1.

Averaging method
The averaging of the high-resolution flow variables is performed according to the approach of Schmidli (2013). The fully turbulent variable ψ(x, t) is split into a model grid-box average ψ(x, t), which is dependent on mesh size and the time step of the numerical model, and a subgrid-scale part ψ (x, t): (2) The resolved turbulent part ψ (x, t) is then computed from the grid-box average by where the time averaging operator is defined as with the time averaging interval T = 40 min. Time averaging is based on a sample interval of 1 min. Test simulations with different averaging intervals indicated that at least 30 min of averaging is necessary to obtain values of resolved turbulent kinetic energy, which are independent of the averaging interval used. The value of 40 min is chosen according to Schmidli (2013), as the valley shape and developing flow in this study are similar to the presented simulations.
The decomposition of fluxes into mean, resolved turbulent and subgrid-scale parts is done according to the method described in Wagner et al. (2014). The computation of mean vertical profiles over the valley and foreland region is done by averaging the corresponding variables along constant-height levels over the valley (y > 0 km) and foreland (y < 0 km), respectively (cf. Wagner et al., 2014). The spatial averaging in the along-valley direction and over the whole valley or foreland region is marked in the figures by [ ] y and [ ] x,y , respectively.

Boundary-layer heights
In this study, three different definitions are used to compute the atmospheric boundary-layer height. In the first definition, a lower boundary-layer height is determined according to Catalano and Moeng (2010) as the altitude where the potential temperature gradient first exceeds a value of 0.001 K m −1 when moving upward from the surface (PBL1). A corresponding upper boundary-layer height is defined as the altitude where the potential temperature gradient falls below the threshold of 0.001 K m −1 when moving downward from the model top (cf. Wagner et al., 2014). PBL1 and PBL2 describe the height of two mixed layers, which are slightly below the altitude of the vertical heat flux minimum (Schmidli, 2013). Over a flat plain, PBL1 and PBL2 are expected to be the same, whereas they can differ in a valley, due to the development of a valley inversion layer between these two mixed layers. The third boundary-layer height PBL3 is defined as the altitude of the maximum potential temperature gradient (Sullivan et al., 1998). PBL3 marks the top of the entrainment zone (Sullivan et al., 1998;Schmidli, 2013) and is located above PBL1 and PBL2. Note that, over the valley, only potential temperature gradients above PBL2 are used to determine PBL3, to avoid large variations in the boundary-layer height due to strong potential temperature gradients in the valley inversion layer. To study transport processes from the boundary layer to the free atmosphere, time-dependent boundary-layer heights are determined by spatially averaging the PBL2 and PBL3 of the PLAIN simulation. These boundary-layer heights are called PLAIN-PBL2 and PLAIN-PBL3, respectively, and are used as reference heights in the following sections. PLAIN-PBL2 marks the top of the mixed layer and is located below the capping inversion, whereas PLAIN-PBL3 defines the top of the entrainment layer and is located above PLAIN-PBL2, as can be seen in Figure 2. A potential temperature gradient threshold of 0.001 K m −1 is used to determine the boundary-layer height PLAIN-PBL2 and the maximum potential temperature gradient is used for PLAIN-PBL3 (see text). Thin contour lines and colour shading show horizontally averaged potential temperature and total vertical heat flux profiles of the PLAIN simulation, respectively. Values for vertical heat fluxes are not available during the first 2 h of simulation, due to time-averaging technical reasons.

Flow structures
In this section, differences in the flow structure within the valley and over the foreland due to varying valley geometries are described. In all simulations, the flow is fully turbulent after about 2 h of simulation. Over the foreland, a convective boundary layer with rising thermals and a plain-to-mountain circulation develops (see Figure 3 for the instantaneous flow after 6 h of simulation). In the valley, convective cells form over the valley floor and are advected upwards by upslope winds. In the valley entrance region, an upvalley flow establishes, which reaches strongest wind speeds in the local afternoon and penetrates up to 80 km into the valley in the reference run (as a threshold to detect the penetrating wind, a mean along-valley wind larger than 0.2 m s −1 is used).
To compare the cross-valley circulations of the different sensitivity runs, the temporally averaged flow fields are spatially averaged in the valley entrance region within a 10 km interval (5 km ≤ y ≤15 km; see Figures 4 and 5). In the PLAIN simulation (without valley topography, Figure 4(a)), no directed flow develops and the boundary-layer height is found between 1.3 km (PBL1, PBL2) and 1.5 km (PBL3) above ground level (AGL) after   Figure 4, but for additional set-ups (see Table 1). middle of the valley. If the valley is very shallow (H0500, Figure 4(b)), upslope winds are weaker (maximum values about 1.5 m s −1 ) and the upslope wind layer is deeper (maximum depth about 0.6 km) than in the reference run ( Figure 4(d)), with upslope winds up to 2.4 m s −1 and a slope wind depth of 0.25-0.5 km. Differences in upslope winds are also visible in vertical profiles of cross-valley winds averaged between y = 5 and y = 15 km near the valley floor, at midslope position and near the ridge ( Figure 6). Deep valleys show shallower upslope wind layers and a stronger increase of upslope wind speed towards the mountain ridge. Differences in upslope winds may be explained by different and time-dependent background stabilities in the valley (e.g. neutral stratification in the H0500 case and valley inversions in deeper valleys). In shallow valleys like in the H0500 and H1000 runs (Figure 4(b) and (c)), the cross-valley flow consists of only one circulation cell, whereas deep valleys (H1500 and H2000, Figure 4(d) and (e)) show two vertically stacked circulations, separated by a valley inversion layer. The different stratification in the dependence of valley depth is indicated by the two mixed-layer heights PBL1 and PBL2, which are similar for valley depths up to 1000 m but become different for deeper valleys (Figure 4). The vertically stacked circulation cells are also visible in the midslope vertical profile of upslope wind speed ( Figure 6(b)), by means of alternating positive and negative wind speeds with height for deep valleys (e.g. H1500 and H2000). Similar results for the thermal structure in the valley were found in Wagner et al. (2014), where valley inversions were eroded by the growing convective boundary layer in strongly smoothed and therefore shallow valleys. In this model set-up, the valley inversion in the H1500 and H2000 runs becomes weaker in time but exists throughout the whole simulation period (not shown).
Valley depth also influences the along-valley flow (Figure 4). The deeper the valley, the stronger the upvalley wind becomes. In the H0500 run, upvalley winds remain below 1 m s −1 after 6 h of simulation, whereas they almost reach 3 m s −1 (4 m s −1 after 11 h of simulation) in the H1500 and H2000 runs. Stronger upvalley winds are related to higher wind speeds in the return flow towards the foreland in upper levels. This means that the mountain-plain circulation intensifies with depth of the valley chosen.
The increase of valley width from 20 to 30 and 40 km (Figure 5(a) and (b)) does not change the upslope flow significantly compared with the H1500 run (cf. Figure 6), as the slope steepness and valley depth remain the same. In both the W30 and W40 runs, a valley inversion layer exists. However, the vertically stacked circulation cells are less developed and alongvalley wind speeds are lower (about 1 m s −1 ) than in the H1500 run (Figure 4(d)). This means that the plain-to-mountain flow weakens and the cross-valley circulation dominates for wider valleys. In the W30 run, two mixed layers exist (PBL1 and PBL2 are separated), whereas a less well-mixed upper layer remains over the valley centre for wider valleys (W40).
Valley lengths larger than 50 km do not change the flow structure in the valley considerably (not shown). If the valley is, however, very short, the along-valley flow weakens substantially, as the flow reaches the valley end quickly and is decelerated due to the solid-wall boundary conditions. Test simulations of the L25 case with a 50 km long valley, which is open on both sides and with periodic boundary conditions in the along-valley direction (cf. section 2), produced the same flow as the L25 case (not shown). The cross-valley circulation in the L25 run (Figure 5(c)) is similar to the H1500 simulation, but upvalley winds only reach values of 1 m s −1 .
An additional simulation of the reference run with a higher horizontal grid resolution of 100 m (DX100, Figure 5(d)) does not change the general flow pattern. Both along-valley winds and vertical profiles of upslope wind speeds of the DX100 case ( Figure 6) show very similar values to the reference run ( Figure 4(d)). This permits us to use a mesh size of 200 m for all sensitivity runs, which reduces the storage resources by a factor of 4.
The influence of along-valley wind on the boundary-layer structure in a valley is demonstrated by a simulation without an adjacent plain (VAL2D, Figure 5(e)). The cross-valley circulation is comparable to the H1500 run. Potential temperatures near the valley floor are about 0.5 K cooler in the reference run compared with the VAL2D simulation, due to cold air advection by alongvalley winds in the three-dimensional set-up. This leads to a slightly stronger and thicker valley inversion layer in simulations with a valley-plain topography.
The temporally averaged along-valley flow in the valley centre (x = 0 km) after 6 h of simulation is plotted in Figure 7. In the H0500 run, the up-valley wind is very weak and the flow in the valley centre is dominated by a convective boundary layer with rising thermals. In this case, the mixed-layer heights (PBL1 and PBL2) over the valley are similar to the mixed-layer heights over the foreland and much higher than the mountain ridges. The top of the entrainment layer (PBL3), however, is higher over the valley than over the foreland, due to stronger thermals over the mountain ridges. For deeper valleys, the along-valley circulation with up-valley flow near the surface and a return flow above becomes dominant. The valley flow and the return flow are separated by the valley inversion layer. The two mixing-layer heights PBL1 and PBL2 are identical over the foreland, but are separated into a lower and upper mixed-layer height in the valley. Both PBL2 and PBL3 are much higher over the valley than over the foreland. As the return flow is located above PBL2 and PBL3 of the plain and advances up to 80 km over the foreland (not shown) in the reference run, the upvalley and mountain-plain circulation transports air mass from the boundary layer to the free atmosphere. This mechanism intensifies for deeper valleys (e.g. H2000) and weakens with increasing valley width (e.g. W40).

Average profiles
To investigate differences in the boundary-layer structure caused by different valley geometries, mean vertical profiles of characteristic variables are computed over the foreland and valley region. The averaging is performed along constant height levels by interpolating the relevant variables on a Cartesian grid. The averaging region is defined between the mountain crests in crossvalley direction (e.g. x = −10 to 10 km for the H1500 case) and over the whole foreland and valley length in along-valley direction (e.g. for the H1500 case y = −100 to 0 km for the foreland and y = 0 to 100 km for the valley region). Figure 8 shows mean profiles for potential temperature, along-valley and vertical wind speed over the foreland and the valley regions, respectively. All simulations show nearly identical vertical profiles of potential temperature over the foreland (Figure 8(a)), with typical features of a convective boundary layer like superadiabatic stratification near the surface, a capping inversion at about 1.5 km and a well-mixed layer in between. Over the valley region (Figure 8(b)), mean potential temperature profiles of deep valleys (H1500 and H2000) show a three-layer thermal structure (Vergeiner and Dreiseitl, 1987;Schmidli, 2013) with an additional valley inversion layer. Valleys with a width of 20 km (e.g. H1500) develop about 1 K warmer temperatures in the lower boundary layer than the PLAIN simulation. The wider the valley, the cooler the potential temperatures and the smaller the horizontal temperature gradient between foreland and valley is, due to the valley volume effect (e.g. W30 and W40 runs).
Mean profiles of along-valley wind over the foreland (Figure 8(c)) show the plain-to-mountain circulation in the boundary layer and a jet-like return flow above the boundary layer. Both the flow towards the mountains near the surface and the return flow are strongest for deep and narrow valleys. The average upvalley flow in the valley region (Figure 8(d)) is strongest for deep valleys and about 1.5-2.5 times larger than the flow over the foreland. Upvalley flow is very weak and of the same magnitude as the plain-to-mountain wind for the W30, W40 and H0500 cases on average. The mean return flow over the valley is slightly weaker than over the foreland (cf. Figure 7) and shows a local minimum at the altitude where the cross-valley return flow transports air from above the mountain ridges to the valley centre (cf. Figure 4). This cross-valley return flow warms the atmosphere locally at these heights and weakens the horizontal pressure gradient and hence the along-valley flow.
The average of vertical wind speed reveals quite low values of the order of 10 −2 m s −1 (Figure 8(e) and (f)). Over the foreland, weak subsidence predominates within the whole boundary layer and the free atmosphere above. In the valley, mean upward motion is visible, with the highest values for short and deep valley geometries. To test whether the strong upward motions of the L25, L50 and L75 runs is caused by the different along-valley averaging lengths, mean vertical profiles are calculated over the valley between y = 0 and 25 km for all simulations (not shown). This smaller averaging region does not change the mean vertical wind-speed profile significantly and only slightly increases upward motions in cases with 100 km long valleys (e.g. H1500). The mean profiles shown in Figure 8 reveal the average mass transport of air from the foreland to the valley, up to higher altitudes and back into the free atmosphere above the foreland. Figure 9 shows mean profiles of subgrid-scale, resolved turbulent, mean and total vertical sensible heat flux over the foreland and the valley region. Over the foreland, subgrid-scale heat fluxes are identical for all simulations and exhibit typical profiles for a LES convective boundary layer with maximum values near the surface. Over the valley, the profiles look very similar to those over the foreland, but additional secondary heat flux maxima are visible at the respective mountain ridge heights. Resolved fluxes over the foreland are similar for all simulations, with maximum heat fluxes of nearly 140 W m −2 at about 0.2 km AGL and negative values of about −40 W m −2 in the entrainment layer at about 1.3-1.4 km AGL. The relatively high entrainment heat fluxes are probably induced by the rather coarse horizontal resolution of 200 m. Test simulations over a flat plain with a horizontal mesh size of 50 m showed lower entrainment heat fluxes of −30 W m −2 (not shown). Differences arise over the valley region, where additional heat flux maxima are found over the mountain ridges, due to increased turbulence in strong convective cells (the region where slope winds converge, cf. Figure 4). For deep and narrow valleys (e.g. H1500, H2000), negative resolved heat fluxes in the entrainment layer are very weak. They become more dominant for wider valleys (e.g. W30 and W40). Mean vertical heat fluxes are zero over the foreland, but show positive values in the valley due to mean ascending motions (cf. Figure 8) and positive potential temperature perturbationŝ θ = θ − θ 0 (z), where θ 0 (z) is a spatial average of θ at a certain height level (see Wagner et al., 2014). This was also shown in Schmidli (2013). Total heat fluxes over the foreland show typical profiles for a convective boundary layer over a flat plain, with linearly decreasing values in the boundary layer and negative heat fluxes in the entrainment layer. Over the valley, heat fluxes are larger than over the plain at the corresponding levels and show additional heat flux maxima at crest height. In the entrainment layer, however, negative heat fluxes are smaller over the valleys. The heat flux profiles demonstrate intensified upward transport of heat over valleys compared with a plain. As heat fluxes stay positive within the valleys and above the mountain ridges (especially in deep valleys), heat is transported upward to much higher altitudes than over a plain. Tendencies of potential temperature after 6 h of simulation are shown in Figure 10. In the lower boundary layer, all simulations show similar heating rates over the foreland (Figure 10(a)). In the entrainment layer, cooling is reduced and in the free atmosphere additonal heating occurs in simulations with valleys. This heating above the boundary layer is induced by vertical advection of warm air due to subsidence over the plain, which in turn is induced by the mountain-to-plain return flow. Over the valley region, the boundary layer is more strongly heated in valleys than in the PLAIN run, due to the valley volume effect (Figure 10(b)). Additionally, heating occurs over a larger depth and cooling in the entrainment layers is smaller over valleys than over a plain.

Transport processes: mass-flux budget
To demonstrate the dependence of vertical exchange processes between the boundary layer and the free atmosphere on valley geometry, both mass-flux budgets and forward trajectories are calculated for all simulations. Mass fluxes are computed for a lower and upper volume over the foreland, to study mass transport into and out of the valley within and above the boundary layer, respectively. The horizontal dimensions of the lower and upper volume boxes are defined by −10 ≤ x ≤ 10 km and −80 ≤ y ≤ −10 km (see Figure 1). In the vertical, the timedependent mean mixed-layer height of the PLAIN simulation (PLAIN-PBL2) is chosen as the separation surface between the upper and lower volumes (see section 4 for the determination of PLAIN-PBL2). This implies that the lower volume ranges from the surface to PLAIN-PBL2 in the vertical. The vertical extent of the upper volume is defined from PLAIN-PBL2 to a horizontal surface at an altitude of 5 km.
Due to the time dependence of PLAIN-PBL2, an additional mass-flux term has to be considered in the mass-flux budget computation. The volume integral of the left-hand side of the continuity equation over the lower volume with density ρ, time t and wind vector v yields with upper boundary z top (PLAIN-PBL2), horizontal integration area A, vertical velocity of the upper boundary W top = ∂z top /∂t, mass of the lower volume M(t) and additional mass-flux term FLUX top (t). Here, the Leibniz rule for integrals with varying boundaries has been applied to the left-hand side of Eq. (6): The application of Gauss's theorem to the volume integral of the right-hand side of Eq. (5) yields with velocity components u, v and w and the corresponding two integration areas in the cross-valley (A cross ) and along-valley (A along ) directions and the vertical (A top ) integration area at the top of the volume. The combination of Eqs (6) and (8) yields According to Eq. (9), the mass of the lower volume changes due to the increasing upper boundary z top (FLUX top ), mass fluxes through the upper surface (FLUX vert ) and net mass fluxes through the side walls of the box (FLUX horiz ). The evolution of the single terms in Eq. (9) is computed for all simulations and shown for the reference run (H1500) in Figure 11 The time series of the mass-flux budget (FLUX vert and FLUX horiz ) for the lower volume is shown in Figure 11(b) for all simulations. The transport into and out of the volumes is dominated by horizontal mass fluxes in the along-valley direction and vertical mass fluxes through the PLAIN-PBL2 surface. Values corresponding to vertical mass fluxes are indicated by grey shading in Figure 11(b). In the lower volume, mass is exported horizontally towards the valley by the plain-to-mountain wind. This mass loss is balanced by downward mass fluxes through the PLAIN-PBL2 surface over the foreland. The same process occurs in the upper volume (not shown), which gains mass from the along-valley return flow and loses mass by subsidence through the PLAIN-PBL2 surface. Net fluxes into and out of the volumes are nearly identical for the upper and lower volume (not shown). The strong decrease of the horizontal mass flux towards the valley for simulations with 1500 m deep valleys (e.g. H1500) after 8 h of simulation is related to the growing PLAIN-PBL2 height with time, which becomes larger than 1500 m after 8 h. A similar massflux reduction is visible for the H1000 run after 5 h of simulation. This mass budget analysis shows that the dominant circulation is in the along-valley direction and that mass is transported from the boundary layer over the plain to the valley and back to regions above the boundary layer over the foreland. Figure 11(c) shows time averages of absolute horizontal net mass fluxes out of the lower volume (i.e. towards the valley, as mass fluxes in the cross-valley direction are very small) between 8 and 12 h of simulation and scaled by the corresponding value of the reference run (H1500). For valleys that are shallower than the PLAIN-PBL2 height, a linear increase of mass transport with valley depth is visible. This means that a reduction of the mountain height to two and one third of the reference run (H1000 and H0500, respectively) causes mass fluxes towards the valley of around two and one third (66 and 40%, respectively) of the reference run mass flux (H1500). If the valley width is doubled (W40), the mass flux towards the valley reduces to 27% of the reference run. Note that the cross-valley dimension of the volumes is defined by −10 ≤ x ≤ 10 km. If the crossvalley extent of the volume is defined by the valley width (i.e. −15 ≤ x ≤ 15 km for W30 and −20 ≤ x ≤ 20 km for W40), mass fluxes towards the valley are nearly identical for the W30, W40 and H1500 runs (not shown). This means that, in this mass-flux computation method, the weaker plain-to-mountain flow is compensated by the wider cross-valley dimension of the volume. The reduction of valley length has only a minor impact on the mass flux, with the exception of the very short valley of the L25 case, where the mass flux reduces to 58% of the reference case. In summary, the horizontal mass transport is more effective for deeper, narrower and longer valleys. This is in agreement with the average along-valley wind speeds shown in Figure 8(c) and (d).

Transport processes: forward trajectories
To investigate the horizontal and vertical transport processes over a valley-plain topography in more detail, forward trajectories are computed for all sensitivity runs. A total of 1764 trajectories are started in a box with a horizontal extent of 4 × 4 km 2 (21 × 21 grid points) on four levels with elevations of 25, 50, 75 and 100 m AGL. The cross-valley extension of the box is increased to 6 and 8 km for the W30 and W40 cases, respectively, to keep the ratio of box width to valley width (0.2) constant. The centre of the box is set to x = 0 km in the cross-valley direction and to different along-valley positions of y = −40, −20, −10 and 10 km to study pathways of parcels in the boundary layer with varying positions relative to the valley topography. All trajectories are started at the initial time of the simulation and are computed forward for 12 h. As the focus of this study is on investigating transport processes from the boundary layer to the free troposphere, the time-dependent mean boundary-layer heights (PLAIN-PBL2 and PLAIN-PBL3) are chosen as reference heights to separate fluid elements in the boundary layer from fluid elements in the free atmosphere. Recall that PLAIN-PBL2 and PLAIN-PBL3 represent the minimum and maximum boundary-layer heights over the plain, respectively. These reference boundary-layer heights are nearly equal to the boundary-layer heights over the foreland of all the other sensitivity runs (not shown, but see Figure 8(a)).
In Figure 12, a scatter plot of the trajectories is shown for the reference run for different along-valley starting positions. The colour shading is adapted to PLAIN-PBL2 to indicate whether parcels are located above or below the boundary layer over a flat plain. Air parcels that are started over the foreland and 40 km away from the valley entrance region are advected towards the mountains and nearly reach the valley after 12 h (Figure 12(a)). The majority of the parcels stay in the boundary layer of the foreland and only a few parcels are transported to heights above PLAIN-PBL2 into the capping inversion below PLAIN-PBL3 (not shown) by convective cells. As soon as these single rising parcels penetrate the capping inversion, they are captured by the mountain to plain return flow and advected up to 60 km away from the valley.
If the trajectories are started closer to the mountains, at y = −20 km and y = −10 km, the plain to mountain circulation is stronger and the parcels are advected up to 40 and 60 km into the valley, respectively (Figure 12(b) and (c)). After the valley is reached, most parcels are transported both in alongvalley direction by upvalley winds and upwards by upslope winds towards the mountain crests. Over the ridges, the parcels experience a strong updraught from the intense convective thermals, which transport the air to altitudes of up to 3 km. After arriving at their maximum heights, the air parcels are transported towards the valley centre by the cross-valley circulation. However, before reaching the middle of the valley, the air is captured by the mountain-to-plain return flow, which transports the parcels into the free troposphere over the foreland. This process is very similar for parcels started in the valley at y = 10 km (Figure 12(d)). Trajectories of these fluid elements show that most of the air that is located in the valley at the initial time is transported upwards in the cross-valley direction towards the mountain crests. As the cross-valley circulation starts before the along-valley flow, when the surface starts to heat, only a minor part of the fluid elements is advected further upvalley. Most of the parcels that reach the mountain crests are advected away from the valley and over the foreland and arrive at distances of up to 40 km from the valley entrance.
In Figure 13  transport near-surface parcels up to 60 km into the valley (H1500 and H2000). Due to higher mountains in the H2000 run, parcels are transported to higher altitudes in relation to PLAIN-PBL2. This implies that more parcels are captured by the return flow and transported towards the foreland than in the H1500 simulation.
The evolution of height and along-valley distribution of parcels started at y = 10 km is shown in Figures 14 and 15 for different simulations. In the PLAIN simulation, most parcels stay in the boundary layer below PLAIN-PBL2 (Figure 14(a)) and in the vicinity of their initial along-valley position at y = 10 km (Figure 15(a)). A significant part of the parcels is located in the inversion layer between PLAIN-PBL2 and PLAIN-PBL3. For increasing valley depths, most parcels are transported to heights above PLAIN-PBL2 and PLAIN-PBL3 by upslope winds during the first 3 h (Figure 14(b)-(d). In the H1500 and H2000 runs, the majority of the parcels stay above PLAIN-PBL3 during the rest of the simulation time. Distributions of parcel along-valley positions indicate that for the H1000 run about half of the parcels are transported into the valley by upvalley winds, whereas the other half are transported towards the foreland by the return flow (Figure 15(b)). For deeper valleys (H1500 and H2000), only a minor number of parcels are transported into the valley and most parcels are captured by the mountain-to-plain return flow and  advected more than 40 km over the foreland (Figure 15(c) and (d)). If the valley is very wide (e.g. W40), the height distribution of the parcels is very similar to the PLAIN simulation (Figure 14(e)). In the along-valley direction, a considerable number of parcels are transported into the valley in the W40 run, due to weak upvalley winds (Figure 15(e)).
To quantify the impact of valley geometry on transport processes from the boundary layer to the free atmosphere, the positions of the parcel trajectories are averaged for every time step and displayed as time series in Figures 16 and 17. On average, parcels that are started in the valley at y = 10 km are transported upward by slope winds and reach elevations above the mountain ridges after about 3-4 h of simulation (Figure 16(a)). The vertical transport is stronger for deeper valleys. In simulations with valleys deeper than or equal to 1500 m, the average altitude of parcels exceeds the reference PLAIN-PBL2, at least during the first 7 h. As time proceeds, PLAIN-PBL2 and PLAIN-PBL3 grow and reach the same altitude as averaged trajectory heights after about 8-10 h of simulation. Only parcels of the H2000 run reside above the reference heights until the simulation end.
In simulations with valleys 1500 m or deeper, 80-90% of the parcels are found above PLAIN-PBL2 after 4-6 h simulation time. In the H2000 run, the fraction of parcels above PLAIN-PBL2 height stays at 80% until the simulation end (Figure 16(b)). If the reference height PLAIN-PBL3 is chosen, the percentage of parcels above this height is only 70-90% between 3 and 6 h of simulation and decreases to 40 and 60% for 1500 and 2000 m deep valleys, respectively, after 10-12 h (Figure 16(c)). Mean along-valley positions demonstrate that, on average, parcels in the H1500 and H2000 runs are advected slightly into the valley at first and are then transported horizontally up to 15 km over the foreland during the last 6 h of the simulations (Figure 16(d)). In shallow valleys (H0500 and H1000), parcels show a strong dispersion in the along-valley direction (cf. Figure 15(b)), which results in insignificant changes of mean along-valley positions.
If the valley width is increased (W30 and W40), most parcels are located over the flat valley floor and far away from the slopes. This means that the average height of the parcels is very similar to that of the PLAIN simulation. However, due to the development of a weak along-valley flow in both W30 and W40 runs, the parcels are advected upvalley throughout the simulation on average. The variation of valley length has no significant influence on trajectories started at y = 10 km, as average heights and along-valley positions are similar to the H1500 run.
Trajectories started on the foreland at y = −10 km show average heights below PLAIN-PBL2 throughout the simulation for all sensitivity runs except the H2000 case (Figure 17(a)). In cases with 1500 m deep valleys, about 50-60% of the parcels are located above PLAIN-PBL2 after 8 h of simulation (Figure 17(b)). This is nearly twice the number of parcels that are transported to the free atmosphere by convective thermals in the PLAIN simulation (about 30%). The percentage of parcels above PLAIN-PBL3 is only 30-40% for 1500 m deep valleys (Figure 17(c)). In the along-valley direction, parcel distributions exhibit a relatively strong dispersion (not shown). Average along-valley positions, however, show the transport of parcels into the valley at low levels and back towards the foreland at higher altitudes (Figure 17(d)). The return transport is strongest for deep valleys (e.g. H2000).

Conclusions
In this study, the impact of valley geometry on the boundarylayer structure and vertical transport processes is investigated by means of idealized numerical simulations. A valley-plain topography and a time-dependent surface heat flux forcing are used to generate thermally driven flows in a heating boundary layer.
In all simulations, except the flat plain simulation, a mesoscale plain-to-mountain circulation develops, which transports mass   from the boundary layer over the foreland towards the mountains (see the schematic in Figure 18). Within the valley, along-valley and upslope winds transport the air more than 60 km into the valley and upwards to heights far above the mountain ridges, respectively. A mountain-to-plain return flow transports the air back towards the foreland at elevations above the boundarylayer height. Compared with vertical exchange by turbulent entrainment in a convective boundary layer over a flat plain, this mesoscale circulation increases the mass transport from the boundary layer to the free atmosphere intensively (cf. the sketch in Figure 18). The quantification of these transport processes is of importance for the improvement of boundary-layer parametrizations over complex terrain and the understanding of land-atmosphere exchange processes (e.g. Rotach et al., 2014). The efficiency of this transport mechanism in dependence of valley geometry is investigated by mass-flux budgets and forward trajectories in this study. The computation of mass-flux budgets for two vertically stacked volumes over the foreland confirms the dominance of the plain-to-mountain circulation in this model set-up. The mass flux towards the valley in the boundary layer is nearly identical to the mass flux of the return flow. This enables us to use the boundary-layer mass flux as a measure of the capability of the valley-plain topography to increase vertical exchange processes compared with a flat plain. A reduction of the valley depth to two and one third (H1000 and H0500, respectively) of the original valley depth (H1500) is related to a reduced mass flux of 66 and 40% of the reference run mass flux, respectively. An increase of valley depth by a factor of about 1.33 (H2000) leads to a mass flux increase of 111%. The enlargement of valley width by a factor of 1.5 (W30) and 2.0 (W40) reduces the mass transport to 50 and 27% compared with values of the reference run, respectively. Note that these values are based on fixed crossvalley extents of the mass-flux volumes (−10 ≤ x ≤ 10 km). A reduction of valley length to 75, 50 and 25% (L75, L50 and L25) of the original valley length (H1500) results in 95, 86 and 58% of the reference run mass flux. This shows that valley depth and width have the largest impact on the valley-plain circulation and vertical transport processes.
These results are in qualitative agreement with average profiles of along-valley wind speed over the foreland. Maximum plainto-mountain winds over the foreland reach only 30 and 73% of the reference run wind speeds for the H0500 and H1000 cases, respectively. The increase of the valley width decreases the maximum wind speed to 65 and 48% of the value of the reference run wind speed for the W30 and W40 simulations, respectively. These differences in the flow structure are caused by differences in the temperature contrast between the valleys and the foreland (volume effect). Mean vertical potential temperature profiles over the foreland are nearly identical for all simulations, whereas over the valley region very shallow (H0500) and wide (W40) valleys develop about 0.2 and 0.6 K colder potential temperatures than the reference run, respectively.
To study the transport processes in more detail, forward trajectories are started near the surface and computed over the whole simulation time. Parcels that are started far away from the valley over the foreland are transported horizontally towards the valley within the boundary-layer flow. Air parcels that are started near enough to the mountains are transported far into the valley and advected above the mountain crests by upslope winds. These parcels are then captured by the mountain-plain return flow and transported back to the free atmosphere over the foreland.
Analysis of the parcel positions shows that, in deep valleys (H1500, H2000), between 80 and 90% of the parcels started from the valley floor are transported to altitudes above the boundary-layer height over the plain (PLAIN-PBL2). In contrast, only 20-30% of the parcels reside above PLAIN-PBL2 in a simulation over a flat plain. This shows that the vertical transport in valleys can be three to four times larger than over a flat plain. Similar results were found in the real-case study of Weigel et al. (2007) for moisture transport out of a valley. This vertical transport contrast becomes even larger when PLAIN-PBL3 is chosen as the reference height and the capping inversion becomes part of the convective boundary layer. In this case, only 10-20% of the parcels are transported above PLAIN-PBL3 in the PLAIN simulation and the transport in valleys can be up to eight times larger than over a flat plain.
Analysis of the cross-valley circulation and thermal structure in the valley indicates that major differences arise due to varying valley depths and widths. Shallow valleys with mountain ridges that are smaller than the boundary-layer height of the foreland (e.g. H0500, H1000) develop only one cross-valley circulation cell, with upslope winds near the surface and a return flow towards the valley centre above. In deeper valleys, a valley inversion layer separates the valley boundary layer into a lower and upper mixed layer (PBL1 and PBL2) and enables the development of two vertically stacked circulation cells. Similar results have already been found in Wagner et al. (2014) for fully resolved (deep) and smoothed (shallow) valleys. However, it is expected that the development of valley inversion layers and vertically stacked circulation cells is strongly dependent on surface forcing (cf. Wagner et al., 2014) and background stability.
The results of this study show that valley geometry and in particular the valley depth play an important role in the thermal stratification and flow structure in the valley itself and over the foreland. The correct representation of complex terrain in numerical models is therefore of great importance to simulate boundary-layer flows and vertical exchange processes correctly and also influences the flow development in the free atmosphere above. Further studies with more complex valley topographies, inhomogeneous surface properties and varying background stabilities and surface forcings would be necessary to generalize the results of this investigation.