====== Rivers and lakes ====== ===== Basic assumptions ===== The HYPE model simulates most lakes and rivers in a conceptual way. The HYPE model can contain two types of rivers, local river and main river, and two types of lakes, local lakes and outlet lakes (Figure 1). The local river represent all ditches, streams, rivers within a subbasin that recieve only runoff within the subbasin. It is modelled as one conceptual river with a length, regardless of the actual distance runoff from different land has to travel through the subbasin. Similarly a local lake represents all lakes within a subbasin receiving inflow only from within the subbasin. The modelled local lake recieves a fraction of the flow in the local river. The fraction is defined as a fraction of the subbasin area. The main river is the river part(s) of a subbasin that water from upstream subbasins flows through. Depending on subbasin delieation it may be clearly defined or represent several tributaries that comes to the subbasin outlet. Finally the modelled outlet lake represents a lake located at the outlet of a subbasin. A local stream and a main rivers are present in all subbasins as default, and the length of each watercourse is then calculated as the square root of the subbasin area. River lengths can be given as input, and then their value decide if there will be a stream or river in the subbasin. If the river length is zero no river is calculated. The river can be defined as a SLC class and has then an surface area in addition to a length, but rivers can also be without area (i.e. no fraction of the subbasin area are occupied by the river and no precipitation added to the river). All runoff from land enters the local river. Local lakes (ilake) receive a portion of the local flow. The flow leaving the local river and the outflow from local lake, goes to the main river of the same subbasin. If there are upstream subbasins their flow is added to the main river together with the local flow. Outlet lakes (olake) receive the outflow from the main river, i.e. all upstream and local flows. | {{:start:hype_model_description:lakeriveroverview.png?400}} | | Figure 1: Schematic representation of streams and lakes in a subbasin of HYPE, and the links between them. | The two lake types are separate classes. The lake classes have characteristics such as land use and soil type, which are defined together with the other classes' characteristics (in GeoClass.txt). Precipitation, atmospheric deposition and evaporation of rivers and lakes are calculated first, while river flow and inflow, transformation processes and the outflow of the lakes is calculated thereafter. Lakes and rivers are calculated in the model’s routing part after all classes are calculated for the subbasin. An outlet lake can be part of a larger lake. It is then called a lake basin. Lake basins are olakes in nearby subbasins. A simple outlet lake has a threshold. If the water level drops below the threshold, the outflow ceases. Lake mean depth below the threshold is specified in GeoData.txt or LakeData.txt as //lake_depth// in meters. Lake depth can also be set by parameters, i.e general parameter //gldepo// or olake region parameter //olldepth//. At the start of a simulation the water depth of the lake is set to be at the threshold. The current water depth, denoted //wlm// in Fig. 2, can be above or below the threshold. For output, the outlet lake water level (output variable //wcom//) is given in a user set reference system. The reference level is used to get the same height system as any observations of the lake's water level. It uses the unit of meter, and the reference level (//w0ref//) gives the level of the threshold in the reference system (Fig. 2). The output //wcom// is calculated as the water level above the threshold plus //w0ref//. A regulated lake (dam) has two thresholds. The distance between the thresholds are determined by the regulation volume (//regvol//) of the dam with the assumption that the dam has constant area with depth. In reality the area may decrease with depth. This means that the the observed variation in water level may be larger than the simulated variation. It is therefore possible to adjust the output //wcom// (and //wcav//) with the actual amplitude of the regulation volume (//wamp//). This will make the simulated and recorded water stage comparable below the upper threshold for a regulated lake. |{{:start:hype_model_description:outletlakewithvariables2.png?400|}}| |Figure 2: An outlet lake with some variables.| A local lake also has a threshold depth that is used as start value. The depth is given by general parameter //gldepi// and is then the same for all the local lakes, or by ilake region parameter //illdepth//. It is measured in meters. A percentage of flow from the local stream flows into the local lake. The rest of the local flow runs directly to main river watercourse. The streams may have a delay and an attenuation of the flow. The former shifts the peaks, but leaves them otherwise untouched, while the attenuation both delays and smooths out peaks. The streams have a dead volume in which the residence time of solutes is increased relative to the water and the concentration smoothed out further over time. ==== Links to file reference ==== ^Parameter/Data ^File ^ |//rivlen, loc_rivlen, slc_nn//|[[start:hype_file_reference:geodata.txt|GeoData.txt]]| |special class code 1,2,11 and 12|[[start:hype_file_reference:geoclass.txt|GeoClass.txt]]| |//lake_depth//|[[start:hype_file_reference:geodata.txt|GeoData.txt]] or [[start:hype_file_reference:lakedata.txt|LakeData.txt]] or [[start:hype_file_reference:damdata.txt|DamData.txt]]| |//gldepo, olldepth, gldepi, illdepth//|[[start:hype_file_reference:par.txt|par.txt]]| |//w0ref, regvol, wamp//|[[start:hype_file_reference:lakedata.txt|LakeData.txt]] or [[start:hype_file_reference:damdata.txt|DamData.txt]]| ==== Links to relevant modules in the code ==== ^Modules (file) ^Procedures ^ | [[http://hype.sourceforge.net/doxy-html/namespacemodelmodule.html|modelmodule (model_hype.f90)]]|initiate_model_state| | ::: |initiate_model | | ::: |calculate_flow_from_undivided_lake| | ::: |calculate_flow_for_lakebasin_lake | | [[http://hype.sourceforge.net/doxy-html/namespacesurfacewater__processes.html|surfacewater_processes (sw_proc.f90)]]| calculate_riverlength| | ::: | calculate_ilake_outflow | | ::: | calculate_outflow_from_outlet_lake | | ::: | calculate_outflow_from_lakebasin_lake | | ::: |remove_outflow_from_lake| | ::: |calculate_branched_flow| ===== Rivers ===== ==== Common rivers processes ==== === Precipitation === Daily precipitation is added to the river if it has an area (is a class) and a new concentration is calculated. Precipitation is divided between river water in damping box and queue according to the respective volumes. === Evaporation === If the river has an area (as a class), it evaporates and a new concentration is calculated. The river is assumed to evaporate at potential evaporation rate (see [[start:hype_model_description:processes_above_ground#evaporation|Processes above ground - Evaporation]]). Normally the river area is constant over time, but with parameters a reduction of riverarea can be simulated for low volume/flow. The reduced river area is also used for heat exchange calculations. frac_area = delim{lbrace}{ matrix{3}{2}{ 0 {x<=0} {(1+(fraxe-x)/(fraxe-fraxm))*(x/fraxe)^{fraxe/(fraxe-fraxm)}} {0=fraxe} }}{} The parameters //fraxe// and //fraxm// are general, and //fraxe// is (minimum) mean river depth (m) where fractional river area = 1 and //fraxm// is mean river depth (m) where the slope of the fractional river area has its maximum (must be in the range between 0 and //fraxe//). //x// is the current mean river depth (estimated as river water volume (including possible deadvolume) divided by the full area extention). === Pure delay === The delay in the watercourse (//transtime//) in days is determined by the length of the watercourse (//rivlen//) and the water’s maximum velocity (//rivvel//). The maximum velocity is a general parameter with unit //m/s//. The delay in the river is dependent on subbasin land area if the default river length is used. The delay is a pure translation unless the parameter //damp// is set. The pure delay is divided into whole days (//ttday//) and parts of the day (//ttpart//) (if the time step is daily, other wise the division is made into whole and fractions of that time step). In the following description daily time step is assumed. transtime = rivlen/{rivvel*8.64*10^4} ttday = INT(transtime) ttpart = transtime - ttday The inflow of the river is stored in two arrays (//riverq// and //riverc//) until it is time for it to flow out of the river stretch. The outflow is weighted by using the parts of the time step (//ttpart//) that are to flow out during the time step. transq = (1-ttpart)*riverq(ttday) + ttpart*riverq(ttday+1) IF(transq>0)THEN transc = ((1-ttpart)*riverq(ttday)*riverc(ttday) + ttpart*riverq(ttday+1)*riverc(ttday+1)) / transq ELSE transc = 0. ENDIF After the calculation of outflow the values in the arrays are shifted forward one time step. === Delay and attenuation === If the delay in the watercourse also includes a damping of the peaks then only part of the delay is considered as translation, while the rest of the delay lies in damping. The translation is calculated first and then the flow goes through a linear box that creates attenuation. The parameter damp indicates how much of the delay that will occur in the attenuation box (or damping box), and translation time is reduced accordingly. Otherwise the translation is calculated in the same manner as above. totaltime=rivlen/{rivvel*8.64~10^4} transtime=(1-damp)*totaltime The result from the translation of water (//transq// and //transc//) flows into the attenuation box, which is assumed to be completely mixed. The delay time in the box (//kt, in timesteps//) is determined form input and parameters. kt = damp * totaltime The outflow equation depends on the attenuation box's volume before changes during the time step ( riverbox_ini ) and on the net inflow during the timestep (//inflow//). The net inflow includes the outflow from the translation (local runoff, upstream inflow, point sources etc.), removal though irrigation or regional groundwater flow, and the flow to or from a main river floodplain. The equation has two coefficients: riverrc1 = 1. - kt + kt * e^{-1{/}kt} riverrc2 = 1. - e^{-1{/}kt} dampq = riverrc1 * inflow + riverrc2 * riverbox_ini An earlier version of calcuation of outflow from the box can be accessed through a model option. In this case the delay time of the attenuation box is recalculated to a recession coefficient (//riverrc//). The recession coefficient is used to calculate the outflow from the box (//dampq//) by the current volume in the box (//riverbox//). riverrc = 1. - kt + kt * e^{-1{/}kt} dampq = riverrc * riverbox where riverbox = riverbox_ini + inflow . === Additional smoothing by dead volume === A dead volume (//deadriver//, m^3) can be used to get additional equalization of concentrations in the watercourse. In this case, the initial value of the attenuation box is equal to the dead volume. Inflows into the box are mixed with the entire volume. At present this represents a dilution of the concentration since the initial value of concentration in the box is zero. In HYPE the dead volume is estimated from the upstream area (including the area of the subbasin itself). This gives the dead volume: deadriver = dead * upparea * rivlen where the parameter //dead// (//deadl// or //deadm//, m^2{/}km^2) is general parameters, the upstream area //uparea// (km^2) is calculated from input data, and the river length (//rivlen//, //m//) is estimated to be the root of the subbasin’s area unless it is set among the input data. Dead volume can be used without suppression of water flow peak (//damp = 0//). When additional smoothing is used, the //riverbox// in the attenuation equations above is replaced by the volume of the attenuation box minus the dead volume. In addition, the dead volume is used to calculate a minimum river width used for calculation of river surface area in the case the river area is not given as a class area. The width is assumed to be 10 times the depth and together with the dead volume and river length, the with is calculated as: deadwidth = 10 * {(deadriver / {rivlen * 10})}^{1/2} === Derivation of the equation of recession in the attenuation box === The continuous-time equation for the change in volume //S// in a reservoir is: dS/dt=i(t)-q(t) where //i(t)// is influx and //q(t)// is outflow. If we assume that the outflow is proportional to the volume we get another expression for the change in //S//. //k// is in the unit of time. q(t)=1/k~S, dS/dt=k~dq/dt Combining these two equations gives a first degree equation that can be solved using the method of “integrating factor”: dq/dt + 1/k~q=i/k, {d e^{t{/}k}q}/dt=i/k~e^{t{/}k}, q(t)=1/k int{}{}{i(t)e^{delim{(}{tau-t}{)}{/}k}d tau} In our case, we have a constant influx during a time steps of length 1 day. Assume that the influx during a time steps are //I// and the outflow //Q//. These flows are thus the equivalent discrete flows. Because //I// is constant during the time step (//i(t) = I//) //Q// can be calculated. Define y(t)=e^{t/k}q(t) and integrate the second equation above, from 0 to t (//t = 1//, one time step). int{y(0)}{y(t)}{dy/dt} d tau = int{0}{t}{{i(tau)}/k} e^{\tau{/}k}d tau, y(t)-y(0)=I/k int{0}{t}{e^{tau{/}k}} d tau = I~(e^{t{/}k}-1) e^{t{/}k} q(t) - q(0) = I~(e^{t{/}k}-1) q(t)=q(0)e^{-t{/}k}+I~(1-e^{-t{/}k}) Calculate //Q// for time step (the mean of //q(t)//) and replace the outflow with the volume. Q = {int{0}{1}{} q(t) dt} / {int{0}{1}{} dt} = int{0}{1}{} q(0)e^{-t{/}k} + I~(1-e^{-t{/}k})dt {}= q(0) int {0} {1}{} e^{-t{/}k} dt + I~ int{0}{1}{} 1-e^{-t{/}k} dt {}= q(0)*({-}k~(e^{-1{/}k}-1))+I(1-0)-I~({-k}~(e^{-1{/}k}-1)) {}= I+(e^{-1{/}k}-1)~(kI - kq(0)) Q=I+(e^{-1{/}k}-1)~(kI-S(0)) or separated for //I// and //S//. Q=(1-k + k*e^{-1{/}k})~I + (1 - e^{-1{/}k})~S(0) Common in HYPE is that outflows are calculated with a recession coefficient. Here the recession coefficient is defined as the proportion of outflow after an inflow pulse. It is therefore calculated as r=Q{/}I under the assumption that the starting volume can be neglected, //S(0)=0//. r=Q/I=1+(e^{-1{/}k}-1)*k For a real flow the volume can of course not be neglected in this way and this relationship is only approximate. Alternatively the outflow may be calculated from the equation separated for //I// and //S//. For this option I is calculated as the sum of several different types of inflow and outflow to the river during the time step, e.g. precipitation and evaporation, in addition to the lateral inflow. In addition the initial value of the river volume (//S//(0)) is saved here to be used for the outflow calculation. === Bank-full flow === Bank-full flow is used for calculation of erosion of sediment and particulate phosphorus in rivers (see [[start:hype_model_description:hype_np_riv_lake#sedimentation_resuspension|Sedimentation/Resuspension]]). This flow has a probability of app. 0.5% (Nixon, 1959). It is in HYPE estimated by the second highest daily flow during the last 365 days, which has similar probability (Rosberg, 2003). ==== Local river ==== The local river has a length equal to the square root of the subbasin area, if not specified as input. Runoff from the land area of the subbasin forms the inflow to the local river (Figure 3). The flow in the local river is delayed and attenuated as described above. Of the resulting flow from the stream a constant percentage goes to the local lake (//icatch//), and the rest directly to the main river. |{{:start:hype_model_description:HYPE_box_picture_v3_localriver.png?400|}}| |Figure 3: Water flows of the local river.| ==== Main river ==== A main river is present in all subbasins. The length is equal to the square root of the subbasin area, if it is not specified as input. In areas without incoming water from upstream there is still a main river, but it receives only local river flow after the local lake. In subbasins with upstream incoming water, the flow to the main river will be the sum of outflow from the local lake, the proportion of flow in the local river not flowing into the local lake and the water from upstream (Figure 4). For a subbasin with a (part of) a multi-basin lake, the main river transports the flow from land to the lakebasin of the subbasin. |{{:start:hype_model_description:HYPE_box_picture_v3_mainriver.png?400|}}| |Figure 4: Water flows of main river.| The return flow from an aquifer is added to the inflow of the main river (Figure 4). The flow in the main river is delayed and attenuated as described above. The resulting effluent from the river flows to the outlet lake or to the next subbasin if there is no outlet lake. If the main river length is zero, the inflows to the main river is added to form the main river outflow. === Inflow from upstream subbasins === In input files it is given to which subbasin(s) the outflow from each subbasin flows. The upstream flow enters the main river of the downstream subbasin. Inflow into the main river of a subbasin is calculated by adding outflows from upstream areas. Concentrations are flow-weighted by their relative share. The upstream flow enters the main river, except if the upstream subbasin has a lakebasin that is part of the downstream subbasin's lake. In this case the upstream lakebasin outflow goes directly into the downstream lakebasin. === Hydraulic geometry to calculate water depth and velocity === River diagnostic variables can be calculated for the main river. A river water depth (//d//) and river velocity (//u//) can be calculated from hydraulic geometry for the main river and the calculated main river flow (//q//). In the case of updating of flow in a subbasin with no outlet lake, the updated (main river) flow is used. The equation coefficients are general parameters (//c,f,k,m//). d=c*q^f u=k*q^m === Rating curve to calculate river water level=== Given a continous monotonous increasing equation for calculating water level from flow, the water level of a river (//wr//) can be calculated from the flow by the inverse of this rating curve. This method is used to calculate main river water level in HYPE. Three different types of river rating curve formulations can be used (//TYPEofRRC//). The first is a single rating curve with a threshold (//w0//) and the rating curve coefficients are input. The rating curve q=k*(wr-w0)^p give coefficients //a// and //b// for the inverse equation: a={1/k}^{1/p} b=1/p wr = a*q^b + w0 The second type uses two rating curves with the same threshold (//w0//); one for ice free condition and one for use when there is ice on the river. The transition between the rating curves is smoothed by scaling of the curves in a transition period. The scaling of rating curve parameters are determined by ice porosity and ice thickness (general model parameters). Between thresholds the influence of the ice curve increases linearly from zero to one. The minimum influence (of porosity and thickness) is used as the scaling weight of the winter curve during the transition period. If only parameters for the ice free curve are given as input, the same parameters is used for ice conditions except for the exponent (//p//) which is then set to one. The third type is for a sectorial rating curve. It has different rating curve coefficients for different sections of water level. The sections may not overlap or leave gaps in water level, even though small discrepancies is handled. The parameters and sections need to be chosen so that the whole curve is continous. Since the rating curves are used inverted in the code, the sections are turned into sectors of flow. The average of the flow given by the minimum water level of one curve and the maximum water level of another curve is taken as the actual limit between the two curves. This type does not handle ice curves. In addition to river water level described above, it is possible to calculate the water level in the scale of the local gauge. This could e.g. be in cm and with the zero of the gauge at other location than //w0// of the equation. Figure 5 below show the relation between the different parameters. | {{:start:hype_model_description:river rating curves.png?600|}} | | Figure 5: Schematic representation of river water level. | ==== Links to file reference ==== ^Section ^Symbol ^Parameter/Data ^File ^ |Common rivers processes|//rivlen//|//rivlen, loc_rivlen//|[[start:hype_file_reference:geodata.txt|GeoData.txt]]| |:::|//fraxe, fraxm, rivvel, damp//|//fraxe, fraxm, rivvel, damp//|[[start:hype_file_reference:par.txt|par.txt]]| |:::|//dead//|//deadm, deadl//|:::| |Local river| |//icatch//|[[start:hype_file_reference:geodata.txt|GeoData.txt]]| |:::| |//gicatch, illicatch//|[[start:hype_file_reference:par.txt|par.txt]]| |Main river| |//maindown//|[[start:hype_file_reference:geodata.txt|GeoData.txt]]| |:::| |//branchid//|[[start:hype_file_reference:branchdata.txt|BranchData.txt]]| |:::|//c, f, k, m// |//hygeomc, hygeomf, hygeomk, hygeomm//|[[start:hype_file_reference:par.txt|par.txt]]| |:::| |//ricew0por, ricew1por, ricew0ice, ricew1ice//|:::| |:::|//k, p, w0// |//k, p, w0ref//|[[start:hype_file_reference:RiverRatingCurve.txt|RiverRatingCurveData.txt]]| |:::| |//wmin, wmax, gaugezero//|:::| ==== Links to relevant modules in the code ==== ^Modules (file) ^Procedures ^ Sections^ |[[http://hype.sourceforge.net/doxy-html/namespacemodelmodule.html|modelmodule (model_hype.f90)]] |initiate_model_state |rivers| |:::|initiate_model|::: | |::: |initiate_model | local river| |::: |::: | main river| |[[http://hype.sourceforge.net/doxy-html/namespacesurfacewater__processes.html|surfacewater_processes (sw_proc.f90)]] |add_precipitation_to_river |precipitation| |:::|calculate_river_evaporation |evaporation| |:::|translation_in_river |pure delay| |:::|calc_qbank|bank-full flow| |:::|update_qbank |:::| |:::|river_water_level |main river| |:::|local_water_level|:::| |:::|ice_on_river|:::| ==== References ==== Nixon, M. 1959. A study of the bank-full discharges of rivers in England and Wales. Journal of the Institute of Civil Engineers 12:157-174. Rosberg, J. 2003. Modelining phosphorus transport and retention in river networks. Master Thesis. Dept. of Earth Sciences, Uppsala University. ===== Lakes ===== ==== Common lake processes ==== === Precipitation === Daily precipitation is added to the lake and a new concentration is calculated. Lakes are assumed to be completely mixed. === Evaporation === The lake is assumed to evaporate at potential evaporation rate (see [[start:hype_model_description:processes_above_ground#evaporation|Processes above ground - Evaporation]]) and a new concentration calculated. The actual evaporating area is reduced if the lake is (partly) ice covered. Ice is calculated in case water temperature (substance T2) is simulated. === Outflow with rating curve ==== The rating curve is used for calculation of outflow in different circumstances. It is based on water level above a threshold. q(t)=k*(w(t)-w_0)^p In the program the equation is solved for the average flow during the timestep with linearization (Lindström, 2016). For rating curve exponent equal to one, the solution is exact, while for other exponent an approximation is used. The outflow of the lake is limited to the water above the threshold, in the case that the rating curve give a higher value. ==== Local lake (ilake) ==== The local lake has an initial volume which is determined by its area and threshold depth. The lake depth below the threshold is determined by model parameters (//gldepi// or //illdepth//). The inflow to the lake is a percentage of the flow in the local stream (//icatch//). The percentage is determined by the percentage of the subbasin area that drains to the lake. This percentage can be given as a fraction in GeoData.txt for each subbasin with an internal lake, or be given by a regional parameter //ilicatch//, or be given by a general parameter //gicatch//. If not set at all the default value is 1, i.e. the local river runs through the local lake. The flow from the local river is added to the lake (Figure 6). The lake water is assumed completely mixed. |{{:start:hype_model_description:HYPE_box_picture_v3_ilake.png?400|}}| |Figure 6: Water flows of internal lake.| Water outflow is calculated with the universal rating curve using general or region specific model parameters. The above description of the functioning of an internal lake (ilake) in HYPE can be changed with a modeloption for ''connectivity''. The default ilake model has no connectivity model. There are two alternatives for introducing lake connectivity within a subbasin. The first is a fill and spill model for a chain of storages. The second is a the Hysteretic Depressions Storage model (HDS). You can choose to use one or the other or to have different ilake descriptions for different subbasins. ===The fill-and-spill of ilake sections model=== This ilake connectivity model simulates the ilake as a chain of small connected lake sections (//lks//) with different height of their outflow threshold. Depending on water volume in the ilake one or several of the lake sections can be disconnected from the chain (zero outflow with water level below the threshold). The precipitation and evaporation are divided by the lake sections depending on their fraction of the ilake area, but the runoff from land area is divided by the lake sections depending on their fraction of the catchment area. In case the water level of a lake section is above its threshold, its outflow is calculated. The outflow of each lake section is calculated using the universal rating curve using general or region specific model parameters same as a simple ilake. The outflow of a lake section is of course also added to the receiving lake section before that one’s outflow is calculated. Depending on how far upstream from the last lake section of the chain there is inflow from the above lake section, that fraction of the ilake area is the ilake’s current connectivity. The catchment area of the lake sections above this border is the currently non-contributing catchment area. ===The Hysteretic Depressions Storage (HDS) model === Another model for the local lake is the Hysteretic Depressions Storage (HDS) model (Ahmed et al. 2023, Shook et al. 2021). The HDS model does not simulate depressions as distinct (individual) depressions, rather, it simulates the effects of the integrated depressions system and their connection at the basin level as a lumped depression storage (ilake). The HDS model simulates the change in the contributing area, depressional storage, and outflow from the subbasin. The model has contributing area fraction as a state. The runoff from the contributing area is outflow from the HDS model of the subbasin. The non-contributing area fraction of runoff is added to the depression storage. If the water of the depression is above the threshold of the depression, all the water above the threshold is also contributing to outflow of the HDS model of the subbasin. In this case the contributing area fraction will be one for the next timestep, otherwise the contributing fraction is calculated with a hysteretic function. The hysteretic function will keep the contributing fraction constant if the water volume in the depression is un-changed, if it is decreasing (drying up) the contributing fraction is set to zero. If the depression is filling up, the contributing fraction is increasing linearly on a curve to reach a contributing fraction of one at the same time as the depression is filled to the max. Input are the maximum depth (//hds_depth//) and maximum area (ilake slc-area) of depression in GeoData.txt (or a ilakeregion dependent parameter //hdsdepth// can be used). In addition, the land area fraction connected to the ilake, //icatch//, is used. It is set equal to one if the whole subbasin may contribute to the HDS outflow. //icatch// can be lower if part of the land area of the subbasin is always contributing to subbasin outflow, e.g. if it is contributing to a main river through the subbasin. The output 'connectivity' of the HDS model is in the HYPE implementation defined as the contributing area fraction, aka one minus the non-contributing area fraction. This because, at the moment, the water area of the depression is constant. The output 'non-contributing area fraction' is a the fraction of the ilake catchment area (including the ilake area itself) not contributing to outflow from the HDS model. ==== Simple outlet lake or dam (olake) ==== | {{:start:hype_model_description:simple_dam.png?400}} | | Figure 7: Water flows of outlet lake. | === Inflow === The outlet lake receives both local runoff and inflow from upstream areas via the main river. An outlet lake may receive inflow from regional groundwater flow (Figure 7). === Outflow with universal rating curve === If the water level (//wlm//) is higher than the threshold (//lake_depth//) the outflow is calculated with the following equation: outflow = delim{lbrace}{matrix{3}{3}{{0} {,~for} {wlm0} {gratk*corr*(wlm-lake_depth)^{gratp}} {,~for} {grata=0} }}{} corr = 1+ratcorr //gratk//, //gratp// and //grata// are general parameters that apply to all lakes in the model application. //ratcorr// is parameter region dependent model parameter for adjusting //gratk// to different regions. The upstream area (//uparea//, km^2) is included in the equation if parameter //grata// is >0. If the water level is below the threshold then the outflow is zero. If the flow calculated by the equation gives a larger outflow volume during a time step than the water volume above the threshold, the outflow is limited so that the water level do not drop below the threshold. It is possible to prescribe another minimum flow (//minflow//) than zero. In this case the outflow is no lower than the minimum flow as long as there is water in the lake. That is the water level can drop below the threshold. === Outflow with specific rating curve === In LakeData.txt a specific rating curve may be set instead of the general parameters. This is done by setting the //rate// and //exp// larger than zero in LakeData.txt. The outflow is also in this case limited by the threshold not to cause the water level to drop below it. It is possible to prescribe another minimum flow (//minflow//) than zero. In this case the outflow is no lower than the minimum flow as long as there is water in the lake. That is the water level can drop below the threshold. outflow = rate * (wlm - lake_{depth}) ^ {exp} === Regulated lake === A simple regulation routine can be given in LakeData.txt for selected outlet lakes. There are two main versions of regulations. The first determines a (often constant) production flow, for water levels between the lake threshold and a lower water stage threshold, and a spill for higher water levels. The second determines the outflow by different rating curves for (two) different seasons. For both variants it is possible to prescribe another minimum flow (//minflow//) than zero. In this case the outflow is no lower than the minimum flow as long as there is water in the lake. That is the water level can drop below the threshold(s). == Production flow == The regulated outflow is independent of water level (//wlm// (//m//)) between the threshold (//w0=lake_depth//) and a minimum water level (//wmin//). For this interval the production flow (//qprod//) is used. Production flow may depend on time of year and the water level. The minimum water stage is not really a water stage, but is calculated from the regulation volume (//regvol//) and the lake (surface) area. Thus it does not consider the area changing with depth. | {{:start:hype_model_description:illustraion_of_regulation_flow.png?400}} | | Figure 8: Illustration of regulation flow and variables. | For water levels above the threshold, the flow is calculated with a rating curve (typically flow through spillways) or all the water above the threshold is discharged. In this case though, the calculated flow may be increased so that the outflow is at least equal to the production flow (//qprod//). Compiled together as one equation, the outflow from a regulated lake is: outflow = delim{lbrace}{matrix{4}{3}{{MAX({rate * (wlm-w0)}^{exp}, qprod)} {,~for} {wlm>w0,rate>0} {MAX((wlm-w0) * 1000 / qunitfactor, qprod)}{,~for}{wlm>w0,rate<=0} {MIN(qprod,(wlm-wmin) * 1000 / qunitfactor)} {,~for} {wmin Input variables //rate, exp, qprod, regvol, w0, qamp// and //qpha// can be found in LakeData.txt. The variable //wmin// is calculated by the program from //regvol// and lake area: wmin = w0 - regvol * 1000000 / area Production flow can have two different values during the year, which depends on the day of the year. This is determined by the input variables //qprod1, qprod2, datum1// and //datum2//. Regulation period 1 between //datum1// and //datum2// has production flow //qprod1//, while the rest of the year has production flow //qprod2//. Not setting the dates gives the same production flow the whole year (//qprod1//). Production flow can alternatively be made to vary sinusoidal over the years, with a peak in December, when power output is normally high, and a minimum in June. This is done with the input variable //qamp//. If you want a different seasonal variation set //qpha// (default = 102). qprod = qprod*(1. + qamp * sin(2*pi*(dayno+qpha)/365)) In addition, the production flow may be reduced when there is a low water level in the dam. The flow will then be reduced linearly from full production flow for that time of year when water level is over the limit (//limqprod// (percentage of volume)) to zero when no water is left in the dam over //wmin// level. == Two rating curves == Regulated outflow can also be calculated from different rating curves for the regulation periods. The rating curve parameters are the specific rate and exponent for the lake, or if lacking, the general rate and exponent parameters. q(t)=k*(w(t)-w_0)^p Rating curve threshold (//w0//) determined by input variable //w0ref// is used for regulation period 1, while the rating curve threshold is changed for regulation period 2. The shift is determined by input variable //deltaw0//: w0 = w0ref + deltaw0 The shift between regulation period 1 and 2 can be made smoother by allowing the threshold to increase/decrease linearly over a few days. The number of days is given by the parameter //w0adjdays//. === Dams of specific purpose === In addition to regulated lakes (described above), dams in HYPE can instead be regulated by a specific purpose. Dams are then governed by the main purpose of the dam, e.g. hydropower, flood control. The rules of calculating the outflow of the dam then depends on the specified purpose of each dam. The outlet lakes that are regulated by a specified purpose is given in DamData.txt. A dam without defined purpose may use the methods given in previous sections (and be defined in LakeData.txt). Dams are characterised by their regulation volume (//regvol//) between a minimum water stage (//wmin//) and the spill threshold (//w0//). The minimum water stage (//wmin//) is not a real a water stage, but is calculated from the regulation volume (//regvol//) and the dam (surface) area. Thus it does not consider the area changing with depth. Below the minimum water level no outflow occurs. The spill threshold is defined from the lake's given depth (//lake_depth//) For dams a preferred production flow is calculated (see below). This is released if the dam in within the regulation volume, but no more water is released than to keep the water level above the minimum threshold. If instead the water level of the dam is above the threshold //w0//, the spillway equation (rating curve) is used. The outflow is the maximum of the spillway equation and the preferred production flow. Input variables //rate, exp, regvol, qamp// and //qpha// is given in DamData.txt. == General preferred production flow == For all dams the general preferred production flow is calculated from input data on the dam. The flow that is preferred to be released from the dam today is then adjusted depending on purpose. The general production flow (//qprod//) may be constant or vary between two values per year. Typically it is estimated from the yearly average inflow of the dam, which is given as input data. It can alternatively be determined by input variables //qprod1, qprod2, datum1// and //datum2//, which then has to be estimated. Regulation period 1 between //datum1// and //datum2// has production flow //qprod1//, while the rest of the year has production flow //qprod2//. Not setting the dates gives the same production flow the whole year (//qprod1//). IF //qprod1// is not given //qprod// is estimated from the yearly average inflow of the dam, which is given as input data. The production flow may be reduced when the water level is low in the dam. The flow will be reduced linearly from full production flow for that time of year when water level is at the limit (//limqprod// (percentage of volume)) to zero when no water is left in the dam over //wmin// level. == 1 - Irrigation dam and 2 - Water supply dam == Dams of these purposes uses the general perferred production flow as it is. == 3 - Flood control dam == The flood control dam will try to stay empty and ready to delay large inflows. The preferred production flow is calculated from the inflow of the day (//Qinftoday//) for low inflow and water stages, but set higher than the inflow for high flows and water levels. The maximum flow (//qthresh//, the threshold flow) is determined from input data (//Qinf// is average inflow to dam for each month) and a general parameter (//kthr//), while the water level threshold (//wthres//) is determined by a general parameter (//klow//) for the fraction of the regulation depth. qthresh = kthr*MAX(Qinf) wthresh = w0 - klow*(w0-wmin) If the current inflow is larger than the threshold inflow (//qthresh//), the maximum allowable discharge is released: qprod=qthresh If the current inflow is less than the threshold inflow (//qthresh//) and the current water level is lower than the threshold level (//wthresh//), the inflow is released from the dam: qprod= Qinftoday If the water level is above the threshold (//wthresh//), more water is released than inflow in an attempt to empty the dam. The factor multiplied by inflow (//krel//) is a general parameter: qprod=MIN(krel*Qinftoday,qthresh) == 4 - Hydropower dam == Dams for hydropower use the general preferred production flow, but the flow may be seasonally redistributed. The seasonal adjustment is a sinusoidal factor over the year, with as default a peak in December, when power output is normally high (in northern Europe), and a minimum in June. For a model in another geographic area, a different seasonal phase may be needed, and is then set with the input //qpha// to another value (default = 102). The seasonal redistribution is used for dams/subbasins with a snowfall fraction (//snowfrac//) above 0.35. For these dams the seasonal variation is calculated as: qprod = qprod*(1 + qamp * sin(2*pi*(dayno+qpha)/365)) If the snow fall fraction is above 0.35, a //qamp// of 0.71 is used, otherwise it is zero. The size of the seasonal adjustment can alternatively be set by the input variable //qamp// (0depth//|//lake_depth//|[[start:hype_file_reference:geodata.txt|GeoData.txt]] or [[start:hype_file_reference:lakedata.txt|LakeData.txt]] or [[start:hype_file_reference:damdata.txt|DamData.txt]]| |:::|:::|//gldepo, olldepth//|[[start:hype_file_reference:par.txt|par.txt]]| |:::| |//ratcorr, olratk, olratp, kthr, klow, krel//|:::| |:::|//wmin//|calculated from //regvol//|[[start:hype_file_reference:lakedata.txt|LakeData.txt]] or [[start:hype_file_reference:damdata.txt|DamData.txt]]| |:::| |//rate, exp, qamp, qpha//|:::| |:::|//qprod//|//qprod1, qprod2, datum1, datum2//|:::| |:::| |//limqprod//,//w0adjdays//|[[start:hype_file_reference:lakedata.txt|LakeData.txt]] or [[start:hype_file_reference:par.txt|par.txt]]| |:::| |//deltaw0,minflow//|[[start:hype_file_reference:lakedata.txt|LakeData.txt]]| |:::| |//purpose, snowfrac//|[[start:hype_file_reference:damdata.txt|DamData.txt]]| |:::|//Qinf//|//qinfjan, qinffeb, .., qinfdec//|:::| |Outlet lake with two outlets| |//ldtype//=5 or 6|[[start:hype_file_reference:lakedata.txt|LakeData.txt]]| |:::| |//w0ref, maxQprod, minflow, obsflow//|:::| |Constructing dams| |//builddam, removedam// |[[start:hype_file_reference:lakedata.txt|LakeData.txt]] or [[start:hype_file_reference:damdata.txt|DamData.txt]]| |:::| |//remdamdays//|[[start:hype_file_reference:par.txt|par.txt]]| ==== Links to relevant modules in the code ==== ^ Modules (file) ^ Procedures ^ Sections ^ |[[http://hype.sourceforge.net/doxy-html/namespacesurfacewater__processes.html|surfacewater_processes (sw_proc.f90)]] |calculate_potential_evaporation | evaporation | | ::: |calculate_actual_lake_evaporation | ::: | |::: |average_flow_rating_curve|ouflow with rating curve| |::: |calculate_ilake_outflow|local lake| |::: |calculate_ilakesection_outflow|:::| |:::|set_general_rating_k|simple outlet lake| |::: |calculate_outflow_from_outlet_lake calculate_branched_flow|simple outlet lake| |:::|:::|outlet lake with two outlets| |:::|calculate_lake_outlet_outflow|outlet lake with two outlets| |:::|calculate_lakebasin_average_waterstage|outlet lake as multi-basin lake| |:::|calculate_outflow_from_lakebasin_lake|:::| |:::|calculate_branched_flow|:::| |:::|change_current_dam_status|constructing dams| |[[http://hype.sourceforge.net/doxy-html/namespacemodelmodule.html|modelmodule (model_hype.f90)]] |initiate_model | local lake | |::: | calculate_local_lake_model |::: | |::: |calculate_flow_from_undivided_lake|simple outlet lake| |:::|:::|outlet lake with two outlets| |::: |calculate_flow_for_lakebasin_lake|outlet lake as multi-basin lake| ==== References ==== Ahmed, M.I., Shook, K., Pietroniro, A., Stadnyk, T., Pomeroy, J.W., Pers, C., Gustafsson, D., 2023. Implementing A Parsimonious Variable Contributing Area Algorithm for the Prairie Pothole Region in the HYPE Modelling Framework. Environmental Modelling & Software. https://doi.org/10.1016/j.envsoft.2023.105769 Lindström, G., 2016. Lake water level for calibration of the S-HYPE model, Hydrology Research 47.4:672-682. https://doi.org/10.2166/nh.2016.019 Shook, K., Papalexiou, S., Pomeroy, J.W., 2021. Quantifying the effects of Prairie depressional storage complexes on drainage basin connectivity. J. Hydrol. 593, 125846. https://doi.org/10.1016/j.jhydrol.2020.125846 ===== Floodplains ===== Floodplains may be simulated adjacent to a main river or outlet lake. Floodplain is a land area close to the surface water that may be temporary flooded. Water may flow from the surface water to the floodplain and back. The floodplain is a part (//fpf//) of the classarea of the main river or the lake. The lake/river surface area is the rest of the classarea. The floodplain is flooded when the water in the river or lake reaches above a certain threshold. The water on the floodplain may return to the river lake or may be trapped when the water level of the floodplain sink. |{{:start:hype_model_description:FloodScenarios.png?400|}}| | Figure 9: Five possible scenarios of flooding.| ==== Common floodplain processes ==== The water level of the floodplain and the extent of the flooded area (aplain, m2) are calculated from the volume (//volplain//, m3), maximum area (//amax//) and water level at maximum areal extent (//fym//, m). The actual water level will be compared to the equlibrium water level to determine the water exchange. The equilibrium water level is the water level we would have if water was evenly distributed in the lake and the floodplain. It is solved from a second degree equation. wl_plain = sqrt{vol_plain * fym * 2 / a_max} a_plain = wl_plain * a_max /fym a_max = fpf * classarea | {{:start:hype_model_description:FloodVarFlow.png?400}} | | Figure 10: Illustration of floodplain variables of a lake. | The exchange of water between lake (or river) and floodplain is determined by the respective water levels (//wlbody// and //wlplain//), the equilibrium water level (//wlequil//) and the thresholds between the water bodies (//flbody/flplain//). If the water level is over the threshold and higher than the water level of the floodplain the flow from water body to floodplain is: q = rc_bodyToPlain * MIN((wl_lake-fl_body)-wl_equil, (wl_lake-fl_body)) If the floodplain water level is over the threshold and higher than the water level of the water body the flow from floodplain to body is similarly: q = rc_plainToBody * MIN((wl_plain-fl_plain)-wl_equil, (wl_plain-fl_plain)) Floodplain water level (//wlplain//) and degree of flooded area (a_plain/a_max) are possible to print out from a simulation with an outlet lake or main river with floodplain. ==== Simple floodplain model ==== The simple floodplain model simulates precipitation on the floodplain and evaporation from the flooded water, in addition to the exchange of water between the river or lake and the flood plain. All precipitation on the floodplain is contributing to flooded water. ==== Floodplain model with soil routines ==== The floodplain model with soil routines is calculating all soil flows for the non-flooded part of the floodplain. The runoff from the floodplain soil goes to the flooded water, and not to the local stream as it does for ordinary land classes. Precipitation and evapotranspiration is calculated for the flooded water and the non-flooded soil. For the soil part, snow, infiltration and surface runoff, percolation, tile drainage and groundwater runoff is calculated as for an ordinary soil. Infiltration from the flooded water to the soil may occur. Regional groundwater percolation is only calculated for the flooded part together with percolation from the river. |{{:start:hype_model_description:FloodVar2.png?400|}}| | Figure 11: Illustration of floodplain soil flows.| ==== Connected floodplains ==== It is possible for flooded floodplains to limit the water flow from upstream rivers and lakes. This is determined based on the water levels in the floodplains, a higher water level of a downstream floodplain compared to a upstream floodplain may reduced the flow from the upstream compartment (main river or outlet lake) to the downstream compartment (main river or outlet lake). The damming flow is calculated as the flow to reach equilibrium water level between the two floodplains. The relative level of the two floodplains location is determined based om the classes average elevation and thresholds or given as indata separately. The function of connecting floodplains works within a subbasin or between connected subbasins. This floodplain features may be used together with the **Floodplain model with soil routines**. ==== Links to file reference ==== ^Section ^Symbol ^Parameter/Data ^File ^ | |//fpf//|//fpfol, fpfmr//|[[start:hype_file_reference:flooddata.txt|FloodData.txt]]| |Common floodplain processes|//classarea//|//slc_nn, area//|[[start:hype_file_reference:geodata.txt|GeoData.txt]]| |:::|//fym//|//fymol, fymmr//|[[start:hype_file_reference:flooddata.txt|FloodData.txt]]| |:::|//rcbodyToPlain//|//rclfp, rcrfp//|:::| |:::|//rcplainToBody//|//rcfpl, rcfpr//|:::| |:::|//flbody//|//floll, flmrr//|:::| |:::|//flplain//|//flolp, flmrp//|:::| |Connected floodplains| |//hrefl, hrefr//|:::| ==== Links to relevant modules in the code ==== ^ Modules (file) ^ Procedures ^ Sections ^ |[[http://hype.sourceforge.net/doxy-html/namespacesurfacewater__processes.html|surfacewater_processes (sw_proc.f90)]] | add_precipitation_to_floodplain | common floodplain processes| | ::: | calculate_floodplain_evaporation | ::: | | ::: | calculate_floodplain_waterlevel | ::: | | ::: |calculate_waterbody_floodplain_interflow| ::: | | ::: |calculate_floodplain_volume| ::: | | ::: |calculate_floodplain_equilibriumlevel| ::: | | ::: |calculate_regional_floodplain_flows| connected floodplains | | ::: |calculate_two_floodplain_equilibriumlevel_dp| ::: | | ::: |calculate_equilibrium_floodplain_level_eq1dp| ::: | | ::: |calculate_equilibrium_floodplain_level_eq2dp| ::: | | ::: |calculate_equilibrium_floodplain_level_eq3dp| ::: | | ::: |calculate_interflow_between_floodplains2| ::: | |[[http://hype.sourceforge.net/doxy-html/namespacefloodplain__soilmodel.html|floodplain soilmodel (soilmodel4.f90)]] |soilmodel_4 | simple floodplain model | | ::: | ::: | floodplain model with soil routines | | ::: | ::: | connected floodplains | ===== Bifurcations ===== Outflow from a subbasin may flow in one or two directions. The main flow follows the main channel, which is the downstream subbasin given by the path in [[start:hype_file_reference:geodata.txt|GeoData.txt]]. If there is a bifurcation, the branch flow goes to another downstream subbasin (with subid //branchid//). Any of the flows may go outside the model set-ups area, they are then no longer a concern of the model. There are three ways to determine the flow in the different channels. 1) The division of the total outflow is determined in BranchData.txt. 2) The outflow is calculated for two outlets separately and then divided into the channels. For the second alternative see [[start:hype_model_description:hype_routing#outlet_lake_with_two_outlets|Outlet lake with two outlets]] section above. 3) The demanded flow in the branch is prescribed (//Qbranch//). The prescribed flow can be constant and set in BarnchData.txt or variable and given in Xobs.txt (''dwtr''). If the total flow is not enough to fulfil the need, less water goes into the branch. The main channel gets the rest of the total flow. For the first method the total outflow has been calculated the ordinary way. The flows division into the two channels is the determined by four parameters; //mainpart//, //maxQmain//, //minQmain// and //maxQbranch//, which are set in [[start:hype_file_reference:branchdata.txt|BranchData.txt]]. Zero values of the input data mean they are not used. The main flow (//mainflow//) is calculated from the totalflow (//q//) as: mainflow = delim{lbrace}{matrix{4}{2}{q {q<=minQ_main} {mainpart*(q-minQ_main)+minQ_main} {minQ_mainq_thresh \,\ q_thresh={{maxQ_main-minQ_main}/{mainpart}}+minQ_main} {q-maxQ_branch} {q>q_thresh\ ,\ q_thresh={{maxQ_branch}/{1-mainpart}}+minQ_main}}}{} q_thresh=MIN({{maxQ_main-minQ_main}/{mainpart}}+minQmain,{{maxQ_branch}/{1-mainpart}}+minQ_main,0) The rest of the total flow goes in the branch. The following figures give some examples of parameter combinations. * Serie 1: //mainpart// = 0.5, //minQmain// = 2, //maxQmain// = 10, //maxQbranch// = 0 * Serie 2: //mainpart// = 0.5, //minQmain// = 2, //maxQmain// = 0, //maxQbranch// = 5 * Serie 3: //mainpart// = 0.5, //minQmain// = 0, //maxQmain// = 10, //maxQbranch// = 0 * Serie 4: //mainpart// = 0, //minQmain// = 2, //maxQmain// = 0, //maxQbranch// = 5 |{{:start:hype_model_description:mainflow.png?400|}}| | Figure 12: Main flow in relation to total flow for four different parameter combinations.| |{{:start:hype_model_description:branchflow.png?400|}}| | Figure 13: Branch flow in relation to total flow for four different parameter combinations.| ==== Links to file reference ==== ^Symbol ^Parameter/Data ^File ^ |//branchid, Qbranch, mainpart//|//branchid, Qbranch, mainpart//|[[start:hype_file_reference:branchdata.txt|BranchData.txt]]| |//maxQmain, minQmain, maxQbranch//|//maxQmain, minQmain, maxQbranch//|:::| ==== Links to relevant modules in the code ==== ^ Modules (file) ^ Procedures ^ Sections ^ |[[http://hype.sourceforge.net/doxy-html/namespacesurfacewater__processes.html|surfacewater_processes (sw_proc.f90)]] |calculate_branched_flow | - | |:::|calculate_branched_flow_new | - |