V0 simpleEdit

Download Model
Download the .scn, .sel and .lse files by clicking on the following link:

Model Code Exploration
In the following sections we will examine all of the model files for this model. Note that instead of downloading the zip file above, you could just copy the text in the boxes below into a text editor and save it with the appropriate name (Section title). Opening the resulting .scn file in the SELES simulator would run this model.

BaseScenario.scn
SELES Scenario $gisData$ = ..\gisData\cell Ecoregion = $gisData$\ecoregion Elevation = $gisData$\elevation initialAge = $gisData$\StandAgeEst Spp = $gisData$\DomSpecies Model Dimensions: Ecoregion Model.sel SimPriority Low Priority // Set low priority for simulation engine // Set up display Minimize Static Minimize Initial State Tile // Move to output folder cwd output //SimStart 300 1

Model.sel
Seles Model Time Units: Year Century 100 260 Landscape Events: // Disturbance event Fire.lse DEBUG // Succession events Succession.lse DEBUG Global Constants: ///////////////////////////////////////////////////////////////  // General constants and parameters CellWidth = CELL WIDTH(Ecoregion) HaPerCell = (CellWidth^2) / 10000 MaxStandAge = MAX(initialAge) MaxTimeSinceDisturbance = 200 newConst = 100 // Need to link spatial constants with an input raster view Spatial Constants: StudyArea = Ecoregion Spp Elevation // Need to link spatial variables with an output raster view, and // specify initial conditions (raster, 0, or constant) and output raster bounds Spatial Variables: ///////////////////////////////////////////////////////////////  // Dynamic stand information StandAge[MaxStandAge] <= initialAge ///////////////////////////////////////////////////////////////  // Time since disturbance information Burnt[MaxTimeSinceDisturbance] TimeSinceDisturbance[MaxTimeSinceDisturbance] Global Variables: ///////////////////////////////////////////////////////////////  // Tracking ForestSize = 0 AreaBurned = 0 SumAgeBurned = 0 Output Frequency: 1

Fire.lse
// Empirical fire model for the Labrador District 19a "study copy" LSEVENT: Fire DEFINITIONS GLOBAL CONSTANT: HaPerCell, MaxTimeSinceDisturbance LAYER: StudyArea, StandAge, Spp, Elevation LAYER: Burnt, TimeSinceDisturbance  // Show areas that were recently burned GLOBAL VARIABLE: ForestSize, AreaBurned, SumAgeBurned, newConst CLUSTER VARIABLE: FireExtent CLUSTER VARIABLE: StartLocation CELL VARIABLE: distInc, d ENDDEF /* // Run after succession RETURNTIME RETURNTIME = IF Time EQ 0 THEN 0.5 ELSE 1 // Update time since disturbance information // Need to do this here, since Burnt may include non-forested cells OVER REGION WHOLE MAP DECISION Burnt > 0 Burnt = MAX(0,Burnt - 1) TimeSinceDisturbance = MIN(MaxTimeSinceDisturbance, TimeSinceDisturbance + 1) ENDFN AreaBurned = 0 SumAgeBurned = 0 ENDRT // Only allow ignitions in forested cells EVENTLOCATION ForestSize = 0 STATIC REGION WHOLE MAP DECISION (Spp > 0) ForestSize = ForestSize + HaPerCell ENDEL /* // Draw the number of openings from an exponential distribution NUMCLUSTERS meanClusters = 1 nClusters = FLOOR(NEGEXP(meanClusters)) NUMCLUSTERS = nClusters ENDNC PROBINIT PROBINIT = 1 //Elevation^2 // For each opening, select an opening size ReturnInterval = 50 meanExtent = (ForestSize/ReturnInterval) FireExtent = ROUND(NEGEXP(meanExtent)) StartLocation = Location distInc = 0 d = 0 ENDPI TRANSITIONS // Continue if there is still extent to be burned // AND if the stand didn't burn during this event already TRANSITIONS = (FireExtent > 0) AND (Burnt < MaxTimeSinceDisturbance) // TRANSITIONS = (FireExtent > 0) AND (TimeSinceDisturbance > 0) // IF Spp > 0 // Decrement the number of cells remaining to burn for this opening // Only do this for forested cells. NonForested cells will just pass on the fire FireExtent = FireExtent - HaPerCell // ENDFN // Set the stand age SumAgeBurned = SumAgeBurned + StandAge StandAge = 0 Burnt = MaxTimeSinceDisturbance TimeSinceDisturbance = 0 AreaBurned = AreaBurned + HaPerCell ENDTR // Spread timestep: time is irrelevant for this empirical model. //SPREADTIME = 0.00001 SPREADTIME = distInc/365.25 // Potentially spread to the four cardinal neighbours SPREADLOCATION REGION CENTRED(1,1.5) DECISION (StudyArea > 0) AND (Burnt < MaxTimeSinceDisturbance) //    DECISION (StudyArea > 0) AND (Spp > 0) AND (Burnt < MaxTimeSinceDisturbance) ENDSL SPREADPROB SPREADPROB = 1 d = ROUND(DISTANCE(StartLocation, Location)) distInc = MAX(0,d - SOURCE d) ENDSP */

Succession.lse
// Landscape event definition for succession in the Labrador District 19a "study copy" LSEVENT: SUCCESSION DEFINITIONS GLOBAL CONSTANT: MaxStandAge /****************************************/  LAYER: StudyArea, StandAge LAYER: Spp ENDDEF // Aging at start of year (before any other models), but not in first period RETURNTIME = 1 // Only process forested cells EVENTLOCATION STATIC REGION WHOLE MAP DECISION (StudyArea > 0) AND (Spp > 0) ENDEL // In each forested cell TRANSITIONS TRANSITIONS = TRUE // Increment the stand age in years isOld = StandAge >= MaxStandAge StandAge = MIN(StandAge + 1, MaxStandAge) // if the stand is 160 ...1% chance of death r = UNIFORM(0,1) IF (isOld) AND (r < 0.01) StandAge = 0 ENDFN /*  StandAge = IF (StandAge >= MaxStandAge) AND (r < 0.1) THEN 0 ELSE MIN(StandAge + 1, MaxStandAge) */ /*  IF (StandAge EQ MaxStandAge) AND (UNIFORM(0,1) <= 0.01) // do this with a prob of 1% StandAge = 0 ENDFN */ ENDTR

Suggested Experiments
To explore this cellular automata model further, try the following: