示例#1
0
 /// <summary>Constructor, initialise tissues.</summary>
 /// <param name="numTissues">The number of tissues in the organ</param>
 public PastureAboveGroundOrgan(int numTissues)
 {
     // Typically four tissues above ground, three live and one dead
     TissueCount = numTissues;
     Tissue      = new GenericTissue[TissueCount];
     for (int t = 0; t < TissueCount; t++)
     {
         Tissue[t] = new GenericTissue();
     }
 }
示例#2
0
        /// <summary>Computes the DM and N amounts turned over for this tissue.</summary>
        /// <param name="turnoverRate">The turnover rate for the tissue today.</param>
        /// <param name="receivingTissue">The tissue to move the turned over biomass to.</param>
        /// <param name="nConc">The N concentration threshold to consider.</param>
        /// <remarks>For live tissues, potential N remobilisable is above optimum concentration, for dead is all above minimum</remarks>
        public void DoTissueTurnover(double turnoverRate, GenericTissue receivingTissue, double nConc)
        {
            if (DM.Wt > 0.0 && turnoverRate > 0.0)
            {
                var turnedoverDM = DM.Wt * turnoverRate;
                var turnedoverN  = DM.N * turnoverRate;
                DMTransferredOut += turnedoverDM;
                NTransferredOut  += turnedoverN;
                if (receivingTissue != null)
                {
                    receivingTissue.SetBiomassTransferIn(turnedoverDM, turnedoverN);
                }

                // get the N amount remobilisable (all N in this tissue above the given nConc concentration)
                double totalRemobilisableN = (DM.Wt - DMTransferredOut) * Math.Max(0.0, DM.NConc - nConc);
                totalRemobilisableN += Math.Max(0.0, NTransferredIn - DMTransferredIn * nConc);
                NRemobilisable       = Math.Max(0.0, totalRemobilisableN * FractionNRemobilisable);
            }
        }
 /// <summary>Constructor, initialise tissues</summary>
 public PastureAboveGroundOrgan(int numTissues)
 {
     // Typically four tissues above ground, three live and one dead
     TissueCount = numTissues;
     Tissue = new GenericTissue[TissueCount];
     for (int t = 0; t < TissueCount; t++)
         Tissue[t] = new GenericTissue();
 }
示例#4
0
        //----------------------- Public methods -----------------------

        /// <summary>Initialise this organ instance (and tissues).</summary>
        /// <param name="minimumLiveWt">Minimum live DM biomass for this organ (kg/ha).</param>
        public void Initialise(double minimumLiveWt)
        {
            LiveTissue    = new GenericTissue[] { EmergingTissue, DevelopingTissue, MatureTissue };
            MinimumLiveDM = minimumLiveWt;
        }