ENCN205 — Lecture 03: Spatial Data Models

Interactive Demo: Vector vs Raster — Banks Peninsula DEM
~10 min activity
MODE: VECTOR — Contour Lines

Vector vs Raster Explorer

Same terrain, two fundamentally different data models

View Mode

Low
High
0m200m400m600m780m

Raster Opacity

0%80%100%

Data Comparison

Area:4 km x 4 km
Raster grid:500 x 500 cells
Raster resolution:8 m per cell
Raster values:250,000 elevation values
Vector contours:—
Contour interval:50 m
Click any contour line to see its geometry type, coordinate count, and elevation.
Feature Info (click a contour)
Geometry type:—
Vertex count:—
Elevation:—
Position (km):—
Case Study: This 4 km x 4 km section of Banks Peninsula terrain is shown as vector contour lines (every 50 m) and as a raster DEM grid (250,000 cells at 8 m resolution). The same real-world elevation is captured in fundamentally different ways.

Guided Questions

Q1

Toggle between Vector and Raster DEM views. Which representation makes it easier to identify a specific elevation (e.g., the 200 m contour)? Which better shows the continuous terrain surface?

Q2

The DEM has 8 m resolution (250,000 cells). The contour lines have far fewer vertices. What information is lost between contour lines that the raster preserves? What does the vector preserve that the raster does not?

Q3

Click a contour line and note the vertex count. Each vertex stores an [x, y] coordinate pair. How does the data storage per elevation value compare between the vector model (vertices along lines) and the raster model (one value per cell)?

Q4

If you needed to calculate the slope gradient at every point across this area, which data model would you use — vector contours or the raster DEM? Why?

Q5

An engineer needs to design a road route across this terrain, keeping the gradient below 10%. Would you deliver the data as contour lines, a DEM raster, or both? What resolution would be appropriate?