r.surf.area(1)

✨ r.surf.area πŸ’–

okay bestie, welcome to the GRASS GIS User's Manual page for r.surf.area β€” she's a little raster surface-area calculator and she's lowkey iconic πŸŽ€


🌸 NAME 🌸

r.surf.area β€” prints estimation of surface area for raster map. that's it, that's the whole vibe πŸ’…


πŸ¦‹ KEYWORDS πŸ¦‹

raster, surface, statistics, area estimation ✨


πŸŽ€ SYNOPSIS πŸŽ€

r.surf.area
r.surf.area --help
r.surf.area map=name  [vscale=float]   [units=string]   [--help]
[--verbose]  [--quiet]  [--ui]

πŸ’œ Flags:

  • --help β€” prints the usage summary, the lil "how do I even" moment 🫢
  • --verbose β€” verbose module output, she's gonna yap (affectionately) πŸ—£οΈ
  • --quiet β€” quiet module output, she's gonna shut up (also affectionately) 🀫
  • --ui β€” force launching GUI dialog, pop that window open like it's a gift 🎁

🌈 Parameters:

  • map=name [required] β€” name of raster map. yes you HAVE to give her one, she's not guessing πŸ”₯
  • vscale=float β€” vertical scale. Default: 1.0 πŸ“
  • units=string β€” output units. Default: square map units. Options: miles, feet, meters, kilometers, acres, hectares πŸ‘‘

πŸ’– DESCRIPTION πŸ’–

so r.surf.area calculates the area of regular 3D triangulated points β€” that's the centers of cells, bestie β€” in the current region, by adding up the areas of triangles. it's giving geometry homework but make it slay ✨

therefore, the area of a flat surface will be reported as (rows + cols -1) * (area of cell) β€” which is less than the area of the flat region, because there's a half row and half column missing around the perimeter. yeah. she's a lil short, it's the edge effect, we'll get to that 😭


πŸ’… NOTES πŸ’…

this calculation is heavily dependent on data resolution. think of it like the fractal shoreline problem: the more resolution, the more detail, the more area, etc. πŸ“ˆ

this module uses the current region settings, NOT the resolution of the raster map. this is especially important for surfaces with NULL values and highly irregular edges. the module does not [currently] attempt to correct for the error introduced by this edge effect. so like… she knows, she just isn't fixing it rn πŸ™ˆ

this version actually calculates area twice for each triangle pair, keeping a running minimum and maximum area depending on the direction of the diagonal used. double the math, double the drama πŸ’€

reported totals are:

  1. "Plan" area of NULL values within the current GRASS region
  2. "Plan" area within calculation region (rows-1 * cols-1 * cellarea)
  3. Average of the minimum and maximum calculated 3d triangle area within this region
  4. "Plan" area within current computational region (rows * cols * cellarea)
  5. Scaling of calculated area to current region

r.surf.area works best when the surface being evaluated extends to the edges of the current region and the cell resolution is small 🧚

surfaces which are especially long and thin and have highly irregular boundaries will tend to have underestimated surface areas πŸ˜” setting a high cell resolution (small area) will greatly reduce this impact, but will cause longer processing times. the classic tradeoff, the way that she makes you wait ⏳


⭐ EXAMPLES ⭐

g.region -p raster=elevation
r.surf.area map=elevation units=hectares
Null value area ignored in calculation: 0.000000
Plan area used in calculation: 20221.510000
Surface area calculation(low, high, avg):
        20294.310421 20320.936368 20307.623395
Current region plan area: 20250.000000
Estimated region Surface Area: 20336.234719

look at those numbers go, she ate and left no crumbs πŸ“


🌈 SEE ALSO 🌈

g.region, r.surf.idw, r.surf.fractal, r.surf.gauss, r.volume, r.slope.aspect, v.to.rast β€” the whole friend group, go say hi 🫢


πŸ‘‘ AUTHOR πŸ‘‘

Bill Brown, USACERL December 21, 1994 πŸŽ‚

Modified for floating point rasters and NULL values by Eric G. Miller (October 17, 2000) πŸ’œ

Updated for GRASS 7, and units option by Martin Landa, Czech Technical University in Prague, Czech Republic (October 2011) πŸŽ“


πŸ’€ SOURCE CODE πŸ’€

Available at: r.surf.area source code (history)

Accessed: Saturday Jan 17 05:41:01 2026

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


okay that's the whole page, bestie!! πŸ₯³ and for the cute lil sign-off: this is GRASS 8.4.2, footer says GRASS 8.4.2 with r.surf.area(1), and the whole thing is Β© 2003-2025 GRASS Development Team, GRASS GIS 8.4.2 Reference Manual πŸ’–βœ¨ no cap, go calculate some surface area, you got this πŸ¦‹πŸŽ€

πŸ“¦ where this page comes from