<CompuCell3D>
    <!-- The Potts section defines paramters that are used in the Metropolis algorithm-->
    <!-- It also defines lattice parameters, flip neighbors and boundary conditions-->
   <Potts>
      <Dimensions x="101" y="101" z="1"/>
      <Anneal>0</Anneal>
      <Steps>1000</Steps>
      <Temperature>5</Temperature>
      <Flip2DimRatio>1.0</Flip2DimRatio>
      <Boundary_y>Periodic</Boundary_y>
      <Boundary_x>Periodic</Boundary_x>
      <FlipNeighborMaxDistance>1.75</FlipNeighborMaxDistance>
   </Potts>

   <!--In Every CompuCell simulation you need to list all the cell types that you will be using-->  
   <!--This is done in the CellType Plugin - as shown below-->  
   <Plugin Name="CellType">
      <CellType TypeName="Medium" TypeId="0"/>
      <CellType TypeName="Foam" TypeId="1"/>   
   </Plugin>
   
   <!--Contact Plugin calculates change in contact energy due to spin flip attempt -->  
   <!--You specify contact energies between cell types and how many levels of neighbors (Depth parameter) should be included in energy calculations  -->  
   <!--Depth tells CompuCell the maximum distance - measured in pixels - up to which it should search for neighbors to be included in contact energy calculations-->
   
   <Plugin Name="Contact">
      <Energy Type1="Foam" Type2="Foam">3</Energy>
      <Energy Type1="Medium" Type2="Medium">0</Energy>
      <Energy Type1="Medium" Type2="Foam">0</Energy>      
      <Depth>2.0</Depth>
   </Plugin>

   <!--Volume plugin puts constraint on cell volume. You also need to include it when you want CompuCell to update volume of cells-->
   <!--The stronget LambdaVolume therestrictive constraint -->
   <!--Below LambdaVolume=0 which means ther is no constraint. However we use this plugin to get up-to-date volume information for every cell-->
   <Plugin Name="Volume">
      <TargetVolume>25</TargetVolume>
      <LambdaVolume>0</LambdaVolume>
   </Plugin>
   
   <!-- Analogous to volume plugin-->
   <Plugin Name="Surface">
      <TargetSurface>17</TargetSurface>
      <LambdaSurface>0</LambdaSurface>
   </Plugin>
   
  <!--This steppable initializes cells on the lattice. It reads text file - here it is foaminit2D- and based on this runs initialization--> 
  <!-- As an initializer it is called only once per simulation -->
  <Steppable Type="PIFInitializer">
      <PIFName>foaminit2D.pif</PIFName>
 </Steppable>


 <!-- This steppable outputs current state  the simulation - here , for every cell we output cellId, volume, surface, number of neighbors-->
 <Steppable Type="FoamDataOutput" Frequency="10"> 
    <Output CellID="" Volume="" Surface="" NumberOfNeighbors=""/>
 </Steppable>  

</CompuCell3D>
