Marine Biology Simulation Program:
Using the Graphical User Interface

The Advanced Placement® Marine Biology Simulation case study is a simulation program designed to help marine biologists study fish movement in a small, bounded environment such as a lake or bay. 

The simulation program is distributed with a graphical user interface (MBSGUI), described in this help file.  Topics include:

Notes:

  1. This document does not describe how to compile and run the Marine Biology Simulation program, which depends on the specific type of computer and software you are using.  Information on compiling and running the program on a number of common platforms can be found in the ExecutionInformation folder under the main JavaMBS folder.  The actual case study document can be found in the Narrative folder.
  2. You may run the Marine Biology Simulation program using the graphical user interface described in this document or using an interface provided from another source.  The Advanced Placement exam will not test students on the specifics of the graphical user interface.  See the Introduction to the case study document for more information on what may be covered on the exam.

Opening an existing initial configuration file

The Marine Biology Simulation (MBS) case study is distributed with a number of initial configuration files in the DataFiles folder, including the fish.dat, manyFish.dat, and onefish.dat files mentioned in Chapter 1.  (You may not see the .dat extensions if your computer environment doesn't show them automatically.)  To choose an initial configuration file:

The program will display the environment for the configuration file you chose as a rectangular grid of locations, with fish in the locations specified in the initial configuration file.

(Go to top of help file.)

Running the simulation

You can run the Marine Biology Simulation program one timestep at a time, or continuously for many timesteps.

(Go to top of help file.)

Saving the current state as a new configuration file

At any time while running the Marine Biology Simulation program, you can save the current state of the environment as a configuration file.  You can then use this file later as an initial configuration file for a new run of the simulation, to continue the current run of the simulation, or to compare results from a different run of the simulation (see Chapters 3 and 4 of the MBS case study for more information about regression testing).

(Go to top of help file.)

Creating and populating a new environment

You can use the graphical user interface for the Marine Biology Simulation program to create new environments in several ways.  You can open an initial configuration file, run it for several timesteps, and then save that environment to a file.  (See "Opening an existing initial configuration file," "Running the simulation," and "Saving the current state as a new configuration file.")  You can also create a new environment from scratch, specifying the size of the environment and the initial locations and directions of all the fish in it.  Or, you can edit the current state of an environment, adding and removing fish.  This section describes creating new environments and editing environments.

Creating a new environment:

Editing an existing environment:

Adding fish to, and removing them from, an environment:

When you are creating or editing an environment, a new panel appears with two pull-down menus.  The first allows you to choose the type of the next fish to add to the environment.  The second allows you to choose the next fish's color.

After you create or edit an environment, you may wish to Save it to a configuration file.  You can run the simulation on the new or modified environment by clicking on the Step or Run buttons, at which time the extra panel for creating new fish will disappear.

(Go to top of help file.)

Seeding the random number generator

You can set a seed for the random number generator when opening or creating new environments.  If you use the same seed for several simulation runs, starting with the same initial configuration, the fish in the simulation will exhibit the same behavior each time.

(Go to top of help file.)

Viewing large environments

The environment display adjusts the size of the grid cells depending on the number of cells in the grid.  The cells in a grid with very few cells will be quite large, whereas the cells in a grid with many cells will be much smaller.  If, however, the cells would be too small to show fish clearly, then the graphical user interface displays only part of the environment and provides scroll bars for viewing other parts of the environment.  There are also several options in the View menu for viewing large environments.

(Go to top of help file.)

Customizing the graphical user interface

You can customize the MBS graphical user interface in several ways. (These are advanced features of the graphical user interface.)

(Go to top of help file.)

This document describes the 1 August 2002 release of the Marine Biology Simulation Graphical User Interface (MBSGUI).

Copyright© 2002 College Entrance Examination Board (www.collegeboard.com).