User Tools

Site Tools


start:hype_tutorials:updating

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
start:hype_tutorials:updating [2018/08/29 11:03]
cpers [Updating of lake water stage (wendupd)]
start:hype_tutorials:updating [2024/01/25 11:37] (current)
Line 10: Line 10:
  
 =====AR – updating of discharge (qar)===== =====AR – updating of discharge (qar)=====
-To use AR-updating of discharge set ''​update qar''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. Subbasins chosen for updating and their AR-factor are given in the file [[start:​HYPE_file_reference:​update.txt|update.txt]]. Recorded values are given in[[start:​HYPE_file_reference:​Qobs.txt|Qobs.txt]]. It is possible to force no updating by setting ''​update qar nostation''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. In this case, the settings in [[start:​HYPE_file_reference:​update.txt|update.txt]] are ignored.+AR-updating of discharge complements the direct updating of discharge by updating flow on time steps without observations. ​To use AR-updating of discharge set ''​update qar''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. Subbasins chosen for updating and their AR-factor are given in the file [[start:​HYPE_file_reference:​update.txt|update.txt]]. Recorded values are given in [[start:​HYPE_file_reference:​Qobs.txt|Qobs.txt]]. It is possible to force no updating by setting ''​update qar nostation''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. In this case, the settings in [[start:​HYPE_file_reference:​update.txt|update.txt]] are ignored.
  
-The updating method applies ​AR-updating on discharge. Timesteps with observations are not updated but the modelled error saved. The AR-updating is then applied on following timesteps without any observation. Let //t0// be a timestep with an observation followed by timesteps (//t+n//) without any observations. Let //AR// be the AR-factor (usually 0-1) set by user, //Qm// = modelled discharge and //Qr// = recorded discharge. Err is the calculated error on the last timestep with observation,​ then the updated discharge (//Qar//) is:+The updating method ​is based on an autoregressive model for the error of discharge. It applies updating on discharge. Timesteps with observations are not updated but the modelled error saved. The AR-updating is then applied on following timesteps without any observation. Let //t0// be a timestep with an observation followed by timesteps (//t+n//) without any observations. Let //AR// be the AR-factor (usually 0-1) set by user, //Qm// = modelled discharge and //Qr// = recorded discharge. Err is the calculated error on the last timestep with observation,​ then the updated discharge (//Qar//) is:
  
 <m> Err(t0) = Qm(t0) - Qr(t0) </m> <m> Err(t0) = Qm(t0) - Qr(t0) </m>
Line 22: Line 22:
  
 =====Updating of lake water stage (wendupd)===== =====Updating of lake water stage (wendupd)=====
-To use lake water updating set ''​update wendupd wstr''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. Subbasins chosen for updating are given in the file [[start:​HYPE_file_reference:​update.txt|update.txt]]. Recorded values (''​wstr''​) are given in [[start:​HYPE_file_reference:​Xobs.txt|Xobs.txt]].+To use lake water updating set ''​update wendupd wstr''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. Subbasins chosen for updating are given in the file [[start:​HYPE_file_reference:​update.txt|update.txt]]. Recorded values (''​wstr''​) are given in [[start:​HYPE_file_reference:​Xobs.txt|Xobs.txt]] or for later versions alternatively in [[start:​HYPE_file_reference:​Wobs.txt|Wobs.txt]].
  
-The updating method replaces modeled water stage of outlet lake with water stage when available. If //Wm// = modelled waterstage and //Wr// = recorded waterstage, then for timesteps with observations (//​Wr//<>​-9999):​+The updating method replaces modeled water stage of outlet lake with water stage when available. The recorded waterstage of a regulated dam is adjusted according to the regulation amplitude (''​wamp''​ in [[start:​HYPE_file_reference:​lakedata.txt|LakeData.txt]] and [[start:​HYPE_file_reference:​damdata.txt|DamData.txt]]) before being used on the simulated waterstage. If //Wm// = modelled waterstage and //Wr// = recorded waterstage, then for timesteps with observations (//​Wr//<>​-9999):​
  
 <m> Wm  = Wr </m> <m> Wm  = Wr </m>
Line 32: Line 32:
 =====AR - updating of lake water stage for discharge (warupd)===== =====AR - updating of lake water stage for discharge (warupd)=====
  
-To update discharge with AR used on lake water stage set ''​update warupd wstr''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. Subbasins chosen for updating are given in the file [[start:​HYPE_file_reference:​update.txt|update.txt]]. Recorded values (''​wstr''​) are given in [[start:​HYPE_file_reference:​Xobs.txt|Xobs.txt]].+To update discharge with AR used on lake water stage set ''​update warupd wstr''​ in [[start:​HYPE_file_reference:​info.txt|info.txt]]. Subbasins chosen for updating are given in the file [[start:​HYPE_file_reference:​update.txt|update.txt]]. Recorded values (''​wstr''​) are given in [[start:​HYPE_file_reference:​Xobs.txt|Xobs.txt]] or for later versions alternatively in [[start:​HYPE_file_reference:​Wobs.txt|Wobs.txt]].
 This method cannot be used in combination with updating methods ''​qar''​ or ''​wendupd''​. This method cannot be used for regulated lakes. This method cannot be used in combination with updating methods ''​qar''​ or ''​wendupd''​. This method cannot be used for regulated lakes.
  
-The updating method applies AR-updating on error of water stage in outlet lake. The output variable for water stage is updated with the current ​AR-changed ​error or a saved AR-change. Let t0 be a timestep with an observation followed by timesteps(t+n) ​ without any observations. Let //AR// be the AR-factor (usually 0-1) set by user, //Wm// = modelled water stage and //Wr// = recorded water stage. Err is the calculated error on the last timestep with observation,​ then the updated ​discharge ​(//War//) is:+The updating method applies AR-updating on error of water stage in outlet lake. The output variable for water stage is updated with the current error or with the updated ​AR-change. Let t0 be a timestep with an observation followed by timesteps(t+n) ​ without any observations. Let //AR// be the AR-factor (usually 0-1) set by user, //Wm// = modelled water stage and //Wr// = recorded water stage. Err is the calculated error on the last timestep with observation,​ then the updated ​water stage (//War//) is:
  
 <m> Err(t0) = Wm(t0) - Wr(t0) </m> <m> Err(t0) = Wm(t0) - Wr(t0) </m>
Line 43: Line 43:
 The change made in the last timestep is saved for the next timestep and then multiplied with AR again. The change for the last timestep is saved to the statefiles when an output state is asked for. This change is used for continued AR-updating after the model is restarted from the saved state. The change made in the last timestep is saved for the next timestep and then multiplied with AR again. The change for the last timestep is saved to the statefiles when an output state is asked for. This change is used for continued AR-updating after the model is restarted from the saved state.
  
-The AR-updated water stage is then used to calculate the current discharge. The current discharge is calculated as the mean of the discharge (at the end of) last time step and the discharge (at the end of) current time step with a rating curve.+The AR-updated water stage is then used to calculate the current discharge. The current discharge is calculated as the mean of two discharges calculated with a rating curve. The first discharge ​is calculated from the updated water stage (at the end of) last time step and the second ​discharge ​is calculated from the updated water stage (at the end of) current time step.
  
 The updating method does not replace the state of modeled water stage of outlet lake with observed water stage. Only the modeled water stage that are printed to file are changed. ​ The updating method does not replace the state of modeled water stage of outlet lake with observed water stage. Only the modeled water stage that are printed to file are changed. ​
  
-For lake basins, only the last lake basin may be updated. The output variable will be updated to the water stage of the whole lake. The state variable(s) of the last lakebasin ​will be updated ​to recorded waterstage recalculated ​to represent the area of the last lakebasin.+For lake basins, only the last lake basin may be updated. The output variable will be updated to the water stage of the whole lake.  
 + 
 + 
 +=====Direct updating of substances/​concentrations ​(cuseobs)===== 
 + 
 +To use direct updating ​of substances set ''​update cuseobs''​ in [[start:​hype_file_reference:​info.txt|info.txt]]. Similar to direct updating of discharge, concentrations of discharge ​will be replaced with observations. Subbasins chosen for updating are given in the file [[start:​hype_file_reference:​update.txt|update.txt]]. Recorded values are given in [[start:​hype_file_reference:​xobs.txt|Xobs.txt]]. It is possible ​to force updating on all stations with observations by setting ''​update cuseobs allstation''​ in [[start:​hype_file_reference:​info.txt|info.txt]]. It is also possible ​to force no updating by setting ''​update cuseobs nostation''​ in [[start:​hype_file_reference:​info.txt|info.txt]]. In case of these latter two options, ​the settings in [[start:​hype_file_reference:​update.txt|update.txt]] are ignored. 
 + 
 +The updating method replaces calculated concentration in discharge with observed values when available. If Cm = modelled concentration and Cr = recorded concentration,​ then for timesteps with observations (Cr<>​-9999):​ 
 + 
 +<m> Cm = Cr </​m>​ 
  
 =====Updating of total phosphorus (TP) and total nitrogen (TN) concentration===== =====Updating of total phosphorus (TP) and total nitrogen (TN) concentration=====
Line 63: Line 73:
  
 <m> TPc  = TPm * (1+tploccorr) </m> <m> TPc  = TPm * (1+tploccorr) </m>
- 
- 
- 
- 
  
  
  
start/hype_tutorials/updating.1535533399.txt.gz · Last modified: 2023/11/16 14:28 (external edit)