[GRASSLIST:8374] Re: EUCALLOCATION in GRASS?
Hamish
hamish_nospam at yahoo.com
Wed Sep 21 22:16:42 EDT 2005
> The EUCALLOCATION function takes a categorical raster as input. Any
> null cells are assigned the category value of the nearest known value
> based on euclidean distance (hence the name). You can work with
> floating point values by converting them to integer "categories". This
> is useful for extrapolating into null areas without changing the value
> of the last known good point.
r.grow can be used to do this, perhaps with a r.mapcalc masking step
before/mid/after.
> I do wave modeling and sometimes the shoreline in the model doesn't
> match up with higher resolution bathymetry in GRASS. So I wind up with
> waves that are breaking well seaward of the real shoreline. What I
> want to do is extrapolate the wave values from the low-resolution data
> shoreward to the beach on the high resolution model. I don't want to
> change the values in those last known good cells using a neighborhood
> function, just "move" them shoreward and fill in the data gap.
>
> Any ideas on how to do this?
Be careful doing this-- the energy dissipation of the wave model will be
resoloved for the model's domain in a finite sense, and by entending the
surf zone in towards shore you will be artifically increasing its
integrated magnitude.
Someday I hope to get SWAN going for more than 500x500 cells.... it has
horribly wasteful memory usage and also segfaults if you try and
allocate more than 2gb RAM (at least for me).
There's also the common problem that before modern LIDAR bathymetry
(which can see down to 20m) there was generally pretty poor nearshore
coverage by nautical surveyors (can't blame them not wanting to get in
among the rocks and breaking waves really). So you end up trying to
interpolate a DEM from a coastline and the coastline of any nearby
islands. With no soundings in between you are going from 0m->0m across
the bay.. you can try to fix this by including lots of above ground
topography in the DEM creation step to keep the downward "momentum" of
the slope of the beach, but if you have cliffs or the like near the
water's edge this all falls over with bad overshoots, and is generally
a pretty dodgy assumption anyway.. but better than nothing.
Hamish
More information about the grass-user
mailing list