Proceed to GeoCommunity Home Page


SpatialNewsGIS Data DepotGeoImaging ChannelGIS and MappingSoftwareGIS JobsGeoBids-RFPsGeoCommunity MarketplaceGIS Event Listings
HomeLoginAccountsAboutContactAdvertiseSearchFAQsForumsCartFree Newsletter

Sponsored by:


TOPICS
Today's News

Submit News

Feature Articles

Product Reviews

Education

News Affiliates

Discussions

Newsletters

Email Lists

Polls

Editor's Corner


SpatialNews Daily Newswire!
Subscribe now!

Latest Industry Headlines
Supergeo Renews Partnership Agreement with Information & Science Techno System Co. in Japan
GISCI Begins Exam Development
Esri and Institute of Fire Engineers Partner to Improve Fire Prevention Planning
Canadian Organizations Shine at the 2013 Esri International User Conference
Atlantic Secures Key Environmental Services Designation from GSA
Conference Addresses the use of Geographic Intelligence for Business and Security

Latest GeoBids-RFPs
GPS Equipment*Canada
Surveying Services*Canada
Hydrological Assessment*Belize
Nautical Charts*Poland
Software & Telemetry GPS

Recent Job Opportunities
Planner/GIS Specialist
Team Leader- Grape Supply Systems
Geospatial Developer

Recent Discussions
Raster images
cartographic symbology
Telephone Exchange areas in Europe
Problem showcasing Vector map on Windows CE device
Base map

GeoCommunity Mailing List
 
Mailing List Archives

Subject: Re: GISList: Locating ridgelines
Date:  02/26/2002 02:30:55 PM
From:  Quantitative Decisions



At 12:35 PM 2/26/02 -0500, Ned Horning wrote:
>how do I define a ridgeline with a DEM as input?

The cells along a ridge line that trends in a given direction, v, have
aspects approximately at v + 90 degrees to the right and v - 90 degrees to
the left. Thus, one way is to search for all such cells. This can be
neatly approximated using the FlowDirection codes returned by ESRI's
Spatial Analyst: each code corresponds to a 45 degree window of
aspects. The appended script provides the details. The computation is
quick. One can also use an aspect grid and even a hillshaded grid to
perform similar computations. A nice byproduct of this approach is the
resulting grid not only identifies apparent ridge lines, but also indicates
their approximate trend direction.

Of course you will not get continuous lines this way. Most ridges bump a
little up and down. The down points are saddle points, which within a
sufficiently small region are quite flat. Therefore you should expect to
see your ridges outlined in a dashed pattern, rather than
continuously. The way I have coded it, such lines will be about three
cells thick. You can make them thicker or thinner depending on how large a
neighborhood you use around each cell.

--Bill Huber
www.quantdec.com
'
' Estimates ridgelines in the first active grid theme.
'
' Quantitative Decisions
' 26 Feb 2002
'
theView = av.GetActiveDoc
'
' Obtain the input DEM.
'
lThemes = theView.GetActiveThemes
if (lThemes.Count = 0) then return NIL end
thmDEM = lThemes.Get(0)
if (thmDEM.Is(GTheme).Not) then return NIL end
gDEM = thmDEM.GetGrid
'
' Find its origin and cell size.
'
xCell = gDEM.GetCellSize
ptO = gDEM.GetExtent.ReturnOrigin
'
' Compute the flow grid,
'
gFlow = gDEM.FlowDirection(false)
'
' Shift flows by one cell in all eight cardinal directions.
'
lPtDirections = {
-1@0, ' Shift to the West
-1@1, ' Northwest
0@1, ' North
1@1, ' Northeast
1@0, ' East
1@(-1),' Southeast
0@(-1),' South
-1@(-1)' Southwest
}
lgShift = {}
for each ptIJ in lPtDirections
lGShift.Add(gFlow.Shift(ptO + (xCell@xCell * ptIJ), NIL))
end
'
' Compare opposite directions at each cell.
' E.g., the first comparison considers whether the cell to the
' east flows east and the cell to the west flows west. If so,
' a code of j=1 is accumulated into gRidge and this indicates
' the cell looks like part of a north-south ridge line.
' The loop proceeds around the compass in the other three pairs
' of directions, using codes j=2 for NE-SW ridge lines, j=4 for
' E-W, and j=8 for NW-SE.
'
gRidge = 0.AsGrid
for each i in 0..3
j = 2^i ' Flow direction code
gRidge = ((lGShift.Get(i) = j) and (lGShift.Get(i+4) = (16*j))) * j + gRidge
end
'
' Display the result.
'
thmRidge = GTheme.Make(gRidge)
thmRidge.SetName("Ridges for" ++ thmDEM.GetName)
theView.AddTheme(thmRidge)
' end of script



To unsubscribe, write to gislist-unsubscribe@geocomm.com
________________________________________________________________________
Setup a GeoCommunity Account and have access to FAST DataDownloads
and Premium Career Posting at a discounted rate!
https://www.geocomm.com/cgi-bin/accounts/login

On-line Archives available at
http://spatialnews.geocomm.com/community/lists/


Sponsored by:

For information
regarding
advertising rates
Click Here!

Copyright© 1995-2012 MindSites Group / Privacy Policy

GeoCommunity™, Wireless Developer Network™, GIS Data Depot®, and Spatial News™
including all logos and other service marks
are registered trademarks and trade communities of
MindSites Group