pele
Python energy landscape explorer
 All Classes Namespaces Functions Variables Typedefs
Public Member Functions | Protected Member Functions | Protected Attributes
pele::BaseHarmonic Class Reference

#include <harmonic.h>

Inheritance diagram for pele::BaseHarmonic:
pele::BasePotential pele::Harmonic pele::HarmonicCOM

List of all members.

Public Member Functions

virtual ~BaseHarmonic ()
virtual double get_energy (pele::Array< double > x)
virtual double get_energy_gradient (pele::Array< double > x, pele::Array< double > grad)
void set_k (double newk)
double get_k ()

Protected Member Functions

virtual void _get_distance (const pele::Array< double > &x)=0
 BaseHarmonic (const pele::Array< double > origin, const double k, const size_t ndim)

Protected Attributes

pele::Array< double > _origin
pele::Array< double > _distance
double _k
const size_t _ndim
const size_t _nparticles

Detailed Description

Definition at line 14 of file harmonic.h.


Constructor & Destructor Documentation

pele::BaseHarmonic::BaseHarmonic ( const pele::Array< double >  origin,
const double  k,
const size_t  ndim 
) [inline, protected]

Definition at line 22 of file harmonic.h.

virtual pele::BaseHarmonic::~BaseHarmonic ( ) [inline, virtual]

Definition at line 30 of file harmonic.h.


Member Function Documentation

virtual void pele::BaseHarmonic::_get_distance ( const pele::Array< double > &  x) [protected, pure virtual]

Implemented in pele::HarmonicCOM, and pele::Harmonic.

double pele::BaseHarmonic::get_energy ( pele::Array< double >  x) [inline, virtual]

Return the energy of configuration x. This is the only function which must be overloaded

Reimplemented from pele::BasePotential.

Definition at line 39 of file harmonic.h.

double pele::BaseHarmonic::get_energy_gradient ( pele::Array< double >  x,
pele::Array< double >  grad 
) [inline, virtual]

compute the energy and gradient.

If not overloaded it will compute the numerical gradient

Reimplemented from pele::BasePotential.

Definition at line 47 of file harmonic.h.

double pele::BaseHarmonic::get_k ( ) [inline]

Definition at line 34 of file harmonic.h.

void pele::BaseHarmonic::set_k ( double  newk) [inline]

Definition at line 33 of file harmonic.h.


Member Data Documentation

Definition at line 18 of file harmonic.h.

double pele::BaseHarmonic::_k [protected]

Definition at line 19 of file harmonic.h.

const size_t pele::BaseHarmonic::_ndim [protected]

Definition at line 20 of file harmonic.h.

const size_t pele::BaseHarmonic::_nparticles [protected]

Definition at line 21 of file harmonic.h.

Definition at line 17 of file harmonic.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs