The Interaction Scenario


The Interaction scenario is a predator-prey model that illustrates several important HexSim features. These include the simulation of both females and males, the forming of male-female pairs, population interactions, the use of a genetic trait, and the Event Group, Mutation, and Generated Hexmap events.

To make the Interaction scenario easier to understand, the events for each population have been segregated into Event Groups. The prey population lives in colonies of up to 200 individuals, and they are broken up into males and females, juveniles and adults, and three resource acquisition classes. Every member of the prey population has a resource target of 5. The prey population extracts resources from a Hexmap named Habitat Map.

The predators are solitary. They are stratified into males and females, juveniles, subadults, and adults, and three consumption classes that record the number of prey items acquired. Predators also have traits that record whether or not they are paired, whether they are hungry, and how effective they are at capturing prey items.

In contrast to the prey population, the predators have resource targets of zero, because they do not acquire resources from the landscape. Predator resource acquisition is based on the number of prey items consumed. And the predators' ability to catch prey varies based on their capture efficiency. The predators have a maximum range size of 1 hexagon, and they spend their entire lives as floaters.

The predator's Capture Efficiency trait is linked to a locus named Capture Efficiency. The locus has three alleles: 0, 1, and 2. The initial population possesses only allele 0, which forces every individual to have low capture efficiency. However, a child's capture efficiency can change if one or both of its parents previously experienced a random genetic mutation, and a Mutation event in this scenario ensures that this will in fact happen. The Capture Efficiency trait has five trait values that link capture efficiency to allele combinations using a simple scheme. Individuals with larger capture efficiencies tend to consume more prey items, which in turn increases their fitness.

The Event Sequence

The Event Sequence begins with an Introduction event that adds the predator population to the simulation. This is done at time step 10, to first give the prey a chance to become established. If the predators are introduced at time step zero they will have trouble finding prey, and will perish.

The Introduction event is followed by three Event Groups, each of which contains a number of life history events. The first Event Group handles the prey life cycle, the second handles the predators, and the final group contains a collection of Census events.

The Prey

The prey population's life cycle begins with an Accumulate event that makes individuals age. This is followed by a Floater Creation event that removes from groups any individuals who can not attain at least 70% of their target resource. Adults are given priority over juveniles in this event. This is followed by a Movement event that sends prey floaters out across the landscape in search of a group to join. If they cannot find a group to join, but are able to start a new group, they will do so.

The members of the prey population then accumulate resources from the landscape, and the adult females reproduce. Reproduction is stratified by both stage and resource class. Adult females only reproduce if their group contains at lease one adult male. This simple form of temporary male-female pairing is handled internally by the Reproduction event when the Use Mate Selection check-box is selected. Doing this adds a Mate Selection tab to the Reproduction event. The Mate Selection tab is used to specify the characteristics that a group member must have to qualify as a viable mate.

Reproduction is followed by a Survival event, which is stratified by both stage class and resource class. Next, a Generated Hexmap event is used to map the prey locations (this map is used later by the predators). The generated Hexmap is both smoothed and re-scaled.

The Predators

The event sequence next handles the predator population. First, an Accumulate event makes each predator older, and then clears records of prey items consumed and past predator pairings. Next, the predators move in search of prey. Their dispersal paths are informed by the generated HexMap that was built from prey locations. A second Movement event is used to create explored areas from which the predators can consume prey resources.

Next, an Interaction event performs the actual consumption of prey by predators. A predator encounters prey anytime its explored area overlaps a prey allocated area (a range, or floater allocation). But a predator's ability to capture prey varies based on its Capture Efficiency trait. Predators have five capture efficiency trait values, and since capture efficiency is a genetic trait, it is subject to selection pressure and mutation. The selection pressure arises in the simulation because both reproduction and survival are in part stratified by the Predation Level trait, which tracks the number of prey items consumed. Thus, the more prey a predator captures, the higher its survival and reproduction will be (on average). When a predator encounters a prey item and they interact, the prey dies and the predator's Prey Consumed accumulator is incremented by one. The Interaction event controlling prey consumption is also stratified by the predator's Hunger Level trait. This keeps predators from consuming more prey items than they need.

Next, the male and female predators are paired for the purposes of reproduction. In this case, pairing implies that the individuals have non-zero Mate accumulators. The assignment of mate accumulators is performed by the second Interaction event. Unpaired males and females will interact, and the interaction outcome sets the Mate accumulator to the partner's ID. When the Mate accumulator is set to a value exceeding zero, the individual becomes paired, and thus unavailable to pair again that time step.

An Accumulate event is then used to set the mean reproductive output for the predators. This is done in three steps. First, the Reproduction Mean accumulator is cleared in the global tab. This sets the reproduction rate to zero for all predators. Second, subadult and adult predators having captured a moderate number of prey items are assigned a reproduction mean of 1.0. Finally, subadults and adults having captured a large number of prey items are assigned a reproduction mean of 2.0. Juveniles, and individuals who captured only low numbers of prey items, will not reproduce in that time step.

Reproduction is then carried out by a Propagation event which is set up to operate on just the female predators. Since the predators are all floaters, a Reproduction event will not work for them (Reproduction events only operate on group members). The Propagation event is passed the Reproduction Mean accumulator, and for simplicity assigned a standard deviation of zero (via another accumulator). Also, the Propagation event is passed the Mate ID accumulator, which ensures that only paired females will reproduce, and that the offspring's genotype is assembled from both parent genetic information.

The Mutation event, which comes next, is set up to randomly vary adjacent alleles. That is, allele 0 can mutate to 1, and visa-versa. And allele 1 can mutate to 2, and visa-vera. But mutation cannot change allele 0 to 2 or 2 to 0. The mutation rates are all the same, and are large enough that mutation can be readily observed.

Next comes a Survival event. Survival varies simultaneously by stage class and predation rate. Finally, a pair of Generated Hexmap events are used to create a time series of predator density maps that can be used in the Simulation Viewer to visualize the predator-prey interactions.

The Census

At the end of the Event Sequence, an Event Group holds a collection of five Census events that package up an array of useful information about the simulation dynamics.

Simulation Dynamics

When the Interaction simulation is run, the prey population exhibits large temporal oscillations. The predator exhibits smaller amplitude cycles, which are tightly coupled to those of the prey. The image at left illustrates these oscillations.

A key attributes of the Predator-Prey scenario is its use of a genetic trait and a Mutation event. This scenario illustrates the effect of selective pressure on an adaptive trait. The scenario starts out with every member being assigned two copies of allele 0, which guarantees that they will be placed into the Low Efficiency trait class. And children of these individuals will remain in this class with certainty.

But Mutations events can alter an individual's genetic information, replacing allele 0 with allele 1, allele 1 with allele 0, allele 1 with allele 2, or allele 2 with allele 1. This provides the mechanism through which individuals can eventually shift from the Low Efficiency class into one of the other four companion classes. Individuals in higher-efficiency classes are then more likely to secure prey items, and as a result will live longer and reproduce at a higher rate than lower-efficiency individuals.

The figure above titled Genetic Adaptation shows the results from a single replicate of the Interaction scenario. The percent of the population in each of the five capture efficiency classes is shown on the vertical axis. Initially, the entire population is in the Low Efficiency class. But mutation quickly begin to shift individuals into the other classes. By the end of the simulation, the majority of the population is in the High Efficiency class.