In order to accurately predict where the water will flow it is important to fill in any holes that may exist in the DEM.





The water in each cell will flow into the adjacent cell with the lowest elevation. The above image shows the this--the flow direction.

The above image shows the flow accumulation for all of the streams. It takes the filled DEM (the one that now has no holes) and finds the highest pixel for each area. The water from this pixel will flow into the adjacent pixel with the lowest elevation - the flow direction. These will now give you a flow accumulation - each pixel has a record of how much water from surrounding pixels will flow into it. Next, using a Matlab Code called "Stream Profiler" I will follow the elevation changes in the flow accumulation in order to look at the stream profile, or the elevation changes of the stream bed along its length. The Matlab codes I will use is below. There are other functions on which these code calls that I have not listed here. They can be found at http://www.geomorphtools.org/Tools/StPro/Tutorials/StPro_UserGuidees_Final.pdf The first code analyzes the streams in batches, and the second code allows the user to define the watershed for each individual stream.

Stream Profiler in batches
Stream Profiler individual