Home
> Miscellaneous
> Math 130
Peaks, Pits, and Passes
Instructions
| Colours
| Explanation
| Source Code
File Drop Down Menu:
Use this menu to select the dataset to display.
Slider:
The slider controls the water level. Higher numbers represent higher contour
levels. Setting the slider to a higher value causes the water to rise higher.
Buttons:
- Step
Causes the water level to rise one level.
- Animate
Causes the water to rise one level at a time. Once the maximum
level has been reached, the water level resets to the minimum level.
- Stop
Stops the animation.
- Reset
Resets the water level to zero, and stops the animation if
necessary.
- Green = "Land"
The brighter the green, the higher the land is above water.
- Blue = "Water"
Dark blue represents deep water, light blue represents shallow
water.
- Brown = "Beach"
This level is just above the water.
Project write-up.
This applet illustrates the relation:
#Peaks + #Pits - #Passes = #Islands
- MorseDemoApp.java
The main class. The demo can be run as both an applet in a browser
and as a standalone application.
- MorseCanvas.java
The canvas for drawing and animating the elevation data.
- ContourTree.java
A data structure for storing the elevation contours in a tree.
- LinkedList.java
A small generic linked list class.
- Lib.java
A small library containing methods for reading integers and doubles
from a text file.
Instructions
| Colours
| Explanation