clClimateChange Class Reference

Climate Change - version 1.0. More...

#include <ClimateChange.h>

Inheritance diagram for clClimateChange:

clBehaviorBase clWorkerBase

List of all members.

Public Member Functions

 clClimateChange (clSimManager *p_oSimManager)
 Constructor.
void GetData (xercesc::DOMDocument *p_oDoc)
 Destructor - not needed.
void Action ()
 Updates the plot temperature or precipitation according to the function above.
void SetNameData (char *cNameString)
 Captures the namestring passed to this behavior.

Protected Attributes

float m_fTimeElapsed
 Time, in years, elapsed since the beginning of the run.
float m_fTimestepLength
 Length of timestep, in years.
float m_fB
 B parameter.
float m_fC
 C parameter.
float m_fStartingValue
 Starting value, either temperature or precipitation.
float m_fMin
 Lower bound.
float m_fMax
 Upper bound.
bool m_bIsTemp
 Whether this is for temperature (True) or precipitation (False).


Detailed Description

Climate Change - version 1.0.

This changes plot temperature or precipitation over time. There can be two versions of this behavior, one doing temperature and one doing precipitation, in the same run.

Temperature or precipitation at time t is: P = P1 + b * t^c where P1 is the starting value, c and b are parameters, and t is time elapsed, in years, since the beginning of the run.

The user can set upper and lower bounds on the climate variable.

This class's namestring is "climate change". The parameter file call string for the temperature version is "Temperature climate change". For precipitation, it's "Precipitation climate change".

Copyright 2010 Charles D. Canham.

Author:
Lora E. Murphy

Edit history:
-----------------
December 1, 2010 - Created (LEM)

Constructor & Destructor Documentation

clClimateChange::clClimateChange ( clSimManager p_oSimManager  ) 

Constructor.

Parameters:
p_oSimManager Sim Manager object.


Member Function Documentation

void clClimateChange::GetData ( xercesc::DOMDocument *  p_oDoc  )  [virtual]

Destructor - not needed.

Reads in values from the parameter file.

Parameters:
p_oDoc DOM tree of parsed input file.

Implements clWorkerBase.

void clClimateChange::Action (  )  [virtual]

Updates the plot temperature or precipitation according to the function above.

Reimplemented from clBehaviorBase.

void clClimateChange::SetNameData ( char *  cNameString  )  [virtual]

Captures the namestring passed to this behavior.

This is overridden from clBehaviorBase so we can capture the namestring passed. Since this class can create multiple kinds of behaviors that function differently, this will capture what kind of behavior this is supposed to be.

Parameters:
cNameString Behavior's namestring.

Reimplemented from clBehaviorBase.


Member Data Documentation

Time, in years, elapsed since the beginning of the run.

Length of timestep, in years.

float clClimateChange::m_fB [protected]

B parameter.

float clClimateChange::m_fC [protected]

C parameter.

Starting value, either temperature or precipitation.

float clClimateChange::m_fMin [protected]

Lower bound.

float clClimateChange::m_fMax [protected]

Upper bound.

bool clClimateChange::m_bIsTemp [protected]

Whether this is for temperature (True) or precipitation (False).


The documentation for this class was generated from the following file:

Generated on Tue Apr 19 13:56:07 2011 for SORTIE Core C++ Documentation by  doxygen 1.5.6