LOCA::ParameterVector Class Reference

LOCA's container for holding a set of parameters that are used by the LOCA continuation routines. More...

#include <LOCA_Parameter_Vector.H>

Collaboration diagram for LOCA::ParameterVector:

[legend]
List of all members.

Public Member Functions

 ParameterVector ()
 Construct a vector of length n. Can optionally be initialized to a scalar value.
 ParameterVector (const ParameterVector &source)
 Copy constructor.
ParameterVectorclone () const
 Clone.
 ~ParameterVector ()
 Destructor.
int addParameter (string label, double value=0.0)
 Adds a parameter to the list. Returns the index value assigned to the parameter.
bool init (double value)
 Initialize the vector. Returns true if successful.
bool scale (double value)
 Scales the entire vector by value. Returns true if successful.
bool scale (const ParameterVector &p)
 Scales the vactor with another vector (element-wise multiply). Returns true if successful.
bool update (double alpha, const ParameterVector &alphaVector, double b)
 Updates the parameter vector: this = alpha * alphaVector + b * this. Returns true if successful.
ParameterVectoroperator= (const ParameterVector &y)
 Set a parameter vector equal to another. This will erase any old parameters in the object.
double & operator[] (unsigned int i)
 Return a reference to the i-th element. Will throw an error if index is out of range.
const double & operator[] (unsigned int i) const
 Return a reference to the i-th element (no l-value type). Will throw an error if index is out of range.
void setValue (unsigned int i, double value)
 Set the value of the parameter with index i. Will throw an error if index is out of range.
void setValue (string label, double value)
 Set the value of the parameter with the corresponding label. Will throw an error if "label" is not valid.
double getValue (unsigned int i) const
 Returns the value of the parameter with index i. Will throw an error if index is out of range.
double getValue (string label) const
 Returns the value of the parameter with the corresponding label. Will throw an error if "label" is not valid.
int getIndex (string label) const
 Returns the index of the parameter with the corresponding label. Returns a -1 if "label" is not found.
double * getDoubleArrayPointer ()
 Returns a pointer to a C-style array of the parameter values.
bool isParameter (string label) const
 Returns true if the parameter string "label" corresponds to a parameter label in the object.
string getLabel (unsigned int i) const
 Returns the label of the parameter with index i.
int length () const
 Returns the length of parameter vector.
void print (ostream &stream) const
 Prints the vector to cout.
const vector< double > & getValuesVector () const
 Accessor to get the underlying stl vector with all parameter values.
const vector< string > & getNamesVector () const
 Accessor to get the underlying stl vector with all parameter names.

Protected Attributes

vector< double > x
 Parameter values.
vector< string > l
 Parameter names.

Detailed Description

LOCA's container for holding a set of parameters that are used by the LOCA continuation routines.

Author:
Roger Pawlowski (SNL 9233)


The documentation for this class was generated from the following files:
Generated on Thu Sep 18 12:42:22 2008 for NOX by doxygen 1.3.9.1