Substrate.h

00001 //---------------------------------------------------------------------------
00002 
00003 #ifndef SubstrateH
00004 #define SubstrateH
00005 //---------------------------------------------------------------------------
00006 #include "BehaviorBase.h"
00007 
00008 class clGridBase;
00009 class clSimManager;
00010 class DOMDocument;
00011 
00084 class clSubstrate : virtual public clBehaviorBase {
00085 
00086  public:
00087 
00092   clSubstrate(clSimManager *p_oSimManager);
00093 
00097   ~clSubstrate();
00098 
00105   void GetData(xercesc::DOMDocument *p_oDoc);
00106 
00113   void Action();
00114 
00115   protected:
00116 
00118   float *mp_fPropOfDeadThatFall;
00119 
00122   float *mp_fPropOfFallenThatUproot;
00123 
00126   float *mp_fPropOfSnagsThatUproot;
00127 
00131   float *mp_fFLogDecayProp;
00132 
00136   float *mp_fScarSoilDecayProp;
00137 
00141   float *mp_fTipupDecayProp;
00142 
00146   float *mp_fDecLogDecayProp;
00147 
00149   short int **mp_iDeadCodes;
00150 
00152   short int *mp_iFLogCalcsCode;
00153 
00155   short int *mp_iDecLogCalcsCode;
00156 
00159   bool **mp_bSubstrateApplies;
00160 
00162   float m_fScarifiedSoilA;
00163 
00165   float m_fTipUpA;
00166 
00168   float m_fFreshLogA;
00169 
00171   float m_fDecayedLogA;
00172 
00174   float m_fScarifiedSoilB;
00175 
00177   float m_fTipUpB;
00178 
00180   float m_fFreshLogB;
00181 
00183   float m_fDecayedLogB;
00184 
00186   float m_fInitScarifiedSoil;
00187 
00189   float m_fInitTipUp;
00190 
00192   float m_fInitFreshLog;
00193 
00195   float m_fInitDecayedLog;
00196 
00199   float m_fPartCutScarifiedSoil;
00200 
00203   float m_fPartCutTipUp;
00204 
00207   float m_fPartCutFreshLog;
00208 
00211   float m_fPartCutDecayedLog;
00212 
00215   float m_fGapCutScarifiedSoil;
00216 
00218   float m_fGapCutTipUp;
00219 
00222   float m_fGapCutFreshLog;
00223 
00226   float m_fGapCutDecayedLog;
00227 
00230   float m_fClearCutScarifiedSoil;
00231 
00234   float m_fClearCutTipUp;
00235 
00238   float m_fClearCutFreshLog;
00239 
00242   float m_fClearCutDecayedLog;
00243 
00246   float m_fRootTipupFactor;
00247 
00249   float m_fMossProportion;
00250 
00252   float m_fGridCellArea;
00253 
00255   float m_fRecipOfGridCellArea;
00256 
00258   int m_iMaxDecayYears;
00259 
00262   int m_iMaxDecayTimesteps;
00263 
00264   short int m_iNumTotalSpecies;   
00265   short int m_iScarSoilCode;      
00266   short int m_iFFMossCode;        
00267   short int m_iFFLitterCode;      
00268   short int m_iTipupCode;         
00269   short int m_iFreshLogCode;      
00270   short int m_iDecLogCode;        
00271   short int m_iPkgAgeCode;        
00272   short int m_iPkgScarSoilCode;   
00273   short int m_iPkgTipupCode;      
00274   short int m_iPkgFreshLogCode;   
00275   short int m_iHarvestTypeCode;   
00276   short int m_iTipupCalcsCode;    
00280   bool m_bParFileHasSubstrateMap;
00281 
00287   bool m_bUseDirectionalTreeFall;
00288 
00345   clGridBase *mp_oSubstrateGrid;
00346 
00366   clGridBase *mp_oCalcGrid;
00367 
00369   clGridBase *mp_oHarvestGrid;
00370 
00376   void GetParameterFileData(xercesc::DOMDocument *p_oDoc);
00377 
00383   void SetupSubstrateGrids();
00384 
00391   void AdjustNewSubstrateToProportion();
00392 
00403   void PopulateInitialConditions();
00404 
00411   void GetDeadCodes();
00412 
00419   void CalculateDecayProportions();
00420 
00433   void HarvestSubstrate();
00434 
00450   void UpdateSubstrateAges();
00451 
00456   void MortalitySubstrate();
00457 
00489   void AddNewDeadTrees();
00490 
00502   void AdjustSubstrateForMortality();
00503 
00513   void AddHarvestAndInitialNewSubstrate();
00514 
00524   void DecaySubstrate();
00525 };
00526 //---------------------------------------------------------------------------
00527 #endif

Generated on Thu Jan 26 13:44:35 2006 for SORTIE Core C++ Documentation by  doxygen 1.4.6-NO