edu.bonn.xulu.plugin.model.sleuth
Class UrbanGrowthModelSelfModifying

java.lang.Object
  extended by AbstractNamedObject
      extended by edu.bonn.xulu.model.AbstractXuluModel
          extended by edu.bonn.xulu.model.AbstractStepModel
              extended by edu.bonn.xulu.plugin.model.sleuth.UrbanGrowthModelSelfModifying
All Implemented Interfaces:
StepModel, XuluModel

public class UrbanGrowthModelSelfModifying
extends AbstractStepModel

This very simple model looks at every grid cell and takes the average over a the surrounding cells in a specified neighborhood. It was implemented as demonstration of the Xulu / V functionality. You can see the parallel version of this model in AverageNeighborhoodParallelDemoModel and also a tuned version using late-merging support in AVNTuned.

  1. Input Grid (inputGrid): A grid with input values
  2. Output Grid (outputGrid): A grid where the output is stored
  3. Number of steps (steps): the number of steps to compute.

Version:
1.0
Author:
Dominik Appl
See Also:
AverageNeighborhoodContentManager

Field Summary
protected  double boom
           
protected  double breed
           
protected  double bust
           
protected  UrbanGrowthModelSelfModifyingContentManager contManager
           
protected  double criticalHigh
           
protected  double criticalLow
           
protected  double criticalSlope
           
protected  double disp
           
protected  double roadGravity
           
protected  double roadGravSens
           
protected  double slope
           
protected  HashMap<Number,Number> slopeLUT
           
protected  double slopeSens
           
protected  double spread
           
 
Fields inherited from class edu.bonn.xulu.model.AbstractStepModel
stepCount
 
Fields inherited from class edu.bonn.xulu.model.AbstractXuluModel
disposed, events, initialised, listeners, modelResourceProvider, running, statusOut, stopped
 
Constructor Summary
UrbanGrowthModelSelfModifying()
          Erzeugt eine neue Instanz des Modells.
 
Method Summary
protected static boolean checkNoData(int x, int y, WritableGrid grid)
           
 void performModelDispose()
          like in every model: frees the resources
 void performModelInit()
          Initializes the model.
 void performModelStep(int stepNo)
          This very simple model looks at every grid cell and takes the average over a the surrounding cells in a specified neighborhood.
 
Methods inherited from class edu.bonn.xulu.model.AbstractStepModel
fireModelStepFinished, fireModelStepStarted, getStepCount, performModelStart
 
Methods inherited from class edu.bonn.xulu.model.AbstractXuluModel
addModelListener, checkBreakingCommands, determineCaption, disposeModel, fireModelDisposed, fireModelEvent, fireModelInitialised, fireModelStarted, fireModelStopped, getContentManager, getEvents, getModelSpecificGUI, getResourceProvider, getStatusOut, initModel, isDisposed, isInitialised, isRunning, isStopped, performError, releaseAccess, removeModelListener, resetCaptions, setStatusOut, startModelling, stopModelling
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface edu.bonn.xulu.model.XuluModel
addModelListener, disposeModel, getContentManager, getEvents, getModelSpecificGUI, getResourceProvider, getStatusOut, initModel, isDisposed, isInitialised, isRunning, isStopped, performError, removeModelListener, setStatusOut, startModelling, stopModelling
 

Field Detail

contManager

protected UrbanGrowthModelSelfModifyingContentManager contManager

spread

protected double spread

disp

protected double disp

breed

protected double breed

roadGravity

protected double roadGravity

slope

protected double slope

criticalSlope

protected double criticalSlope

roadGravSens

protected double roadGravSens

slopeSens

protected double slopeSens

criticalLow

protected double criticalLow

criticalHigh

protected double criticalHigh

boom

protected double boom

bust

protected double bust

slopeLUT

protected HashMap<Number,Number> slopeLUT
Constructor Detail

UrbanGrowthModelSelfModifying

public UrbanGrowthModelSelfModifying()
Erzeugt eine neue Instanz des Modells.

Method Detail

performModelInit

public void performModelInit()
Initializes the model. Like in the init method of every XuluModel the resources are initalized.

Specified by:
performModelInit in class AbstractXuluModel

performModelDispose

public void performModelDispose()
like in every model: frees the resources

Specified by:
performModelDispose in class AbstractXuluModel

performModelStep

public void performModelStep(int stepNo)
This very simple model looks at every grid cell and takes the average over a the surrounding cells in a specified neighborhood.

Specified by:
performModelStep in interface StepModel
Specified by:
performModelStep in class AbstractStepModel
Parameters:
stepNo - zu modellierender Schritt (beginnend bei 1!)

checkNoData

protected static boolean checkNoData(int x,
                                     int y,
                                     WritableGrid grid)