3.66667

3.7 | 3 ratings Rate this file 122 downloads (last 30 days) File Size: 107.89 KB File ID: #14504

Flow Accumulation (upslope area)

by Wolfgang Schwanghart

 

02 Apr 2007 (Updated 07 Jan 2009)

Code covered by BSD License  

Flow accumulation algorithm that routes through flats

Download Now | Watch this File

File Information
Description

How much water flows where? Use this algorithm to calculate the upslope area of each cell in a digital elevation model.

Algorithm specifications:
- multiple flow direction
- single flow direction
- routes across flats
- calculates deterministic, randomized and random flow
- allows you to specify a weighting exponent that governs the relation flow direction - slope
- handles edge effects

Acknowledgements
This submission has inspired the following:
Strahler Stream Order
MATLAB release MATLAB 7.0.1 (R14SP1)
Zip File Content  
Other Files example_dem.mat,
flowaccumulation.jpg,
ixneighbors.m,
wflowacc.m
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (7)
28 Jun 2007 looks good

looks good

29 Jun 2007 Salvatore Manfreda

Good, but do not have a fill sinks option that would be very useful.

02 Jul 2007 Wolfgang Schwanghart

I did not include a fill sinks option as it requires the image processing toolbox. If you have this toolbox use

demfs = imfill(dem,'holes')

Best regards,
Wolfgang

16 Apr 2008 Jorge Santos Santos

Does not work for large rivers

18 Apr 2008 Wolfgang Schwanghart

Hi Jorge,

you are right. The algorithm is quite memory demanding and grids exceeding 600x600 cells may cause problems. I am currently working on an improved version that allows for huge grids. Please be a bit patient...

Best regards,
Wolfgang

06 Nov 2008 Liam Reinhardt

A good user friendly piece of code. Unfortunately it does not seem to generate single thread 'rivers' 1 cell wide. Instead cells of high accumulation are often adjacent to each other (i.e. perpendicular to the primary flow direction) producing messy flow paths.

10 Nov 2008 Wolfgang Schwanghart

Hi Liam,

thanks for your feedback. The code is it stands right now is a multiple flow direction algorithm, and yes, it can be very "dissipative". There is a way to avoid this behavior by element-wise exponentiate the flow direction matrix (M), so that steep gradients gain a larger weight than smaller ones.

I'll work on an update of this version and include it as an additional option.

Thanks a lot again for the feedback.

Wolfgang

Please login to add a comment or rating.
Updates
10 Nov 2008

included single flowdirection and the exponent for flow direction weighting to address the problems encountered by Liam.

07 Jan 2009

an option was added to control flow behavior at grid edges

Tag Activity for this File
Tag Applied By Date/Time
hydrology Wolfgang Schwanghart 22 Oct 2008 09:06:58
geomorphology Wolfgang Schwanghart 22 Oct 2008 09:06:58
elevation Wolfgang Schwanghart 22 Oct 2008 09:06:58
earth sciences Wolfgang Schwanghart 22 Oct 2008 09:06:58
algorithms Cristina McIntire 10 Nov 2008 11:50:10
geomorphology Cristina McIntire 10 Nov 2008 11:50:19
earth sciences Cristina McIntire 10 Nov 2008 11:50:26
model Cristina McIntire 10 Nov 2008 11:50:44
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com