#include <thermodynamics.h>
Inherited by RNA.
Public Member Functions | |
int | SetTemperature (double temperature) |
Set the temperature of folding in K. | |
double | GetTemperature () |
Get the current folding temperature in K. | |
int | ReadThermodynamic () |
Function to read the thermodynamic parameters. | |
datatable * | GetDatatable () |
datatable * | GetEnthalpyTable () |
Protected Attributes | |
bool | energyread |
Access the thermodynamic parameter class an instance of datatable. |
The RNA class provides an encapsulation of the functions and struct for reading and storing thermodynamic parameters. This includes methods for changing folding temperatures This class is intended for use in inheritance for classes that provide functionality.
datatable * Thermodynamics::GetDatatable | ( | ) |
This function is used during inheritance o provide access to the free energy change parameters. This function generates no errors. (Error checking was done for this during construction).
datatable * Thermodynamics::GetEnthalpyTable | ( | ) |
This function is used to provide an enthalpy table. This function will return a NULL pointer if there is an error reading the tables from disk. It is important that programs check the status of the pointer before using it, i.e. make sure it is not NULL.
double Thermodynamics::GetTemperature | ( | ) |
Get the current folding temperature in K.
int Thermodynamics::ReadThermodynamic | ( | ) |
Function to read the thermodynamic parameters.
This function depends on temp, the current temperature, to determine in the folding free energies need to be set to other than those read in files for 310.15 K. Return of zero => no error and a return of non-zero indicates error. Public functions that need the thermodynamic parameters call this function.
int Thermodynamics::SetTemperature | ( | double | temperature | ) |
Set the temperature of folding in K.
This function allows the user to specify folding temperatures other than 310.15 (37 degrees C). This changes folding free energy changes that would be returned for existing structures and would alter the set of structures predicted. When this function is called, the tehrmodynamic parameter files are immediately read from disk. These include both enthalpy parameters (.dh files) and free energy changes at 310.15 (.dat files). The files must either be at a location indicated by the $DATAPATH environment variable or in pwd. Changing the temperature only alters subsequent calculations. For example, if a structure prediction method has been called, the set of predicted structures are not changed at the time of a call to SetTemperature. Likewise, SetTemperature must be called before calling a structure prediction method if a temperature other than the 310.15 K default is desired. The function returns an error code where 0 is no error and non-zero errors can be parsed by by GetErrorMessage() or GetErrorMessageString() in an inheriting class.