Magnitudo¶
The magnitude of a cell is the number of sources upstream of it, the sources being the cells into which nothing drains. On the drainage directions of the network alone, the sources are the channel heads, and the magnitude is the Shreve (1966) magnitude: 1 for the first links, the sum of the two magnitudes at each confluence. It measures the size of the network upstream, as the contributing area measures the size of the basin.
On the drainage directions of the whole terrain, the sources are the cells on the divides, and the magnitude grows with the contributing area.
Details¶
In a network where two channels join at every confluence, a network of magnitude n has 2n - 1 links: n exterior links, from the sources to the first confluence, and n - 1 interior ones. As every source drains a comparable area, the magnitude is also a rough index of the contributing area.
Parameters¶
Calculates the magnitude of each cell: the number of sources upstream of it, the sources being the cells into which nothing drains. On the drainage directions of the network alone, the sources are the channel heads and the result is the Shreve magnitude of the network.
Toolbox folder: Network
Status: Certified
Keywords: Network, Magnitude, Shreve
Authors: Erica Ghesla - erica.ghesla@ing.unitn.it, Antonello Andrea, Cozzini Andrea, Franceschi Silvia, Pisoni Silvano, Rigon Riccardo
Class: org.hortonmachine.modules.Magnitudo
Inputs
Parameter |
Type |
Unit |
Default |
Description |
|---|---|---|---|---|
|
raster file |
The map of the drainage directions. |
Outputs
Parameter |
Type |
Unit |
Description |
|---|---|---|---|
|
output file |
The map of the magnitude. |
References
Shreve, R. L. (1966). Statistical law of stream numbers. The Journal of Geology, 74(1), 17-37.
Example¶
The example runs on the sample elevation model of the manual, dtm_flanginec.tif in docs/manual/modules/maps/data, each module on the outputs of the previous ones:
import org.hortonmachine.modules.CutOut
import org.hortonmachine.modules.Magnitudo
// the folder with the elevation model: change it to yours
var folder = "/data/flanginec/"
// keep the drainage directions of the network only, so that the sources are the channel heads
var cutOut = new CutOut()
cutOut.inRaster = folder + "drain_marked.tif"
cutOut.inMask = folder + "net_basin.tif"
cutOut.outRaster = folder + "drain_net.tif"
cutOut.process()
var magnitudo = new Magnitudo()
magnitudo.inFlow = folder + "drain_net.tif"
magnitudo.outMag = folder + "magnitudo.tif"
magnitudo.process()
The Shreve magnitude of the network of the basin of ExtractBasin, from 1 at the channel heads to 24 at the outlet.¶