Numerical methods
Cross-section construction
Conveyance-storage separation
In 1D hydrodynamic models, flow through a cross-section is resolved assuming a cross-sectionally average velocity. This assumed that the entire cross-section is available to for conveyance. However in reality some parts of the cross-section do not contribute to flow. For example, sections of a river behind a levee where water is stagnant contribute to storage (volume), but not flow.
SOBEK enables distinction between 'flow area' and 'storage area'. fm2prof
implements
methods to resolve from 2D model output which cells add to the 'flow volume' within a
control volume and which to the storage volume.
fm2prof
implements two methods. The configuration parameter ConveyanceDetectionMethod
is used
to determine which method is used.
max_method
A cell is considered flowing if the velocity magnitude is more than the average
of the three higher flow velocities per outputmap multiplied by the
relative velocity threshold
OR
if the flow velocity meets the absolute threshold absolute velocity threshold
mean_method
Not recommended. Legacy method.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
waterdepth |
DataFrame
|
dataframe of a control volume with waterdepths per cel per output map |
required |
velocity |
DataFrame
|
dataframe of a control volume with velocity magnitude per cel per output map |
required |
Returns:
Name | Type | Description |
---|---|---|
flow_mask |
DataFrame
|
dataframe of a control volume with the flow condition per cel per output map. |
Source code in fm2prof\CrossSection.py
1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 |
|
Simplification
The cross-section geometry generated by fm2prof
contains one point per output
timestep in the 2D map file. This resolution is often too high given the
complexity of the cross-sections, and results in very large input files for the
1D model. Therefore fm2prof
includes a simplification algorithm that reduces
the number of points while preservering the shape of the geometry. This algorithm
reduces as many points until the number specified in
MaximumPointsInProfile
is reached.
We use the Visvalingam-Whyatt method of poly-line vertex reduction1. The total width is leading for the simplification of the geometry meaning that the choice for which points to remove to simplify the geometry is based on the total width. Subsequently, the corresponding point are removed from the flow width.
-
Visvalingam, M and Whyatt J D (1993) "Line Generalisation by Repeated Elimination of Points", Cartographic J., 30 (1), 46 - 51 URL: http://web.archive.org/web/20100428020453/http://www2.dcs.hull.ac.uk/CISRG/publications/DPs/DP10/DP10.html Implemented vertex reduction methods: ↩
Parameters:
Name | Type | Description | Default |
---|---|---|---|
count_after |
int
|
number of points in cross-section after application of this function |
20
|
Source code in fm2prof\CrossSection.py
Lake identification
This algorithms determines whether a 2D cell should be marked as Lake.
Cells are marked as lake if the following conditions are both met: - the waterdepth on timestep LakeTimeSteps is positive - the waterdepth on timestep LakeTimeSteps is at least 1 cm higher than the waterlevel on timestep 0.
Next, the following steps are taken
- It is determined at what timestep the waterlevel in the lake starts rising. From that point on the lake counts as regular geometry and counts toward the total volume. A cell is considered active if its waterlevel has risen by 1 mm.
- A correction matrix is built that contains the 'lake water level' for each lake cell. This matrix is subtracted from the waterdepth to compute volumes.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
waterdepth |
DataFrame
|
a DataFrame containing all waterdepth output in the control volume |
required |
Returns:
Name | Type | Description |
---|---|---|
lake_mask |
ndarray
|
mask of all cells that are a 'lake' |
wet_not_lake_mask |
ndarray
|
mask of all cells that are wet, but not a lake |
lake_depth_correction |
ndarray
|
the depth of a lake at the start of the 2D computation |
Source code in fm2prof\CrossSection.py
1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 |
|