ESPResSo
Extensible Simulation Package for Research on Soft Matter Systems
Loading...
Searching...
No Matches
Observable_stat Class Reference

Observable for the pressure and energy. More...

#include <Observable_stat.hpp>

+ Collaboration diagram for Observable_stat:

Public Member Functions

 Observable_stat (std::size_t chunk_size, std::size_t n_bonded, int max_type)
 
auto get_chunk_size () const
 
double accumulate (double acc=0.0, std::size_t column=0ul) const
 Accumulate values.
 
void rescale (double volume)
 Rescale values.
 
std::span< double > bonded_contribution (int bond_id) const
 Get contribution from a bonded interaction.
 
void add_non_bonded_contribution (int type1, int type2, int molid1, int molid2, std::span< const double > data)
 
void add_non_bonded_contribution (int type1, int type2, int molid1, int molid2, double data)
 
auto non_bonded_intra_contribution (int type1, int type2) const
 Get contribution from a non-bonded intramolecular interaction.
 
auto non_bonded_inter_contribution (int type1, int type2) const
 Get contribution from a non-bonded intermolecular interaction.
 
void mpi_reduce ()
 MPI reduction.
 

Public Attributes

std::span< double > kinetic
 Contribution from linear and angular kinetic energy (accumulated).
 
std::span< double > bonded
 Contribution(s) from bonded interactions.
 
std::span< double > coulomb
 Contribution(s) from Coulomb interactions.
 
std::span< double > dipolar
 Contribution(s) from dipolar interactions.
 
std::span< double > virtual_sites
 Contribution from virtual sites (accumulated).
 
std::span< double > external_fields
 Contribution from external fields (accumulated).
 
std::span< double > non_bonded_intra
 Contribution(s) from non-bonded intramolecular interactions.
 
std::span< double > non_bonded_inter
 Contribution(s) from non-bonded intermolecular interactions.
 

Detailed Description

Observable for the pressure and energy.

Definition at line 31 of file Observable_stat.hpp.

Constructor & Destructor Documentation

◆ Observable_stat()

Observable_stat::Observable_stat ( std::size_t  chunk_size,
std::size_t  n_bonded,
int  max_type 
)

Member Function Documentation

◆ accumulate()

double Observable_stat::accumulate ( double  acc = 0.0,
std::size_t  column = 0ul 
) const
inline

Accumulate values.

Parameters
accInitial value for the accumulator.
columnWhich column to sum up (only relevant for multi-dimensional observables).

Definition at line 56 of file Observable_stat.hpp.

Referenced by ScriptInterface::Analysis::get_summary().

◆ add_non_bonded_contribution() [1/2]

void Observable_stat::add_non_bonded_contribution ( int  type1,
int  type2,
int  molid1,
int  molid2,
double  data 
)
inline

Definition at line 105 of file Observable_stat.hpp.

References add_non_bonded_contribution().

◆ add_non_bonded_contribution() [2/2]

void Observable_stat::add_non_bonded_contribution ( int  type1,
int  type2,
int  molid1,
int  molid2,
std::span< const double >  data 
)
inline

◆ bonded_contribution()

std::span< double > Observable_stat::bonded_contribution ( int  bond_id) const
inline

Get contribution from a bonded interaction.

Definition at line 91 of file Observable_stat.hpp.

References bonded.

Referenced by ScriptInterface::Analysis::get_summary().

◆ get_chunk_size()

auto Observable_stat::get_chunk_size ( ) const
inline

Definition at line 49 of file Observable_stat.hpp.

Referenced by ScriptInterface::Analysis::get_summary().

◆ mpi_reduce()

void Observable_stat::mpi_reduce ( )

MPI reduction.

Definition at line 77 of file Observable_stat.cpp.

References comm_cart.

◆ non_bonded_inter_contribution()

auto Observable_stat::non_bonded_inter_contribution ( int  type1,
int  type2 
) const
inline

Get contribution from a non-bonded intermolecular interaction.

Definition at line 116 of file Observable_stat.hpp.

References non_bonded_inter.

Referenced by ScriptInterface::Analysis::get_summary().

◆ non_bonded_intra_contribution()

auto Observable_stat::non_bonded_intra_contribution ( int  type1,
int  type2 
) const
inline

Get contribution from a non-bonded intramolecular interaction.

Definition at line 111 of file Observable_stat.hpp.

References non_bonded_intra.

Referenced by ScriptInterface::Analysis::get_summary().

◆ rescale()

void Observable_stat::rescale ( double  volume)
inline

Rescale values.

Definition at line 68 of file Observable_stat.hpp.

Member Data Documentation

◆ bonded

std::span<double> Observable_stat::bonded

Contribution(s) from bonded interactions.

Definition at line 76 of file Observable_stat.hpp.

Referenced by bonded_contribution(), and Observable_stat().

◆ coulomb

std::span<double> Observable_stat::coulomb

Contribution(s) from Coulomb interactions.

Definition at line 78 of file Observable_stat.hpp.

Referenced by add_non_bonded_pair_energy(), add_non_bonded_pair_virials(), ScriptInterface::Analysis::get_summary(), and Observable_stat().

◆ dipolar

std::span<double> Observable_stat::dipolar

◆ external_fields

std::span<double> Observable_stat::external_fields

Contribution from external fields (accumulated).

Definition at line 84 of file Observable_stat.hpp.

Referenced by Constraints::ExternalPotential< Coupling, Field >::add_energy(), ScriptInterface::Analysis::get_summary(), and Observable_stat().

◆ kinetic

std::span<double> Observable_stat::kinetic

Contribution from linear and angular kinetic energy (accumulated).

Definition at line 74 of file Observable_stat.hpp.

Referenced by add_kinetic_virials(), ScriptInterface::Analysis::get_summary(), and Observable_stat().

◆ non_bonded_inter

std::span<double> Observable_stat::non_bonded_inter

Contribution(s) from non-bonded intermolecular interactions.

Definition at line 88 of file Observable_stat.hpp.

Referenced by add_non_bonded_contribution(), non_bonded_inter_contribution(), and Observable_stat().

◆ non_bonded_intra

std::span<double> Observable_stat::non_bonded_intra

Contribution(s) from non-bonded intramolecular interactions.

Definition at line 86 of file Observable_stat.hpp.

Referenced by add_non_bonded_contribution(), non_bonded_intra_contribution(), and Observable_stat().

◆ virtual_sites

std::span<double> Observable_stat::virtual_sites

Contribution from virtual sites (accumulated).

Definition at line 82 of file Observable_stat.hpp.

Referenced by ScriptInterface::Analysis::get_summary(), and Observable_stat().


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