Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
PLMD::ves::CoeffsBase Class Reference

#include <CoeffsBase.h>

Inheritance diagram for PLMD::ves::CoeffsBase:
Inheritance graph
[legend]

Public Member Functions

 CoeffsBase ()
 
 CoeffsBase (const std::string &, const std::vector< std::string > &, const std::vector< unsigned int > &, const bool use_iteration_counter=false)
 
 CoeffsBase (const std::string &, std::vector< Value *> &, std::vector< BasisFunctions *> &, const bool use_iteration_counter=false)
 
 CoeffsBase (const std::string &, std::vector< std::vector< Value *> > &, std::vector< std::vector< BasisFunctions *> > &, const bool use_iteration_counter=false, const std::string &multicoeffs_label="bias")
 
 ~CoeffsBase ()
 
std::string getLabel () const
 
void setLabel (const std::string &)
 
std::string getDataLabel () const
 
void setDataLabel (const std::string &)
 
void setLabels (const std::string &)
 
void setLabels (const std::string &, const std::string &)
 
CoeffsType getType () const
 
std::string getTypeStr () const
 
void setType (const CoeffsType coeffs_type)
 
void linkVesBias (VesBias *)
 
void linkAction (Action *)
 
VesBiasgetPntrToVesBias () const
 
ActiongetPntrToAction () const
 
bool isGenericCoeffs () const
 
bool isLinearBasisSetCoeffs () const
 
bool isMultiLinearBasisSetCoeffs () const
 
std::vector< unsigned int > shapeOfIndices () const
 
unsigned int shapeOfIndices (const unsigned int dim_index) const
 
size_t numberOfCoeffs () const
 
unsigned int numberOfDimensions () const
 
bool isActive () const
 
void activate ()
 
void deactivate ()
 
size_t getIndex (const std::vector< unsigned int > &) const
 
std::vector< unsigned int > getIndices (const size_t) const
 
bool indicesExist (const std::vector< unsigned int > &) const
 
std::string getCoeffDescription (const size_t index) const
 
std::string getCoeffDescription (const std::vector< unsigned int > &) const
 
std::vector< std::string > getAllCoeffsDescriptions () const
 
void setCoeffDescription (const size_t, const std::string &)
 
void setCoeffDescription (const std::vector< unsigned int > &, const std::string &)
 
void setAllCoeffsDescriptions (const std::string &description_prefix="C")
 
void setAllCoeffsDescriptions (const std::vector< std::string > &)
 
std::string getDimensionLabel (const unsigned int) const
 
std::vector< std::string > getAllDimensionLabels () const
 
void setDimensionLabel (const unsigned int, const std::string &)
 
void setAllDimensionLabels (const std::string &)
 
void setAllDimensionLabels (const std::vector< std::string > &)
 
void writeCoeffsInfoToFile (OFile &) const
 
void writeTimeInfoToFile (OFile &, const double) const
 
void getCoeffsInfoFromFile (IFile &, const bool ignore_coeffs_info=false)
 
void checkCoeffsInfo (const std::string &, const std::string &, const unsigned int, const size_t, const std::vector< unsigned int > &)
 
void turnOnIterationCounter ()
 
void turnOffIterationCounter ()
 
bool isIterationCounterActive () const
 
void setIterationCounter (const unsigned int)
 
void setTime (const double)
 
void setIterationCounterAndTime (const unsigned int, const double)
 
unsigned int getIterationCounter () const
 
double getTimeValue () const
 
void setOutputFmt (const std::string &ss)
 
void resetOutputFmt ()
 
std::string getOutputFmt () const
 

Protected Member Functions

void setupBasisFunctionsInfo ()
 
void resizeIndices (const std::vector< unsigned int > &)
 
void resizeIndices (std::vector< BasisFunctions *> &)
 
bool sameShape (const CoeffsBase &) const
 
void writeIterationCounterAndTimeToFile (OFile &) const
 
bool getIterationCounterAndTimeFromFile (IFile &)
 

Private Types

enum  CoeffsType { Generic, LinearBasisSet, MultiCoeffs_LinearBasisSet }
 

Private Member Functions

void initializeIndices (const std::vector< unsigned int > &, const std::vector< std::string > &)
 
void reinitializeIndices (const std::vector< unsigned int > &)
 

Private Attributes

std::string label_
 
std::string data_label_
 
enum PLMD::ves::CoeffsBase::CoeffsType coeffs_type_
 
bool iteration_and_time_active_
 
unsigned int iteration_opt
 
double time_md
 
bool active
 
Actionaction_pntr_
 
VesBiasvesbias_pntr_
 
unsigned int ndimensions_
 
std::vector< unsigned int > indices_shape_
 
size_t ncoeffs_
 
std::vector< std::string > coeffs_descriptions_
 
std::vector< std::string > dimension_labels_
 
std::vector< Value * > args_
 
std::vector< BasisFunctions * > basisf_
 
bool multicoeffs_
 
std::vector< std::vector< Value * > > multicoeffs_args_
 
std::vector< std::vector< BasisFunctions * > > multicoeffs_basisf_
 
const std::string field_type_
 
const std::string field_ndimensions_
 
const std::string field_ncoeffs_total_
 
const std::string field_shape_prefix_
 
const std::string field_time_
 
const std::string field_iteration_
 
std::string output_fmt_
 

Member Enumeration Documentation

◆ CoeffsType

Enumerator
Generic 
LinearBasisSet 
MultiCoeffs_LinearBasisSet 

Constructor & Destructor Documentation

◆ CoeffsBase() [1/4]

PLMD::ves::CoeffsBase::CoeffsBase ( )
explicit

◆ CoeffsBase() [2/4]

PLMD::ves::CoeffsBase::CoeffsBase ( const std::string &  label,
const std::vector< std::string > &  dimension_labels,
const std::vector< unsigned int > &  indices_shape,
const bool  use_iteration_counter = false 
)
explicit

◆ CoeffsBase() [3/4]

PLMD::ves::CoeffsBase::CoeffsBase ( const std::string &  label,
std::vector< Value *> &  args,
std::vector< BasisFunctions *> &  basisf,
const bool  use_iteration_counter = false 
)
explicit

◆ CoeffsBase() [4/4]

PLMD::ves::CoeffsBase::CoeffsBase ( const std::string &  label,
std::vector< std::vector< Value *> > &  multicoeffs_args,
std::vector< std::vector< BasisFunctions *> > &  multicoeffs_basisf,
const bool  use_iteration_counter = false,
const std::string &  multicoeffs_label = "bias" 
)
explicit

◆ ~CoeffsBase()

PLMD::ves::CoeffsBase::~CoeffsBase ( )

Member Function Documentation

◆ activate()

void PLMD::ves::CoeffsBase::activate ( )
inline

◆ checkCoeffsInfo()

void PLMD::ves::CoeffsBase::checkCoeffsInfo ( const std::string &  msg_header,
const std::string &  coeffs_type_f,
const unsigned int  ndimensions_f,
const size_t  ncoeffs_total_f,
const std::vector< unsigned int > &  indices_shape_f 
)

◆ deactivate()

void PLMD::ves::CoeffsBase::deactivate ( )
inline

◆ getAllCoeffsDescriptions()

std::vector<std::string> PLMD::ves::CoeffsBase::getAllCoeffsDescriptions ( ) const
inline

◆ getAllDimensionLabels()

std::vector<std::string> PLMD::ves::CoeffsBase::getAllDimensionLabels ( ) const
inline

◆ getCoeffDescription() [1/2]

std::string PLMD::ves::CoeffsBase::getCoeffDescription ( const size_t  index) const
inline

◆ getCoeffDescription() [2/2]

std::string PLMD::ves::CoeffsBase::getCoeffDescription ( const std::vector< unsigned int > &  indices) const
inline

◆ getCoeffsInfoFromFile()

void PLMD::ves::CoeffsBase::getCoeffsInfoFromFile ( IFile ifile,
const bool  ignore_coeffs_info = false 
)

◆ getDataLabel()

std::string PLMD::ves::CoeffsBase::getDataLabel ( ) const
inline

◆ getDimensionLabel()

std::string PLMD::ves::CoeffsBase::getDimensionLabel ( const unsigned int  dim_index) const
inline

◆ getIndex()

size_t PLMD::ves::CoeffsBase::getIndex ( const std::vector< unsigned int > &  indices) const
inline

◆ getIndices()

std::vector< unsigned int > PLMD::ves::CoeffsBase::getIndices ( const size_t  index) const
inline

◆ getIterationCounter()

unsigned int PLMD::ves::CoeffsBase::getIterationCounter ( ) const
inline

◆ getIterationCounterAndTimeFromFile()

bool PLMD::ves::CoeffsBase::getIterationCounterAndTimeFromFile ( IFile ifile)
protected

◆ getLabel()

std::string PLMD::ves::CoeffsBase::getLabel ( ) const
inline

◆ getOutputFmt()

std::string PLMD::ves::CoeffsBase::getOutputFmt ( ) const
inline

◆ getPntrToAction()

Action* PLMD::ves::CoeffsBase::getPntrToAction ( ) const
inline

◆ getPntrToVesBias()

VesBias* PLMD::ves::CoeffsBase::getPntrToVesBias ( ) const
inline

◆ getTimeValue()

double PLMD::ves::CoeffsBase::getTimeValue ( ) const
inline

◆ getType()

CoeffsType PLMD::ves::CoeffsBase::getType ( ) const
inline

◆ getTypeStr()

std::string PLMD::ves::CoeffsBase::getTypeStr ( ) const

◆ indicesExist()

bool PLMD::ves::CoeffsBase::indicesExist ( const std::vector< unsigned int > &  indices) const

◆ initializeIndices()

void PLMD::ves::CoeffsBase::initializeIndices ( const std::vector< unsigned int > &  indices_shape,
const std::vector< std::string > &  dimension_labels 
)
private

◆ isActive()

bool PLMD::ves::CoeffsBase::isActive ( ) const
inline

◆ isGenericCoeffs()

bool PLMD::ves::CoeffsBase::isGenericCoeffs ( ) const
inline

◆ isIterationCounterActive()

bool PLMD::ves::CoeffsBase::isIterationCounterActive ( ) const
inline

◆ isLinearBasisSetCoeffs()

bool PLMD::ves::CoeffsBase::isLinearBasisSetCoeffs ( ) const
inline

◆ isMultiLinearBasisSetCoeffs()

bool PLMD::ves::CoeffsBase::isMultiLinearBasisSetCoeffs ( ) const
inline

◆ linkAction()

void PLMD::ves::CoeffsBase::linkAction ( Action action_pntr_in)

◆ linkVesBias()

void PLMD::ves::CoeffsBase::linkVesBias ( VesBias vesbias_pntr_in)

◆ numberOfCoeffs()

size_t PLMD::ves::CoeffsBase::numberOfCoeffs ( ) const
inline

◆ numberOfDimensions()

unsigned int PLMD::ves::CoeffsBase::numberOfDimensions ( ) const
inline

◆ reinitializeIndices()

void PLMD::ves::CoeffsBase::reinitializeIndices ( const std::vector< unsigned int > &  indices_shape_new)
private

◆ resetOutputFmt()

void PLMD::ves::CoeffsBase::resetOutputFmt ( )
inline

◆ resizeIndices() [1/2]

void PLMD::ves::CoeffsBase::resizeIndices ( const std::vector< unsigned int > &  indices_shape_new)
protected

◆ resizeIndices() [2/2]

void PLMD::ves::CoeffsBase::resizeIndices ( std::vector< BasisFunctions *> &  basisf_new)
protected

◆ sameShape()

bool PLMD::ves::CoeffsBase::sameShape ( const CoeffsBase coeffsbase_in) const
protected

◆ setAllCoeffsDescriptions() [1/2]

void PLMD::ves::CoeffsBase::setAllCoeffsDescriptions ( const std::string &  description_prefix = "C")

◆ setAllCoeffsDescriptions() [2/2]

void PLMD::ves::CoeffsBase::setAllCoeffsDescriptions ( const std::vector< std::string > &  coeffs_descriptions)

◆ setAllDimensionLabels() [1/2]

void PLMD::ves::CoeffsBase::setAllDimensionLabels ( const std::string &  label_prefix)

◆ setAllDimensionLabels() [2/2]

void PLMD::ves::CoeffsBase::setAllDimensionLabels ( const std::vector< std::string > &  labels)

◆ setCoeffDescription() [1/2]

void PLMD::ves::CoeffsBase::setCoeffDescription ( const size_t  index,
const std::string &  description 
)

◆ setCoeffDescription() [2/2]

void PLMD::ves::CoeffsBase::setCoeffDescription ( const std::vector< unsigned int > &  indices,
const std::string &  description 
)

◆ setDataLabel()

void PLMD::ves::CoeffsBase::setDataLabel ( const std::string &  data_label)

◆ setDimensionLabel()

void PLMD::ves::CoeffsBase::setDimensionLabel ( const unsigned int  dim_index,
const std::string &  label 
)

◆ setIterationCounter()

void PLMD::ves::CoeffsBase::setIterationCounter ( const unsigned int  iteration_opt_in)
inline

◆ setIterationCounterAndTime()

void PLMD::ves::CoeffsBase::setIterationCounterAndTime ( const unsigned int  iteration_opt_in,
const double  time_md_in 
)
inline

◆ setLabel()

void PLMD::ves::CoeffsBase::setLabel ( const std::string &  label)

◆ setLabels() [1/2]

void PLMD::ves::CoeffsBase::setLabels ( const std::string &  label)

◆ setLabels() [2/2]

void PLMD::ves::CoeffsBase::setLabels ( const std::string &  label,
const std::string &  data_label 
)

◆ setOutputFmt()

void PLMD::ves::CoeffsBase::setOutputFmt ( const std::string &  ss)
inline

◆ setTime()

void PLMD::ves::CoeffsBase::setTime ( const double  time_md_in)
inline

◆ setType()

void PLMD::ves::CoeffsBase::setType ( const CoeffsType  coeffs_type)

◆ setupBasisFunctionsInfo()

void PLMD::ves::CoeffsBase::setupBasisFunctionsInfo ( )
protected

◆ shapeOfIndices() [1/2]

std::vector<unsigned int> PLMD::ves::CoeffsBase::shapeOfIndices ( ) const
inline

◆ shapeOfIndices() [2/2]

unsigned int PLMD::ves::CoeffsBase::shapeOfIndices ( const unsigned int  dim_index) const
inline

◆ turnOffIterationCounter()

void PLMD::ves::CoeffsBase::turnOffIterationCounter ( )
inline

◆ turnOnIterationCounter()

void PLMD::ves::CoeffsBase::turnOnIterationCounter ( )
inline

◆ writeCoeffsInfoToFile()

void PLMD::ves::CoeffsBase::writeCoeffsInfoToFile ( OFile ofile) const

◆ writeIterationCounterAndTimeToFile()

void PLMD::ves::CoeffsBase::writeIterationCounterAndTimeToFile ( OFile ofile) const
protected

◆ writeTimeInfoToFile()

void PLMD::ves::CoeffsBase::writeTimeInfoToFile ( OFile ,
const double   
) const

Member Data Documentation

◆ action_pntr_

Action* PLMD::ves::CoeffsBase::action_pntr_
private

◆ active

bool PLMD::ves::CoeffsBase::active
private

◆ args_

std::vector<Value*> PLMD::ves::CoeffsBase::args_
private

◆ basisf_

std::vector<BasisFunctions*> PLMD::ves::CoeffsBase::basisf_
private

◆ coeffs_descriptions_

std::vector<std::string> PLMD::ves::CoeffsBase::coeffs_descriptions_
private

◆ coeffs_type_

enum PLMD::ves::CoeffsBase::CoeffsType PLMD::ves::CoeffsBase::coeffs_type_
private

◆ data_label_

std::string PLMD::ves::CoeffsBase::data_label_
private

◆ dimension_labels_

std::vector<std::string> PLMD::ves::CoeffsBase::dimension_labels_
private

◆ field_iteration_

const std::string PLMD::ves::CoeffsBase::field_iteration_
private

◆ field_ncoeffs_total_

const std::string PLMD::ves::CoeffsBase::field_ncoeffs_total_
private

◆ field_ndimensions_

const std::string PLMD::ves::CoeffsBase::field_ndimensions_
private

◆ field_shape_prefix_

const std::string PLMD::ves::CoeffsBase::field_shape_prefix_
private

◆ field_time_

const std::string PLMD::ves::CoeffsBase::field_time_
private

◆ field_type_

const std::string PLMD::ves::CoeffsBase::field_type_
private

◆ indices_shape_

std::vector<unsigned int> PLMD::ves::CoeffsBase::indices_shape_
private

◆ iteration_and_time_active_

bool PLMD::ves::CoeffsBase::iteration_and_time_active_
private

◆ iteration_opt

unsigned int PLMD::ves::CoeffsBase::iteration_opt
private

◆ label_

std::string PLMD::ves::CoeffsBase::label_
private

◆ multicoeffs_

bool PLMD::ves::CoeffsBase::multicoeffs_
private

◆ multicoeffs_args_

std::vector<std::vector<Value*> > PLMD::ves::CoeffsBase::multicoeffs_args_
private

◆ multicoeffs_basisf_

std::vector<std::vector<BasisFunctions*> > PLMD::ves::CoeffsBase::multicoeffs_basisf_
private

◆ ncoeffs_

size_t PLMD::ves::CoeffsBase::ncoeffs_
private

◆ ndimensions_

unsigned int PLMD::ves::CoeffsBase::ndimensions_
private

◆ output_fmt_

std::string PLMD::ves::CoeffsBase::output_fmt_
private

◆ time_md

double PLMD::ves::CoeffsBase::time_md
private

◆ vesbias_pntr_

VesBias* PLMD::ves::CoeffsBase::vesbias_pntr_
private

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