All data pertaining to an individual deer are contained in a data structure. The deer data structure used in the parallel SIMPDEL model requires several additional fields (Figure 7), as compared to the structure used in the sequential model. The fields related to the deer foraging process: daily_trav, save_trav, intake, graze_time, graze_dist, and energy_gain, of the parallel structure are global variables in the sequential model. The floating-point values stored in these global variables always correspond to the current foraging deer, since no other deer can begin the foraging sequence until the current deer's sequence has ended. A deer may graze on several grid cells before it's daily intake is fulfilled, requiring these variables to be updated for each grazing step. However, in the parallel model, a deer may be moved to a new processor during the foraging sequence (to be explained in Section 3.3.5) and its foraging continued at the new location. By containing these variables as fields in the deer data structure, the copying and recopying of deer data each time a deer is moved to a new processor is avoided.
Figure 7: Parallel deer data structure (new fields are shown in italics).
The data structure fields num_moves, graze, and removed are specific to the parallel model. The integer num_moves is used to examine the number of times a deer moves across processor boundaries, and is incremented for each move. The integer graze is assigned the value of the class of forage for which the deer is searching (FQ_HIGH, FQ_MEDIUM, or FQ_LOW) before being moved to a location on a new processor. The integer value stored in removed is used to determine if a deer has been logically removed from the deer array, due to mortality or movement between processors. A deer is first logically removed, by setting its removed field to 1, before being physically removed (by deallocating memory) at the end of the day, in order to avoid constant compressions of the deer array.