From 6896c1657dc0b04838fcfc280e2c60b1db1aecce Mon Sep 17 00:00:00 2001 From: visr Date: Mon, 9 Dec 2024 10:15:13 +0000 Subject: [PATCH] deploy: fbc238325dbe50fbe994aacfd43a90848c66b123 --- dev/model_docs/vertical/sbm.html | 2 +- dev/search.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dev/model_docs/vertical/sbm.html b/dev/model_docs/vertical/sbm.html index 2982096ad..4e2712e12 100644 --- a/dev/model_docs/vertical/sbm.html +++ b/dev/model_docs/vertical/sbm.html @@ -687,7 +687,7 @@

The S
┌ Warning: Found `resolution` in the theme when creating a `Scene`. The `resolution` keyword for `Scene`s and `Figure`s has been deprecated. Use `Figure(; size = ...` or `Scene(; size = ...)` instead, which better reflects that this is a unitless size and not a pixel resolution. The key could also come from `set_theme!` calls or related theming functions.
-└ @ Makie ~/.julia/packages/Makie/XQfuO/src/scenes.jl:229
+└ @ Makie ~/.julia/packages/Makie/pFPBw/src/scenes.jl:238
diff --git a/dev/search.json b/dev/search.json index ca7c4c2f8..f92e8b577 100644 --- a/dev/search.json +++ b/dev/search.json @@ -1315,7 +1315,7 @@ "href": "model_docs/vertical/sbm.html#soil-processes", "title": "SBM", "section": "Soil processes", - "text": "Soil processes\n\nThe SBM soil water accounting scheme\nA detailed description of the Topog_SBM model has been given by Vertessy (1999). Briefly: the soil is considered as a bucket with a certain depth (\\(\\SIb{z_t}{mm}\\)), divided into a saturated store (\\(\\SIb{S}{mm}\\)) and an unsaturated store (\\(\\SIb{U}{mm}\\)). The top of the \\(S\\) store forms a pseudo-water table at depth \\(\\SIb{z_{i}}{mm}\\) such that the value of \\(S\\) at any time is given by:\n\\[\n S=(z_t-z_i)(\\theta_s-\\theta_r)\n\\]\nwhere \\(\\SIb{\\theta_{s}}{-}\\) and \\(\\SIb{\\theta_{r}}{-}\\) are the saturated and residual soil water contents, respectively.\nThe unsaturated store \\(U\\) is subdivided into storage (\\(\\SIb{U_s}{mm}\\)) and deficit (\\(\\SIb{U_d}{m}\\)):\n\\[\n U_d=(\\theta_s-\\theta_r)z_i-U\\\\\n U_s=U-U_d\n\\]\nThe saturation deficit (\\(\\SIb{S_d}{mm}\\)) for the soil profile as a whole is defined as:\n\\[\n S_d=(\\theta_s-\\theta_r)z_t-S\n\\]\nAll infiltrating water that enters the \\(U\\) store first. The unsaturated layer can be split-up in different layers, by providing the thickness \\(\\SIb{}{mm}\\) of the layers in the TOML file. The following example specifies three layers (from top to bottom) of 100, 300 and 800 mm:\n[model]\nthicknesslayers = [100, 300, 800]\nThe code checks for each grid cell the specified layers against the soilthickness \\(\\SIb{}{mm}\\), and adds or removes (partly) layer(s) based on the soilthickness.\nAssuming a unit head gradient, the transfer of water (\\(\\SIb{\\mathrm{st}}{mm t^{-1}}\\)) from a \\(\\SIb{U}{mm}\\) store layer is controlled by the saturated hydraulic conductivity \\(\\SIb{\\subtext{K}{sat}}{mm t^{-1}}\\) at depth \\(\\SIb{z}{mm}\\) (bottom layer) or \\(\\SIb{z_i}{mm}\\), the effective saturation degree of the layer, and a Brooks-Corey power coefficient (parameter \\(c\\)) based on the pore size distribution index \\(\\lambda\\) (Brooks and Corey, 1964):\n\\[\n\\begin{gathered}\n \\mathrm{st}=\\subtext{K}{sat}\\left(\\frac{\\theta-\\theta_r}{\\theta_s-\\theta_r}\\right)^c\\\\\n c=\\frac{2+3\\lambda}{\\lambda}\n\\end{gathered}\n\\]\nHere \\(\\SIb{}{mm t^{-1}}\\) denotes milimeter per time step.\nWhen the unsaturated layer is not split-up into different layers, it is possible to use the original Topog\\_SBM vertical transfer formulation, by specifying in the TOML file:\n[model]\ntransfermethod = true\nThe transfer of water from the \\(\\SIb{U}{mm}\\) store to the \\(\\SIb{S}{mm}\\) store (\\(\\SIb{st}{mm\nt^{-1}}\\)) is in that case controlled by the saturated hydraulic conductivity \\(\\SIb{\\subtext{K}{sat}}{mm s^{-1}}\\) at depth \\(\\SIb{z_i}{mm}\\) and the ratio between \\(\\SIb{U}{mm}\\) and \\(\\SIb{S_d}{mm}\\):\n\\[\n \\mathrm{st}=\\subtext{K}{sat}\\frac{U_s}{S_d}\n\\]\nFour different saturated hydraulic conductivity depth profiles (ksat_profile) are available and a ksat_profile can be specified in the TOML file as follows:\n[input.vertical]\nksat_profile = \"exponential_constant\" # optional, one of (\"exponential\", \"exponential_constant\", \"layered\", \"layered_exponential\"), default is \"exponential\"\nSoil measurements are often available for about the upper \\(\\SI{1.5-2}{m}\\) of the soil column to estimate the saturated hydraulic conductivity, while these measurements are often lacking for soil depths beyond \\(\\SI{1.5-2}{m}\\). These different profiles allow to extent the saturated hydraulic conductivity profile based on measurements (either an exponential fit or hydraulic conductivity value per soil layer) with an exponential or constant profile. By default, with ksat_profile “exponential”, the saturated hydraulic conductivity \\(\\SIb{\\subtext{K}{sat}}{mm\nt^{-1}}\\) declines with soil depth \\(\\SIb{z}{mm}\\) in the model according to:\n\\[\n \\subtext{K}{sat} = K_0 e^{-fz},\n\\]\nwhere \\(\\SIb{K_0}{mm s^{-1}}\\) is the saturated hydraulic conductivity at the soil surface and \\(\\SIb{f}{mm^{-1}}\\) is a scaling parameter.\nThe plot below shows the relation between soil depth \\(z\\) and saturated hydraulic conductivity \\(\\subtext{K}{sat}\\) for different values of \\(f\\).\n\n\nCode\nusing Printf\nusing CairoMakie\n\nlet\n fig = Figure(resolution=(800, 400))\n ax = Axis(fig[1, 1], xlabel=L\"K_\\mathrm{sat}\\;[\\mathrm{mm/day}]\", ylabel=L\"-z\\;[\\mathrm{mm}]\")\n\n z = 0:5.0:1000\n ksat = 100.0\n f = 0.6 ./ collect(50:150.0:800)\n\n for fi in f\n lines!(ax, ksat .* exp.(-fi .* z), -z, label=@sprintf(\"%.2e\", fi))\n end\n\n Legend(fig[1, 2], ax, L\"f\")\n fig\nend\n\n\n┌ Warning: Found `resolution` in the theme when creating a `Scene`. The `resolution` keyword for `Scene`s and `Figure`s has been deprecated. Use `Figure(; size = ...` or `Scene(; size = ...)` instead, which better reflects that this is a unitless size and not a pixel resolution. The key could also come from `set_theme!` calls or related theming functions.\n└ @ Makie ~/.julia/packages/Makie/XQfuO/src/scenes.jl:229\n\n\n\n\n\n\n\n\n\nWith ksat_profile “exponential_constant”, \\(\\subtext{K}{sat}\\) declines exponentially with soil depth \\(\\SIb{z}{mm}\\) until \\(\\SIb{\\subtext{z}{mm}}{mm}\\) below the soil surface, and stays constant at and beyond soil depth \\(\\subtext{z}{exp}\\):\n\\[\n \\subtext{K}{sat} = \\begin{cases}\n K_0e^{-fz} & \\text{if $z < \\subtext{z}{exp}$}\\\\\n K_0e^{-f\\subtext{z}{exp}} & \\text{if $z \\ge \\subtext{z}{exp}$}.\n \\end{cases}\n\\]\nIt is also possible to provide a \\(\\subtext{K}{sat}\\) value per soil layer by specifying ksat_profile “layered”, these \\(\\subtext{K}{sat}\\) values are used directly to compute the vertical transfer of water between soil layers and to the saturated store \\(S\\). Finally, with the ksat_profile “layered_exponential” a \\(\\subtext{K}{sat}\\) value per soil layer is used until depth \\(\\subtext{z}{layered}\\) below the soil surface, and beyond \\(\\subtext{z}{layered}\\) an exponential decline of \\(\\subtext{K}{sat}\\) (of the soil layer with bottom \\(\\subtext{z}{layered}\\)) controlled by \\(f\\) occurs. The different available ksat_profle options are schematized in the figure below where the blue line represents the \\(\\subtext{K}{sat}\\) value.\n\n\n\nOverview of available ksat_profile options, for a soil column with five layers\n\n\n\n\nInfiltration\nThe water available for infiltration is taken as the rainfall including meltwater. Infiltration is determined separately for the compacted and non-compacted areas, as these have different infiltration capacities. Naturally, only the water that can be stored in the soil can infiltrate. If not all water can infiltrate, this is added as excess water to the runoff routing scheme.\nThe infiltrating water is split in two parts, the part that falls on compacted areas and the part that falls on non-compacted areas. The maximum amount of water that can infiltrate in these areas is calculated by taking the minimum of the maximum infiltration rate (infiltcapsoil \\(\\SIb{}{mm t^{-1}}\\) for non-compacted areas and infiltcappath \\(\\SIb{}{mm\nt^{-1}}\\) for compacted areas) and the amount of water available for infiltration avail_forinfilt \\(\\SIb{}{mm t^{-1}}\\). The water that can actually infiltrate infiltsoilpath \\(\\SIb{}{mm t^{-1}}\\) is calculated by taking the minimum of the total maximum infiltration rate (compacted and non-compacted areas) and the remaining storage capacity.\nInfiltration excess occurs when the infiltration capacity is smaller then the throughfall and stemflow rate. This amount of water (infiltexcess \\(\\SIb{}{mm t^{-1}}\\)) becomes overland flow (infiltration excess overland flow). Saturation excess occurs when the (upper) soil becomes saturated and water cannot infiltrate anymore. This amount of water excesswater \\(\\SIb{}{mm\nt^{-1}}\\) becomes overland flow (saturation excess overland flow).\n\nInfiltration in frozen soils\nIf snow processes are modelled, the infiltration capacity is reduced when the soil is frozen (or near freezing point). A infiltration correction factor is defined as a S-curve with the shape as defined below. A parameter (cf_soil) defines the base factor of infiltration when the soil is frozen. The soil temperature is calculated based on the soil temperature on the previous timestep, and the temperature difference between air and soil temperature weighted with a factor (w_soil, which defaults to 0.1125).\nThe near surface soil temperature is modelled using a simple equation (Wigmosta et al., 2009):\n\\[\nT_s^t = T_s^{t-1} + w (T_a - T_s^{t-1})\n\\] where \\(\\SIb{T_s^{t}}{\\degree C}\\) is the near-surface soil temperature at time \\(t\\), \\(\\SIb{T_a}{\\degree C}\\) is air temperature and \\(\\SIb{w}{-}\\) is a weighting coefficient determined through calibration (default is 0.1125 for daily timesteps).\nA reduction factor (cf_soil \\(\\SIb{}{-}\\), default is 0.038) is applied to the maximum infiltration rate (infiltcapsoil and infiltcappath), when the following model settings are specified in the TOML file:\n[model]\nsoilinfreduction = true\nsnow = true\nIf soilinfreduction is set to false, water is allowed to infiltrate the soil, even if the soil is frozen.\nA S-curve (see plot below) is used to make a smooth transition (a c-factor (\\(c\\)) of 8.0 is used):\n\\[\n\\begin{gathered}\n b = \\frac{1.0}{1.0 - \\subtext{\\mathrm{cf}}{soil}}\\\\\n \\mathrm{soilinfredu} = \\frac{1.0}{b + \\exp(-c (T_s - a))} + \\subtext{\\mathrm{cf}}{soil}\\\\\n a = 0.0\\\\\n c = 8.0\n\\end{gathered}\n\\]\n\n\n\nInfiltration correction factor as a function of soil temperature\n\n\n\n\n\n\nCapillary rise\nThe actual capillary rise actcapflux \\(\\SIb{}{mm t^{-1}}\\) is determined using the following approach: first the saturated hydraulic conductivity ksat \\(\\SIb{}{mm t^{-1}}\\) is determined at the water table \\(z_i\\); next a potential capillary rise maxcapflux \\(\\SIb{}{mm t^{-1}}\\) is determined from the minimum of ksat, actual transpiration actevapustore \\(\\SIb{}{mm t^{-1}}\\) taken from the \\(U\\) store, available water in the \\(S\\) store (satwaterdepth \\(\\SIb{}{mm}\\)) and the deficit of the \\(U\\) store (ustorecapacity \\(\\SIb{}{mm}\\)), as shown by the following code block:\nmaxcapflux = max(0.0, min(ksat, actevapustore, ustorecapacity, satwaterdepth))\nThen the potential rise maxcapflux is scaled using the water table depth zi, a maximum water depth cap_hmax \\(\\SIb{}{mm}\\) beyond which capillary rise ceases and a coefficient cap_n \\(\\SIb{}{-}\\), as follows in the code block below (i refers to the index of the vector that contains all active cells within the spatial model domain):\nif sbm.zi[i] > rootingdepth\n capflux =\n maxcapflux * pow(\n 1.0 - min(sbm.zi[i], sbm.cap_hmax[i]) / (sbm.cap_hmax[i]),\n sbm.cap_n[i],\n )\nelse\n capflux = 0.0\nend\nIf the roots reach the water table (rootingdepth \\(\\ge\\) sbm.zi), capflux is set to zero.\nFinally, the capillary rise capflux is limited by the unsaturated store deficit (one or multiple layers), calculated as follows in the code block below (i refers to the index of the vector that contains all active cells within the spatial model domain, and k refers to the layer position):\nusl[k] * (sbm.theta_s[i] - sbm.theta_r[i]) - usld[k]\nwhere usl \\(\\SIb{}{mm}\\) is the unsaturated layer thickness, usld is the ustorelayerdepth \\(\\SIb{}{mm}\\) (amount of water in the unsaturated layer), and \\(\\theta_s\\) and \\(\\theta_r\\) as previously defined.\nThe calculation of the actual capillary rise actcapflux is as follows in the code block below (i refers to the index of the vector that contains all active cells within the spatial model domain, and k refers to the layer position):\nactcapflux = 0.0\nnetcapflux = capflux\nfor k = n_usl:-1:1\n toadd =\n min(netcapflux, max(usl[k] * (sbm.theta_s[i] - sbm.theta_r[i]) - usld[k], 0.0))\n usld = setindex(usld, usld[k] + toadd, k)\n netcapflux = netcapflux - toadd\n actcapflux = actcapflux + toadd\nend\nIn case of multiple unsaturated layers (n_usl \\(>\\) 1), the calculation of the actual capillary rise starts at the lowest unsaturated layer while keeping track of the remaining capillary rise netcapflux \\(\\SIb{}{mm t^{-1}}\\).\n\n\nLeakage\nIf the maxleakage \\(\\SIb{}{mm day^{-1}}\\) input model parameter is set > 0, water is lost from the saturated zone and runs out of the model.", + "text": "Soil processes\n\nThe SBM soil water accounting scheme\nA detailed description of the Topog_SBM model has been given by Vertessy (1999). Briefly: the soil is considered as a bucket with a certain depth (\\(\\SIb{z_t}{mm}\\)), divided into a saturated store (\\(\\SIb{S}{mm}\\)) and an unsaturated store (\\(\\SIb{U}{mm}\\)). The top of the \\(S\\) store forms a pseudo-water table at depth \\(\\SIb{z_{i}}{mm}\\) such that the value of \\(S\\) at any time is given by:\n\\[\n S=(z_t-z_i)(\\theta_s-\\theta_r)\n\\]\nwhere \\(\\SIb{\\theta_{s}}{-}\\) and \\(\\SIb{\\theta_{r}}{-}\\) are the saturated and residual soil water contents, respectively.\nThe unsaturated store \\(U\\) is subdivided into storage (\\(\\SIb{U_s}{mm}\\)) and deficit (\\(\\SIb{U_d}{m}\\)):\n\\[\n U_d=(\\theta_s-\\theta_r)z_i-U\\\\\n U_s=U-U_d\n\\]\nThe saturation deficit (\\(\\SIb{S_d}{mm}\\)) for the soil profile as a whole is defined as:\n\\[\n S_d=(\\theta_s-\\theta_r)z_t-S\n\\]\nAll infiltrating water that enters the \\(U\\) store first. The unsaturated layer can be split-up in different layers, by providing the thickness \\(\\SIb{}{mm}\\) of the layers in the TOML file. The following example specifies three layers (from top to bottom) of 100, 300 and 800 mm:\n[model]\nthicknesslayers = [100, 300, 800]\nThe code checks for each grid cell the specified layers against the soilthickness \\(\\SIb{}{mm}\\), and adds or removes (partly) layer(s) based on the soilthickness.\nAssuming a unit head gradient, the transfer of water (\\(\\SIb{\\mathrm{st}}{mm t^{-1}}\\)) from a \\(\\SIb{U}{mm}\\) store layer is controlled by the saturated hydraulic conductivity \\(\\SIb{\\subtext{K}{sat}}{mm t^{-1}}\\) at depth \\(\\SIb{z}{mm}\\) (bottom layer) or \\(\\SIb{z_i}{mm}\\), the effective saturation degree of the layer, and a Brooks-Corey power coefficient (parameter \\(c\\)) based on the pore size distribution index \\(\\lambda\\) (Brooks and Corey, 1964):\n\\[\n\\begin{gathered}\n \\mathrm{st}=\\subtext{K}{sat}\\left(\\frac{\\theta-\\theta_r}{\\theta_s-\\theta_r}\\right)^c\\\\\n c=\\frac{2+3\\lambda}{\\lambda}\n\\end{gathered}\n\\]\nHere \\(\\SIb{}{mm t^{-1}}\\) denotes milimeter per time step.\nWhen the unsaturated layer is not split-up into different layers, it is possible to use the original Topog\\_SBM vertical transfer formulation, by specifying in the TOML file:\n[model]\ntransfermethod = true\nThe transfer of water from the \\(\\SIb{U}{mm}\\) store to the \\(\\SIb{S}{mm}\\) store (\\(\\SIb{st}{mm\nt^{-1}}\\)) is in that case controlled by the saturated hydraulic conductivity \\(\\SIb{\\subtext{K}{sat}}{mm s^{-1}}\\) at depth \\(\\SIb{z_i}{mm}\\) and the ratio between \\(\\SIb{U}{mm}\\) and \\(\\SIb{S_d}{mm}\\):\n\\[\n \\mathrm{st}=\\subtext{K}{sat}\\frac{U_s}{S_d}\n\\]\nFour different saturated hydraulic conductivity depth profiles (ksat_profile) are available and a ksat_profile can be specified in the TOML file as follows:\n[input.vertical]\nksat_profile = \"exponential_constant\" # optional, one of (\"exponential\", \"exponential_constant\", \"layered\", \"layered_exponential\"), default is \"exponential\"\nSoil measurements are often available for about the upper \\(\\SI{1.5-2}{m}\\) of the soil column to estimate the saturated hydraulic conductivity, while these measurements are often lacking for soil depths beyond \\(\\SI{1.5-2}{m}\\). These different profiles allow to extent the saturated hydraulic conductivity profile based on measurements (either an exponential fit or hydraulic conductivity value per soil layer) with an exponential or constant profile. By default, with ksat_profile “exponential”, the saturated hydraulic conductivity \\(\\SIb{\\subtext{K}{sat}}{mm\nt^{-1}}\\) declines with soil depth \\(\\SIb{z}{mm}\\) in the model according to:\n\\[\n \\subtext{K}{sat} = K_0 e^{-fz},\n\\]\nwhere \\(\\SIb{K_0}{mm s^{-1}}\\) is the saturated hydraulic conductivity at the soil surface and \\(\\SIb{f}{mm^{-1}}\\) is a scaling parameter.\nThe plot below shows the relation between soil depth \\(z\\) and saturated hydraulic conductivity \\(\\subtext{K}{sat}\\) for different values of \\(f\\).\n\n\nCode\nusing Printf\nusing CairoMakie\n\nlet\n fig = Figure(resolution=(800, 400))\n ax = Axis(fig[1, 1], xlabel=L\"K_\\mathrm{sat}\\;[\\mathrm{mm/day}]\", ylabel=L\"-z\\;[\\mathrm{mm}]\")\n\n z = 0:5.0:1000\n ksat = 100.0\n f = 0.6 ./ collect(50:150.0:800)\n\n for fi in f\n lines!(ax, ksat .* exp.(-fi .* z), -z, label=@sprintf(\"%.2e\", fi))\n end\n\n Legend(fig[1, 2], ax, L\"f\")\n fig\nend\n\n\n┌ Warning: Found `resolution` in the theme when creating a `Scene`. The `resolution` keyword for `Scene`s and `Figure`s has been deprecated. Use `Figure(; size = ...` or `Scene(; size = ...)` instead, which better reflects that this is a unitless size and not a pixel resolution. The key could also come from `set_theme!` calls or related theming functions.\n└ @ Makie ~/.julia/packages/Makie/pFPBw/src/scenes.jl:238\n\n\n\n\n\n\n\n\n\nWith ksat_profile “exponential_constant”, \\(\\subtext{K}{sat}\\) declines exponentially with soil depth \\(\\SIb{z}{mm}\\) until \\(\\SIb{\\subtext{z}{mm}}{mm}\\) below the soil surface, and stays constant at and beyond soil depth \\(\\subtext{z}{exp}\\):\n\\[\n \\subtext{K}{sat} = \\begin{cases}\n K_0e^{-fz} & \\text{if $z < \\subtext{z}{exp}$}\\\\\n K_0e^{-f\\subtext{z}{exp}} & \\text{if $z \\ge \\subtext{z}{exp}$}.\n \\end{cases}\n\\]\nIt is also possible to provide a \\(\\subtext{K}{sat}\\) value per soil layer by specifying ksat_profile “layered”, these \\(\\subtext{K}{sat}\\) values are used directly to compute the vertical transfer of water between soil layers and to the saturated store \\(S\\). Finally, with the ksat_profile “layered_exponential” a \\(\\subtext{K}{sat}\\) value per soil layer is used until depth \\(\\subtext{z}{layered}\\) below the soil surface, and beyond \\(\\subtext{z}{layered}\\) an exponential decline of \\(\\subtext{K}{sat}\\) (of the soil layer with bottom \\(\\subtext{z}{layered}\\)) controlled by \\(f\\) occurs. The different available ksat_profle options are schematized in the figure below where the blue line represents the \\(\\subtext{K}{sat}\\) value.\n\n\n\nOverview of available ksat_profile options, for a soil column with five layers\n\n\n\n\nInfiltration\nThe water available for infiltration is taken as the rainfall including meltwater. Infiltration is determined separately for the compacted and non-compacted areas, as these have different infiltration capacities. Naturally, only the water that can be stored in the soil can infiltrate. If not all water can infiltrate, this is added as excess water to the runoff routing scheme.\nThe infiltrating water is split in two parts, the part that falls on compacted areas and the part that falls on non-compacted areas. The maximum amount of water that can infiltrate in these areas is calculated by taking the minimum of the maximum infiltration rate (infiltcapsoil \\(\\SIb{}{mm t^{-1}}\\) for non-compacted areas and infiltcappath \\(\\SIb{}{mm\nt^{-1}}\\) for compacted areas) and the amount of water available for infiltration avail_forinfilt \\(\\SIb{}{mm t^{-1}}\\). The water that can actually infiltrate infiltsoilpath \\(\\SIb{}{mm t^{-1}}\\) is calculated by taking the minimum of the total maximum infiltration rate (compacted and non-compacted areas) and the remaining storage capacity.\nInfiltration excess occurs when the infiltration capacity is smaller then the throughfall and stemflow rate. This amount of water (infiltexcess \\(\\SIb{}{mm t^{-1}}\\)) becomes overland flow (infiltration excess overland flow). Saturation excess occurs when the (upper) soil becomes saturated and water cannot infiltrate anymore. This amount of water excesswater \\(\\SIb{}{mm\nt^{-1}}\\) becomes overland flow (saturation excess overland flow).\n\nInfiltration in frozen soils\nIf snow processes are modelled, the infiltration capacity is reduced when the soil is frozen (or near freezing point). A infiltration correction factor is defined as a S-curve with the shape as defined below. A parameter (cf_soil) defines the base factor of infiltration when the soil is frozen. The soil temperature is calculated based on the soil temperature on the previous timestep, and the temperature difference between air and soil temperature weighted with a factor (w_soil, which defaults to 0.1125).\nThe near surface soil temperature is modelled using a simple equation (Wigmosta et al., 2009):\n\\[\nT_s^t = T_s^{t-1} + w (T_a - T_s^{t-1})\n\\] where \\(\\SIb{T_s^{t}}{\\degree C}\\) is the near-surface soil temperature at time \\(t\\), \\(\\SIb{T_a}{\\degree C}\\) is air temperature and \\(\\SIb{w}{-}\\) is a weighting coefficient determined through calibration (default is 0.1125 for daily timesteps).\nA reduction factor (cf_soil \\(\\SIb{}{-}\\), default is 0.038) is applied to the maximum infiltration rate (infiltcapsoil and infiltcappath), when the following model settings are specified in the TOML file:\n[model]\nsoilinfreduction = true\nsnow = true\nIf soilinfreduction is set to false, water is allowed to infiltrate the soil, even if the soil is frozen.\nA S-curve (see plot below) is used to make a smooth transition (a c-factor (\\(c\\)) of 8.0 is used):\n\\[\n\\begin{gathered}\n b = \\frac{1.0}{1.0 - \\subtext{\\mathrm{cf}}{soil}}\\\\\n \\mathrm{soilinfredu} = \\frac{1.0}{b + \\exp(-c (T_s - a))} + \\subtext{\\mathrm{cf}}{soil}\\\\\n a = 0.0\\\\\n c = 8.0\n\\end{gathered}\n\\]\n\n\n\nInfiltration correction factor as a function of soil temperature\n\n\n\n\n\n\nCapillary rise\nThe actual capillary rise actcapflux \\(\\SIb{}{mm t^{-1}}\\) is determined using the following approach: first the saturated hydraulic conductivity ksat \\(\\SIb{}{mm t^{-1}}\\) is determined at the water table \\(z_i\\); next a potential capillary rise maxcapflux \\(\\SIb{}{mm t^{-1}}\\) is determined from the minimum of ksat, actual transpiration actevapustore \\(\\SIb{}{mm t^{-1}}\\) taken from the \\(U\\) store, available water in the \\(S\\) store (satwaterdepth \\(\\SIb{}{mm}\\)) and the deficit of the \\(U\\) store (ustorecapacity \\(\\SIb{}{mm}\\)), as shown by the following code block:\nmaxcapflux = max(0.0, min(ksat, actevapustore, ustorecapacity, satwaterdepth))\nThen the potential rise maxcapflux is scaled using the water table depth zi, a maximum water depth cap_hmax \\(\\SIb{}{mm}\\) beyond which capillary rise ceases and a coefficient cap_n \\(\\SIb{}{-}\\), as follows in the code block below (i refers to the index of the vector that contains all active cells within the spatial model domain):\nif sbm.zi[i] > rootingdepth\n capflux =\n maxcapflux * pow(\n 1.0 - min(sbm.zi[i], sbm.cap_hmax[i]) / (sbm.cap_hmax[i]),\n sbm.cap_n[i],\n )\nelse\n capflux = 0.0\nend\nIf the roots reach the water table (rootingdepth \\(\\ge\\) sbm.zi), capflux is set to zero.\nFinally, the capillary rise capflux is limited by the unsaturated store deficit (one or multiple layers), calculated as follows in the code block below (i refers to the index of the vector that contains all active cells within the spatial model domain, and k refers to the layer position):\nusl[k] * (sbm.theta_s[i] - sbm.theta_r[i]) - usld[k]\nwhere usl \\(\\SIb{}{mm}\\) is the unsaturated layer thickness, usld is the ustorelayerdepth \\(\\SIb{}{mm}\\) (amount of water in the unsaturated layer), and \\(\\theta_s\\) and \\(\\theta_r\\) as previously defined.\nThe calculation of the actual capillary rise actcapflux is as follows in the code block below (i refers to the index of the vector that contains all active cells within the spatial model domain, and k refers to the layer position):\nactcapflux = 0.0\nnetcapflux = capflux\nfor k = n_usl:-1:1\n toadd =\n min(netcapflux, max(usl[k] * (sbm.theta_s[i] - sbm.theta_r[i]) - usld[k], 0.0))\n usld = setindex(usld, usld[k] + toadd, k)\n netcapflux = netcapflux - toadd\n actcapflux = actcapflux + toadd\nend\nIn case of multiple unsaturated layers (n_usl \\(>\\) 1), the calculation of the actual capillary rise starts at the lowest unsaturated layer while keeping track of the remaining capillary rise netcapflux \\(\\SIb{}{mm t^{-1}}\\).\n\n\nLeakage\nIf the maxleakage \\(\\SIb{}{mm day^{-1}}\\) input model parameter is set > 0, water is lost from the saturated zone and runs out of the model.", "crumbs": [ "Model documentation", "Vertical processes",