00001 //--------------------------------------------------------------------------- 00002 00003 #ifndef MichMenGrowthBaseH 00004 #define MichMenGrowthBaseH 00005 //--------------------------------------------------------------------------- 00006 #include "GrowthBase.h" 00007 00008 //class DOMDocument; 00009 00024 class clMichMenBase : virtual public clGrowthBase { 00025 //note: need the virtual keyword to avoid base class ambiguity. 00026 public: 00027 00033 clMichMenBase(clSimManager *p_oSimManager); 00034 00038 virtual ~clMichMenBase(); 00039 00040 protected: 00041 00042 //These are the variables held in common by the descendent classes. 00043 00044 //I did have these as static but I un-static-ed them because it was hard 00045 //to tell which species required what. I know that means multiple copies 00046 //but for now that's okay. 00047 00048 float *mp_fSlopeGrowthResponse; 00050 float *mp_fAdultConstBAInc; 00053 float *mp_fAdultConstRadInc; 00056 float *mp_fAsympDiamGrowth; 00060 bool m_bConstRadialLimited; 00062 bool m_bConstBasalAreaLimited; 00073 void GetParameterFileData(xercesc::DOMDocument *p_oDoc); 00074 00082 inline float CalculateMichaelisMentonFunction(short int &iSpecies, float &fGli) 00083 { return ( (mp_fAsympDiamGrowth[iSpecies] * fGli) / 00084 (mp_fSlopeGrowthResponse[iSpecies] + fGli) ); }; 00085 00101 float ApplyGrowthLimits(const short int &iSpecies, 00102 const float &fAmountDiamIncrease, const float &fDiam); 00103 00114 float GetGrowthMemberValue(clTree *p_oTree, float fDiameterGrowth); 00115 00116 }; 00117 //--------------------------------------------------------------------------- 00118 #endif