If a river diverges from its talweg implied in valley fragments, the constraint is violated and certain strategies are needed to maintain the river's proper course.
To alleviate the problems described earlier, we further propose a post-processing as follows based on the water flow direction and talweg direction:
If the distance metric for matched river and talweg segments equals zero or is small enough, the river segment is consistent with the valley fragments.
The second method is to displace contour valley fragment groups so that the implicit talweg is consistent with the river segment.
As shown in Figure 18, when a river segment is far away from its talweg, the displacement of contour fragments dramatically changes the representation of topographic forms and also leads to crossing conflicts between neighboring contours.
One is the angular deviation ([theta]) between the river segment and its talweg segment, and another is the relative distance from the river segment to its talweg segment.
This ultimately results in a natural phenomenon that rivers always flow into their talwegs in the physical world.
Based on the above constrains, we can find the logical corresponding relationships between river segments and contour fragments that imply talwegs, which further allows for the identification and correction of inconsistencies between river and contour features.
After establishing the relationships mentioned earlier, we can compute the position deviation between river segments and their corresponding talwegs in order to be able to judge whether their positions are consistent or not.
A simple solution is replacing river segments with approximate talwegs that connect from the valley bottom points.