ESPResSo
Extensible Simulation Package for Research on Soft Matter Systems
Loading...
Searching...
No Matches
Observables::Observable Class Referenceabstract

Base class for observables. More...

#include <Observable.hpp>

+ Inheritance diagram for Observables::Observable:

Public Member Functions

 Observable ()=default
 
virtual ~Observable ()=default
 
virtual std::vector< double > operator() (boost::mpi::communicator const &comm) const =0
 Calculate the set of values measured by the observable.
 
std::size_t n_values () const
 Size of the flat array returned by the observable.
 
virtual std::vector< std::size_t > shape () const =0
 Dimensions needed to reshape the flat array returned by the observable.
 

Detailed Description

Base class for observables.

An observable extracts raw data from a system or compute a statistic based on the state of a system, and returns an array of doubles.

Observables typically don't have setters or getters to access and modify their member variables, and usually only have a default constructor with no argument. Each observable class has a corresponding interface in ScriptInterface::Observables, where setters and getters are defined.

Definition at line 42 of file core/observables/Observable.hpp.

Constructor & Destructor Documentation

◆ Observable()

Observables::Observable::Observable ( )
default

◆ ~Observable()

virtual Observables::Observable::~Observable ( )
virtualdefault

Member Function Documentation

◆ n_values()

std::size_t Observables::Observable::n_values ( ) const
inline

◆ operator()()

virtual std::vector< double > Observables::Observable::operator() ( boost::mpi::communicator const &  comm) const
pure virtual

◆ shape()


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