private void OnSimulationCommencing(object sender, EventArgs e) { Soil soil = Apsim.Find(this, typeof(Soil)) as Soil; if (soil == null) { throw new Exception("Cannot find soil"); } if (soil.Crop(Plant.Name) == null && soil.Weirdo == null) { throw new Exception("Cannot find a soil crop parameterisation for " + Plant.Name); } PlantZone = new ZoneState(Plant, this, soil, 0, initialDM.Value(), Plant.Population, maximumNConc.Value(), rootFrontVelocity, maximumRootDepth, remobilisationCost); Zones = new List <ZoneState>(); Allocated = new PMF.Biomass(); Senesced = new Biomass(); Detached = new Biomass(); Removed = new Biomass(); NDemand = new BiomassPoolType(); DMDemand = new BiomassPoolType(); NSupply = new BiomassSupplyType(); DMSupply = new BiomassSupplyType(); potentialDMAllocation = new BiomassPoolType(); }
protected void OnSimulationCommencing(object sender, EventArgs e) { Allocated = new PMF.Biomass(); Senesced = new Biomass(); Detached = new Biomass(); Removed = new Biomass(); }
private void OnDoDailyInitialisation(object sender, EventArgs e) { if (Plant.IsAlive) { Allocated = new PMF.Biomass(); Senesced = new Biomass(); Detached = new Biomass(); Removed = new Biomass(); } }
protected void OnSimulationCommencing(object sender, EventArgs e) { Allocated = new PMF.Biomass(); Senesced = new Biomass(); Detached = new Biomass(); Removed = new Biomass(); NDemand = new BiomassPoolType(); DMDemand = new BiomassPoolType(); NSupply = new BiomassSupplyType(); DMSupply = new BiomassSupplyType(); }