Habitat Model

A simple model to demonstrate ??.

HabitatModel.scn
Example 1: Scenario Information $inputGisDir$ = "..\..\gisData" // path to GIS layers $outputDir$ = "..\..\outputFiles" // path to output directory // Static layers StudyArea = $inputGisDir$\cell\lrmp_bnd // LRMP boundary ProductiveForest = $inputGisDir$\cell\ProductiveForest Model Dimensions: StudyArea Habitat.sel cwd $outputDir$ SimStart 1 1 // 1 time step, 1 run // save results Save HabPatch .\cell\HabPatch GRASS COMPRESSED Save Habitat .\cell\Habitat GRASS COMPRESSED Scenario Information Model Dimensions: 100, 100 Model.sel //SimPriority Low Priority

Example 2: Scenario Information $inputGisDir$ = "..\..\gisData" // path to GIS layers $outputDir$ = "..\..\outputFiles" // path to output directory // Static layers StudyArea = $inputGisDir$\cell\lrmp_bnd // LRMP boundary ProductiveForest = $inputGisDir$\cell\ProductiveForest Model Dimensions: StudyArea Habitat.sel cwd $outputDir$ SimStart 1 1 // 1 time step, 1 run // save results Save HabPatch .\cell\HabPatch GRASS COMPRESSED Save Habitat .\cell\Habitat GRASS COMPRESSED

Example 3: Scenario Information $inputGisDir$ = "..\..\gisData" // path to GIS layers $outputDir$ = "..\..\outputFiles" // path to output directory // Static layers StudyArea = $inputGisDir$\cell\lrmp_bnd // LRMP boundary BEC = $inputGisDir$\cell\bec // biogeoclimatic zone Elevation = $inputGisDir$\cell\elevation // DEM ProductiveForest = $inputGisDir$\cell\ProductiveForest Dist2Roads = $inputGisDir$\cell\Dist2ActiveRoad // distance to active logging roads // Load Initial Dynamic Layer StandAge = $inputGisDir$\cell\age_prj // projected age. Model Dimensions: StudyArea Habitat.sel minStandAge = 80 maxStandAge = 120 maxElevation = 1000 cwd $outputDir$ cwd .\cell cwd ..\cellhd cwd .. SimStart 1 1 // 1 time step, 1 run // save results Save HabPatch .\cell\HabPatch GRASS COMPRESSED Save Habitat .\cell\Habitat GRASS COMPRESSED

Habitat.sel
Example 1: Seles Model Time Units: step decistep 10 1 Landscape Events: Habitat.lse DEBUG Variable-Input View Maps: StudyArea ProductiveForest Variable-Output View Maps: Habitat HabPatch Output Model Bounds: HabPatch: 1 Habitat: 2 Legends: BEClegend = "$inputGisDir$\cats\bec" Global Constants: HaPerCell = 1 // (CellWidth * CellWidth) / 10000 TotalCells = NUMROWS * NUMCOLS inBEC = .\inputFiles\inBEC.txt numBEC = ROWS(inBEC) Global variables: // General BaseTimestep = 1 Output Frequency: 1

Example 2: Seles Model Time Units: step decistep 10 1 Landscape Events: Habitat.lse DEBUG Variable-Input View Maps: StudyArea ProductiveForest Variable-Output View Maps: Habitat HabPatch Output Model Bounds: HabPatch: 1 Habitat: 2 Legends: //BEClegend = "$inputGisDir$\cats\bec" BEClegend = .\inputFiles\BEClegend.txt Global Constants: HaPerCell = 1 // (CellWidth * CellWidth) / 10000 TotalCells = NUMROWS * NUMCOLS Global variables: // General BaseTimestep = 1 Output Frequency: 1

Example 3: Seles Model Time Units: step decistep 10 1 Landscape Events: Habitat.lse DEBUG Variable-Input View Maps: StudyArea StandAge Elevation BEC ProductiveForest Variable-Output View Maps: Habitat HabPatch Output Model Bounds: HabPatch: 1 Habitat: 2 Legends: BEClegend = "$inputGisDir$\cats\bec" Global Constants: HaPerCell = 1 // (CellWidth * CellWidth) / 10000 NumSubStrata = 1 TotalCells = NUMROWS * NUMCOLS inBEC = .\inputFiles\inBEC.txt NumBECZones = MAX(BEC) + 1 Global variables: // General RecordResults = true BaseTimestep = 1 minStandAge = 80 maxStandAge = 450 maxElevation = 800 // Output habArea[NumBECZones] = 0 Output Frequency: 1

Habitat.lse
Example 1: LSEVENT: Habitat.lse DEFINITIONS LAYER: StudyArea LAYER: ProductiveForest LAYER: Habitat, HabPatch // General GLOBAL CONSTANT: HaPerCell, TotalCells GLOBAL VARIABLE: BaseTimestep ENDDEF INITIALSTATE INITIALSTATE = 1 ENDIS RETURNTIME RETURNTIME = IF (Time EQ 0) THEN 0.1 ELSE BaseTimestep // Reset dynamic layers HabPatch = 0 Habitat = 0 ENDRT EVENTLOCATION REGION WHOLE MAP DECISION (StudyArea > 0) ENDEL TRANSITIONS TRANSITIONS = TRUE // Compute habitat (1: NonHabitat, 2: Habitat) Habitat = IF ProductiveForest > 0 THEN 2 ELSE 1 HabPatch = Habitat EQ 2 ENDTR

Example 2: LSEVENT: Habitat.lse DEFINITIONS LAYER: StudyArea LAYER: ProductiveForest LAYER: Habitat, HabPatch // General GLOBAL CONSTANT: HaPerCell, TotalCells GLOBAL VARIABLE: BaseTimestep ENDDEF INITIALSTATE INITIALSTATE = 1 ENDIS RETURNTIME RETURNTIME = IF (Time EQ 0) THEN 0.1 ELSE BaseTimestep // Reset dynamic layers HabPatch = 0 Habitat = 0 ENDRT EVENTLOCATION REGION WHOLE MAP DECISION (StudyArea > 0) ENDEL TRANSITIONS TRANSITIONS = TRUE // Compute habitat (1: NonHabitat, 2: Habitat) Habitat = IF ProductiveForest > 0 THEN 2 ELSE 1 HabPatch = Habitat EQ 2 ENDTR NUMRECIPIENTS = 0 // do not allow spreading to occur.

Example 3: LSEVENT: Habitat DEFINITIONS LAYER: StudyArea, StandAge, BEC, Elevation, ProductiveForest LAYER: Habitat, HabPatch // General GLOBAL CONSTANT: HaPerCell, TotalCells GLOBAL VARIABLE: BaseTimestep // Habitat Parameters GLOBAL VARIABLE: minStandAge, maxStandAge GLOBAL VARIABLE: maxElevation GLOBAL CONSTANT: inBEC[], NumBECZones // Reporting Variables GLOBAL VARIABLE: habArea[] // Output file MIN OUTPUT VARIABLE: HabitatAreaOutput = HabitatAreaOutput.txt ENDDEF INITIALSTATE INITIALSTATE = 1 ENDIS RETURNTIME IF (Time > 0) OVER INDEX SEQUENCE(0, NumBECZones-1) bec = Index OUTPUT RECORD(HabitatAreaOutput) BEC: $bec{BEC} HabArea: habArea[bec] ENDFN ENDFN ENDFN RETURNTIME = IF (Time EQ 0) THEN 0.1 ELSE BaseTimestep // Reset dynamic layers HabPatch = 0 Habitat = 0 ENDRT EVENTLOCATION REGION WHOLE MAP DECISION (StudyArea > 0) ENDEL TRANSITIONS TRANSITIONS = TRUE // Compute habitat (1: NonHabitat, 2: Habitat) Habitat = IF AND // Habitat ProductiveForest > 0 // forested inBEC[BEC]                // BEC variant supports type A                      Elevation <= maxElevation // Elevation limit not exceeded minStandAge <= StandAge <= maxStandAge  // older than min Stand Age ENDFN THEN 2 ELSE IF ProductiveForest > 0                // forested THEN 1 ELSE 0 // non-forested HabPatch = IF Habitat EQ 2 THEN 1 ELSE 0 habArea[BEC] = habArea[BEC] + (HabPatch * HaPerCell) ENDTR