Title: Representing a River Network with Graph Theory
1Representing a River Network with Graph Theory
- Class Project
- CS 8715-Spatial Databases
- Instructor-Shashi Shekhar
- Group - G6
- David Moretz Chandana Gangodagamage
2Problem Statement 1 of 2
- Input Geospatial data for the South Fork Eel
River in northern California, including X,Y
coordinates for nodes and edges that represent
river - Output Directed spatial network stored in
PostGres and PostGIS and visualized via MapServer
- Objective Implement a graph theoretic model for
the river network and then develop SQL queries
that would process the following information - Calculate total length of river at each node
- Determine maximum path of river
- Find elevation along flow direction of maximum
path - Find total contributing area for maximum path
3Problem Statement 2 of 2
- Constraints
- River network analysis conducted by using PostGIS
as spatial database instead of using a more
powerful GIS package - Queries and analysis conducted through SQL
instead of creating complex calculations by using
a more powerful programming language such as
Python or PHP - Data file was a simplified version of the actual
river network - Mapserver was used for visualization of results
4Related Work
- Various approaches have been proposed before, but
those approaches have been based around the use
of the ArcGIS/ArcInfo environment - Davis, Kimberley, et al. 2000. Definition of the
Arc Hydrology Data Model.University of Texas at
Austin ed. Vol. 1. Austin, Texas GIS in Water
Resources Converence.
5Motivation
- Develop a directed spatial network using PostGIS
to implement graph theory directly into PostGIS
by using SQL - Visualize the results via Mapserver so that the
data can be widely accessed and distributed over
the Internet
6Major Contributions
- Describe how river network data created in ArcGIS
can be converted from a shapefile and then
inserted into a PostGIS database - Apply a graph theoretic framework to the river
network so that it is possible to perform various
SQL queries to calculate river network
connectivity and network attributes - Implement Mapserver to visualize the results
7Key Concepts
- Model a river network in a PostGIS environment
- Create a spatial database and load data into
Postgres Database - Develop algorithm for river network analysis
- Develop algorithm to create paths from nodes
8Model River Network
- Input data was shape file created from 1M LIDAR
Digital Elevation Model - Simplified river network using the Douglas Pecker
polyline simplification algorithm - Generated multiple attributes for each link
- Elevation
- Cumulative contributing area
- Original river length
- Slope of river reach
- Source node
- Destination node
- Path
9Create Database / Load Data
- Create database within PostGIS system
- Convert shapefile to SQL using shape2sql
- Load SQL file into database
Figure1 Visualization of GIS database for
PostGIS system created from 1M LIDAR DEM.
10River network analysis algorithm
Identify all source points and make a 1D array S,
where S(1) source point 1 Define an array for
path 1 as, P1 Start with source points 1 FOR
i1L where L is the number of source point in
the network S1S(i) P1(i)S1 then select
A,1 find A,1S(i) return index j that tells
the location of S(i) in column 1 then select
Aj,2 P2(i1)AJ,2 END
11River network analysis algorithm
12Validation Methodology
- Combination of theory, experiment, prototype, and
case study - Validation criteria
- Theoretical and Empirical equations developed by
Leopold and Maddock
13Alternative Solutions
- Expand functionality of traditional GIS software
package such as ArcGIS or EMS-Is River Tools by
using VBA scripts - Implement graph theory in another Spatial DBMS
such as Oracle Spatial or ArcSDE - Use programming languages such as Python or PHP
to develop more complex calculations
14Conclusions and Future Work
- It is possible to represent a simplified directed
river network in PostGIS by using graph theory - Work with more complex network data
- Develop more complex algorithm to conduct more
complicated analysis - Utilize MapServer to actually conduct analysis
instead of just display