blob: 8a0d636e244759f08e3b8442a72f36995d2eaaf0 [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<metaabm:SContext xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:act="http://metaabm.org/act" xmlns:function="http://metaabm.org/function" xmlns:metaabm="http://metaabm.org/metaabm.org/structure" label="G A S_ Base" ID="GAS_Base" pluralLabel="G A S_ Bases" description="Incomplete model!">
<attributes label="Sugar Moundness" ID="sugarMoundness" pluralLabel="Sugar Moundnesss" description="The topology parameter for sugar peaks" sType="REAL"/>
<attributes label="Min Vision" ID="minVision" pluralLabel="Min Visions" description="The minimum vision that an agent may be given on initialization.Model parameter." sType="INTEGER" defaultValue="1"/>
<attributes label="Max Vision" ID="maxVision" pluralLabel="Max Visions" description="The maximum vision that an agent may be given on initialization.Model parameter." sType="INTEGER" defaultValue="6"/>
<attributes label="Min Sugar Metabolism" ID="minSugarMetabolism" pluralLabel="Min Sugar Metabolisms" description="The minimum sugar metabolism that an agent may be given on initialization.Model parameter." sType="INTEGER" defaultValue="1"/>
<attributes label="Max Sugar Metabolism" ID="maxSugarMetabolism" pluralLabel="Max Sugar Metabolisms" description="The maximum sugar metabolism that an agent may be given on initialization.Model parameter." sType="INTEGER" defaultValue="4"/>
<attributes label="Min Death Age" ID="minDeathAge" pluralLabel="Min Death Ages" description="The minimum age that an agent may be given on initialization.Model parameter." sType="INTEGER"/>
<attributes label="Min Initial Sugar" ID="minInitialSugar" pluralLabel="Min Initial Sugars" description="The minimum sugar that an agent may be given on initialization.Model parameter." sType="INTEGER"/>
<attributes label="Max Initial Sugar" ID="maxInitialSugar" pluralLabel="Max Initial Sugars" description="The maximum sugar that an agent may be given on initialization.Model parameter." sType="INTEGER"/>
<attributes label="G A S_ Base Agent Count" ID="gAS_BaseAgentCount" pluralLabel="G A S_ Base Agent Counts" description="The number of g a s_ base agents to create." sType="INTEGER" defaultValue="60"/>
<attributes label="Max Death Age" ID="maxDeathAge" pluralLabel="Max Death Ages" description="The minimum age that an agent may be given on initialization.Model parameter." sType="INTEGER"/>
<rootActivity xsi:type="act:AGroup" label="Root Act Group" ID="rootActGroup" pluralLabel="Root Act Groups">
<members xsi:type="act:ABuild" label="Build G A S_ Base" ID="buildGAS_Base" targets="//@rootActivity/@members[ID='createSugarAgents'] //@rootActivity/@members[ID='buildSugarspace'] //@rootActivity/@members[ID='createSugarCells']" selected="//@rootActivity/@members[ID='buildGAS_Base']" agent="/" pluralLabel="Build G A S_ Bases"/>
<members xsi:type="act:ACreateAgents" label="Create Sugar Agents" ID="createSugarAgents" sources="//@rootActivity/@members[ID='buildGAS_Base']" selected="//@rootActivity/@members[ID='buildGAS_Base']" agent="//@agents[ID='sugarAgent']" agentCount="//@attributes[ID='gAS_BaseAgentCount']"/>
<members xsi:type="act:ABuildGrid" label="Build Sugarspace" ID="buildSugarspace" sources="//@rootActivity/@members[ID='buildGAS_Base']" selected="//@rootActivity/@members[ID='buildGAS_Base']" pluralLabel="Build Sugarspaces" agents="//@agents[ID='sugarAgent']" projection="//@projections[ID='sugarspace']" fillAgent="//@agents[ID='sugarCell']"/>
<members xsi:type="act:ACreateAgents" label="Create Sugar Cells" ID="createSugarCells" sources="//@rootActivity/@members[ID='buildGAS_Base']" selected="//@rootActivity/@members[ID='buildGAS_Base']" agent="//@agents[ID='sugarCell']"/>
<members xsi:type="act:AInitialize" label="Initialize" ID="initialize" targets="//@rootActivity/@members[ID='sugarPeaks']" selected="//@rootActivity/@members[ID='initialize']" agent="/" pluralLabel="Initializes"/>
<members xsi:type="act:ASelect" label="Sugar Peaks" ID="sugarPeaks" sources="//@rootActivity/@members[ID='initialize']" selected="//@rootActivity/@members[ID='initialize']" agent="//@agents[ID='sugarCell']" for="ALL"/>
</rootActivity>
<implementation package="edu.brook.sugarscape" className="GAS_Base" basePath=""/>
<agents label="Sugar Agent" ID="sugarAgent" pluralLabel="Sugar Agents" description=" A basic sugarscape citizen. Provides basic funtionality for sugarscape agents as well as all desired functionality that could be included in base class without compromising good design or supporting unnecessary member variables. Despite the relativly large size of this class it is actually quite simple; much of the code is simply getters and setters for various initialization paramaters. author Miles T. Parker version 1.0">
<attributes label="Sugar Stock" ID="sugarStock" pluralLabel="Sugar Stocks" sType="REAL"/>
<attributes label="Vision" ID="vision" pluralLabel="Visions" sType="INTEGER"/>
<attributes label="Sugar Metabolism" ID="sugarMetabolism" pluralLabel="Sugar Metabolisms" sType="INTEGER"/>
<attributes label="Age" ID="age" pluralLabel="Ages" sType="INTEGER"/>
<attributes label="Death Age" ID="deathAge" pluralLabel="Death Ages" sType="INTEGER"/>
<rootActivity xsi:type="act:AGroup" label="Root Act Group" ID="rootActGroup" pluralLabel="Root Act Groups">
<members xsi:type="act:ARule" label="Harvest" ID="harvest" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCell']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='harvest']" agent="//@agents[ID='sugarAgent']" pluralLabel="Harvests"/>
<members xsi:type="act:ARule" label="Movement" ID="movement" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarAgent']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='movement']" agent="//@agents[ID='sugarAgent']" pluralLabel="Movements"/>
<members xsi:type="act:ARule" label="Metabolism" ID="metabolism" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolismIncrementAge'] //@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolismSugarStockSubtractSugarMetabolism']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" agent="//@agents[ID='sugarAgent']" pluralLabel="Metabolisms"/>
<members xsi:type="act:AInitialize" label="Initialize" ID="initialize" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomDeathAge'] //@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomVision'] //@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomMetabolism'] //@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomSugar'] //@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomCell']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" agent="//@agents[ID='sugarAgent']" space="//@projections[ID='sugarspace']" pluralLabel="Initializes"/>
<members xsi:type="act:ASet" label="Set Death Age To Random Death Age" ID="setDeathAgeToRandomDeathAge" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomDeathAge']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomAge']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='deathAge']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomDeathAge']"/>
<members xsi:type="act:AEvaluate" label="Random Death Age" ID="randomDeathAge" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setDeathAgeToRandomDeathAge']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='minDeathAge']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='maxDeathAge']"/>
<function xsi:type="function:FGenericFunction" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='random']/@functions[ID='randomInRange']"/>
</members>
<members xsi:type="act:AEvaluate" label="Random Age" ID="randomAge" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setDeathAgeToRandomDeathAge']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setAgeToRandomAge']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']">
<value xsi:type="metaabm:SAttribute" href="http://metaabm.org/core_library.metaabm#//@attributes[ID='zero']"/>
</inputs>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@agents[ID='sugarAgent']/@attributes[ID='deathAge']"/>
<function xsi:type="function:FGenericFunction" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='random']/@functions[ID='randomInRange']"/>
</members>
<members xsi:type="act:ASet" label="Set Age To Random Age" ID="setAgeToRandomAge" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomAge']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='age']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomAge']"/>
<members xsi:type="act:AEvaluate" label="Random Vision" ID="randomVision" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setVisionToRandomVision']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='minVision']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='maxVision']"/>
<function xsi:type="function:FGenericFunction" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='random']/@functions[ID='randomInRange']"/>
</members>
<members xsi:type="act:ASet" label="Set Vision To Random Vision" ID="setVisionToRandomVision" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomVision']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='vision']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomVision']"/>
<members xsi:type="act:AEvaluate" label="Random Metabolism" ID="randomMetabolism" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setSugarMetabolismToRandomMetabolism']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='minSugarMetabolism']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='maxSugarMetabolism']"/>
<function xsi:type="function:FGenericFunction" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='random']/@functions[ID='randomInRange']"/>
</members>
<members xsi:type="act:ASet" label="Set Sugar Metabolism To Random Metabolism" ID="setSugarMetabolismToRandomMetabolism" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomMetabolism']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='sugarMetabolism']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomMetabolism']"/>
<members xsi:type="act:AEvaluate" label="Random Sugar" ID="randomSugar" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setSugarStockToRandomSugar']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='minInitialSugar']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" value="//@attributes[ID='maxInitialSugar']"/>
<function xsi:type="function:FGenericFunction" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='random']/@functions[ID='randomInRange']"/>
</members>
<members xsi:type="act:ASet" label="Set Sugar Stock To Random Sugar" ID="setSugarStockToRandomSugar" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomSugar']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='sugarStock']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomSugar']"/>
<members xsi:type="act:ARule" label="Death Starvation" ID="deathStarvation" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarStockZero']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']" agent="//@agents[ID='sugarAgent']" space="//@projections[ID='sugarspace']" pluralLabel="Death Starvations"/>
<members xsi:type="act:ARule" label="Death Old Age" ID="deathOldAge" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAgeAgeGreaterorEqualDeathAgeQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']" agent="//@agents[ID='sugarAgent']" space="//@projections[ID='sugarspace']" pluralLabel="Death Old Ages"/>
<members xsi:type="act:AQuery" label="Sugar Stock Zero" ID="sugarStockZero" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='die']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']" value="//@agents[ID='sugarAgent']/@attributes[ID='sugarStock']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']">
<value xsi:type="metaabm:SAttribute" href="http://metaabm.org/core_library.metaabm#//@attributes[ID='zero']"/>
</inputs>
<function xsi:type="function:FLogicalOperator" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='operators']/@subs[ID='logicalOperators']/@functions[ID='lesserorEqual']"/>
</members>
<members xsi:type="act:ADie" label="Die" ID="die" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarStockZero']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']" destination="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathStarvation']"/>
<members xsi:type="act:AQuery" label="Death Old Age: Age Greater or Equal Death Age Query" ID="deathOldAgeAgeGreaterorEqualDeathAgeQuery" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='dieCopy']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']" value="//@agents[ID='sugarAgent']/@attributes[ID='age']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']" value="//@agents[ID='sugarAgent']/@attributes[ID='deathAge']"/>
<function xsi:type="function:FLogicalOperator" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='operators']/@subs[ID='logicalOperators']/@functions[ID='greaterorEqual']"/>
</members>
<members xsi:type="act:ASelect" label="Sugar Cell" ID="sugarCell" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='harvest']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCellNeighborQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='harvest']" agent="//@agents[ID='sugarCell']" space="//@projections[ID='sugarspace']"/>
<members xsi:type="act:AEvaluate" label="Sugar Cell: Sugar Stock Add Sugar Amount" ID="sugarCellSugarStockAddSugarAmount" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCellNeighborQuery']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setSugarStockToSugarCellSugarStockAddSugarAmount'] //@agents[ID='sugarAgent']/@rootActivity/@members[ID='setSugarAmountToZero']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCell']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='harvest']" value="//@agents[ID='sugarAgent']/@attributes[ID='sugarStock']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCell']" value="//@agents[ID='sugarCell']/@attributes[ID='sugarAmount']"/>
<function xsi:type="function:FOperator" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='operators']/@subs[ID='numericOperators']/@functions[ID='add']"/>
</members>
<members xsi:type="act:ASet" label="Set Sugar Stock To Sugar Cell: Sugar Stock Add Sugar Amount" ID="setSugarStockToSugarCellSugarStockAddSugarAmount" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCellSugarStockAddSugarAmount']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='harvest']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='sugarStock']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCellSugarStockAddSugarAmount']"/>
<members xsi:type="act:ASet" label="Set Sugar Amount To Zero" ID="setSugarAmountToZero" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCellSugarStockAddSugarAmount']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCell']" attribute="//@agents[ID='sugarCell']/@attributes[ID='sugarAmount']">
<parameter xsi:type="metaabm:SAttribute" href="http://metaabm.org/core_library.metaabm#//@attributes[ID='zero']"/>
</members>
<members xsi:type="act:AEvaluate" label="Metabolism: Increment Age" ID="metabolismIncrementAge" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setAgeToMetabolismIncrementAge']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" value="//@agents[ID='sugarAgent']/@attributes[ID='age']"/>
<function xsi:type="function:FOperator" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='operators']/@subs[ID='numericOperators']/@functions[ID='increment']"/>
</members>
<members xsi:type="act:ASet" label="Set Age To Metabolism: Increment Age" ID="setAgeToMetabolismIncrementAge" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolismIncrementAge']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='age']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolismIncrementAge']"/>
<members xsi:type="act:AEvaluate" label="Metabolism: Sugar Stock Subtract Sugar Metabolism" ID="metabolismSugarStockSubtractSugarMetabolism" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='setSugarStockToMetabolismSugarStockSubtractSugarMetabolism']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']">
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" value="//@agents[ID='sugarAgent']/@attributes[ID='sugarStock']"/>
<inputs selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" value="//@agents[ID='sugarAgent']/@attributes[ID='sugarMetabolism']"/>
<function xsi:type="function:FOperator" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='operators']/@subs[ID='numericOperators']/@functions[ID='sub']"/>
</members>
<members xsi:type="act:ASet" label="Set Sugar Stock To Metabolism: Sugar Stock Subtract Sugar Metabolism" ID="setSugarStockToMetabolismSugarStockSubtractSugarMetabolism" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolismSugarStockSubtractSugarMetabolism']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolism']" attribute="//@agents[ID='sugarAgent']/@attributes[ID='sugarStock']" parameter="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='metabolismSugarStockSubtractSugarMetabolism']"/>
<members xsi:type="act:ASelect" label="Random Cell" ID="randomCell" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomCellAvailableQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" agent="//@agents[ID='sugarCell']" space="//@projections[ID='sugarspace']"/>
<members xsi:type="act:AQuery" label="Random Cell: Available() Query" ID="randomCellAvailableQuery" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomCell']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='moveSugarCell']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomCell']">
<function xsi:type="function:FGenericLogical" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='spatial']/@functions[ID='available']"/>
</members>
<members xsi:type="act:AMove" label="Move Sugar Cell" ID="moveSugarCell" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomCellAvailableQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='initialize']" destination="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='randomCell']"/>
<members xsi:type="act:ASelect" label="Sugar Agent" ID="sugarAgent" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='movement']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarAgentAvailableQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='movement']" agent="//@agents[ID='sugarCell']" space="//@projections[ID='sugarspace']"/>
<members xsi:type="act:AQuery" label="Sugar Agent: Available() Query" ID="sugarAgentAvailableQuery" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarAgent']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='movetoSugarCellinSugarspace']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarAgent']">
<function xsi:type="function:FGenericLogical" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='spatial']/@functions[ID='available']"/>
</members>
<members xsi:type="act:AMove" label="Move to Sugar Cell in Sugarspace" ID="movetoSugarCellinSugarspace" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarAgentAvailableQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='movement']" destination="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarAgent']"/>
<members xsi:type="act:ADie" label="Die Copy" ID="dieCopy" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAgeAgeGreaterorEqualDeathAgeQuery']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']" destination="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='deathOldAge']"/>
<members xsi:type="act:AQuery" label="Sugar Cell: Neighbor() Query" ID="sugarCellNeighborQuery" sources="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCell']" targets="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCellSugarStockAddSugarAmount']" selected="//@agents[ID='sugarAgent']/@rootActivity/@members[ID='sugarCell']">
<function xsi:type="function:FGenericLogical" href="http://metaabm.org/core_library.metaabm#//@library[ID='coreFunctions']/@subs[ID='spatial']/@functions[ID='neighbor']"/>
</members>
</rootActivity>
<implementation className="SugarAgent"/>
</agents>
<agents label="Sugar Cell" ID="sugarCell" pluralLabel="Sugar Cells" description=" history 19990624 AAL changed variables from private to protected so SpiceCell could inherit seperated peak creation from initialize() history 19990629 AAL removed a variety of &quot;sugar&quot;related methods and attributes, and put them in new class CommoditySource">
<attributes label="Perceived Value" ID="perceivedValue" pluralLabel="Perceived Values" sType="REAL"/>
<attributes label="Sugar Amount" ID="sugarAmount" pluralLabel="Sugar Amounts" sType="REAL"/>
<rootActivity xsi:type="act:AGroup" label="Root Act Group" ID="rootActGroup" pluralLabel="Root Act Groups">
<members xsi:type="act:ARule" label="Sugar Grow Back1" ID="sugarGrowBack1" selected="//@agents[ID='sugarCell']/@rootActivity/@members[ID='sugarGrowBack1']" agent="//@agents[ID='sugarCell']" pluralLabel="Sugar Grow Back1s"/>
<members xsi:type="act:ARule" label="Sugar Grow Back Epsilon" ID="sugarGrowBackEpsilon" selected="//@agents[ID='sugarCell']/@rootActivity/@members[ID='sugarGrowBackEpsilon']" agent="//@agents[ID='sugarCell']" pluralLabel="Sugar Grow Back Epsilons"/>
<members xsi:type="act:AInitialize" label="Initialize" ID="initialize" selected="//@agents[ID='sugarCell']/@rootActivity/@members[ID='initialize']" agent="//@agents[ID='sugarCell']" space="//@projections[ID='sugarspace']" pluralLabel="Initializes"/>
</rootActivity>
<implementation className="SugarCell"/>
</agents>
<projections xsi:type="metaabm:SGrid" label="Sugarspace" ID="sugarspace" pluralLabel="Sugarspaces" dimensionality="2">
<attributes xsi:type="metaabm:SAttributeArray" label="Dimensions" ID="dimensions" pluralLabel="Dimensionss" description="The size of each dimension." sType="INTEGER" size="2"/>
<attributes label="Width" ID="width" pluralLabel="Widths" description="The horizontal extent of the space." sType="INTEGER" defaultValue="50"/>
<attributes label="Height" ID="height" pluralLabel="Heights" description="The vertical extent of the space." sType="INTEGER" defaultValue="50"/>
</projections>
</metaabm:SContext>