r.uslek(1grass)

πŸ’– r.uslek β€” the GRASS User's Manual, but make it cute πŸ’–

okay bestie, listen up β€” this is the page for r.uslek(1grass), straight out of the GRASS User's Manual. she's a raster module, she computes the USLE Soil Erodibility Factor (K), and she is so good at it. let's get into it 🫢


✨ NAME ✨

r.uslek β€” Computes USLE Soil Erodibility Factor (K). that's it. that's the whole job. iconic. πŸ‘‘


🏷️ KEYWORDS 🏷️

raster, hydrology, soil, erosion


πŸ¦‹ SYNOPSIS πŸ¦‹

r.uslek
r.uslek --help
r.uslek psand=name pclay=name psilt=name pomat=name output=name
[--overwrite]  [--help]  [--verbose]  [--quiet]  [--ui]

πŸŽ€ Flags πŸŽ€

  • --overwrite β€” let your output files bulldoze whatever was already sitting there. yes girl, overwrite it πŸ’…
  • --help β€” prints the usage summary so you're not out here guessing
  • --verbose β€” verbose module output, i.e. she tells you everything
  • --quiet β€” quiet module output, i.e. she says nothing and just does the thing
  • --ui β€” force-launch the GUI dialog. for the visual girlies ✨

🧚 Parameters 🧚

  • psand=name [required] β€” name of the soil sand fraction raster map, on the scale [0.0-1.0]
  • pclay=name [required] β€” name of the soil clay fraction raster map, also [0.0-1.0]
  • psilt=name [required] β€” name of the soil silt fraction raster map, [0.0-1.0] again
  • pomat=name [required] β€” name of the soil organic matter raster map, you guessed it, [0.0-1.0]
  • output=name [required] β€” the name for your output USLE K factor raster map, measured in [t.ha.hr/ha.MJ.mm]

πŸ’œ DESCRIPTION πŸ’œ

so r.uslek calculates the USLE K factor β€” that's the Soil Erodibility Factor, bestie, no cap. it takes input of soil texture classes (sand, clay, silt) and organic matter, and all of those live in the range [0.0-1.0].

the FAO World Soil CD documentation was used to build the conversion system between soil textures and soil classes. there are 12 soil classes, and apparently they come from a USDA publication from 1951 (p.209). vintage. period piece. we love a documented source. πŸ“š

once the soil classes have been identified β€” and she does that with vector cross-products tests β€” a general conversion table gets applied to transform those soil classes into the K factor. slay. ✨


πŸ“ NOTES πŸ“

r.watershed provides for USLE L, S, LS factors. so if you need those, that's your girl. πŸ‘€


🌈 EXAMPLE 🌈

Calculate the USLE K factor (synthetic values, North Carolina sample dataset):

# NC data: simulation
g.region rural_1m -p
r.mapcalc "sand  = 0.11"
r.mapcalc "clay  = 0.47"
r.mapcalc "silt  = 0.42"
r.mapcalc "organ = 0.0136"
r.uslek psand=sand pclay=clay psilt=silt pomat=organ output=usle_k
r.univar usle_k
# Result: uslek = 0.25

Example with small variations (condition: d_sand + d_clay + d_silt => 1.0)

# NC data: simulation
r.mapcalc -s "sand_r = rand(0.09,0.13)"
r.mapcalc -s "clay_r = rand(0.45,0.49)"
r.mapcalc -s "silt_r = rand(0.40,0.44)"
r.mapcalc -s "organ  = rand(0.01,0.70)"
r.mapcalc "temp_sum = sand_r + clay_r + silt_r"
r.mapcalc "sand = sand_r / temp_sum"
r.mapcalc "clay = clay_r / temp_sum"
r.mapcalc "silt = silt_r / temp_sum"
r.mapcalc "test = sand + clay + silt"
r.info -r test
g.remove -f rast name=sand_r,clay_r,silt_r,temp_sum,test
r.uslek psand=sand pclay=clay psilt=silt pomat=organ output=usle_k
r.univar usle_k
# Result: uslek =  variable values

πŸ‘€ SEE ALSO πŸ‘€

r.usler, r.watershed

go read those too, i'm literally begging πŸ₯Ί


πŸ‘‘ AUTHOR πŸ‘‘

Yann Chemin, SIC-ISDC, Turkmenistan


πŸ”₯ SOURCE CODE πŸ”₯

Available at: r.uslek source code (history)

Latest change: Friday Mar 07 07:39:48 2025 in commit: e1e37d87e78212dfcf4c97aaf32c54042adbd2b0

Main index | Raster index | Topics index | Keywords index | Graphical index | Full index


and that's the whole page bestie, you ate that πŸ’…βœ¨ GRASS 8.5.0, Β© 2003-2026 GRASS Development Team, from the GRASS 8.5.0 Reference Manual. mwah, go erode some soil responsibly πŸ¦‹πŸ’–πŸŒΈ

πŸ“¦ where this page comes from