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

Parameters for IBM elastic triangle (triel) More...

#include <ibm_triel.hpp>

Public Member Functions

double cutoff () const
 
void initialize (BoxGeometry const &box_geo, CellStructure const &cell_structure)
 Set the IBM Triel parameters.
 
 IBMTriel (int ind1, int ind2, int ind3, double maxDist, tElasticLaw elasticLaw, double k1, double k2)
 
std::optional< std::tuple< Utils::Vector3d, Utils::Vector3d, Utils::Vector3d > > calc_forces (Utils::Vector3d const &vec1, Utils::Vector3d const &vec2) const
 Calculate the forces.
 

Public Attributes

double l0
 
double lp0
 
double sinPhi0
 
double cosPhi0
 
double area0
 
double a1
 
double a2
 
double b1
 
double b2
 
double maxDist
 
tElasticLaw elasticLaw
 
double k1
 
double k2
 
std::tuple< int, int, int > p_ids
 Particle ids.
 
bool is_initialized
 

Static Public Attributes

static constexpr int num = 2
 

Detailed Description

Parameters for IBM elastic triangle (triel)

Definition at line 35 of file ibm_triel.hpp.

Constructor & Destructor Documentation

◆ IBMTriel()

IBMTriel::IBMTriel ( int  ind1,
int  ind2,
int  ind3,
double  maxDist,
tElasticLaw  elasticLaw,
double  k1,
double  k2 
)
inline

Definition at line 71 of file ibm_triel.hpp.

Member Function Documentation

◆ calc_forces()

std::optional< std::tuple< Utils::Vector3d, Utils::Vector3d, Utils::Vector3d > > IBMTriel::calc_forces ( Utils::Vector3d const &  vec1,
Utils::Vector3d const &  vec2 
) const

Calculate the forces.

The equations can be found in Appendix C of [25].

Returns
the forces on p1, p2, p3

Definition at line 74 of file ibm_triel.cpp.

References a1, a2, area0, b1, b2, cosPhi0, elasticLaw, k1, k2, l0, lp0, maxDist, NeoHookean, Utils::Vector< T, N >::norm(), sinPhi0, Utils::sqr(), and Utils::vector_product().

◆ cutoff()

double IBMTriel::cutoff ( ) const
inline

Definition at line 61 of file ibm_triel.hpp.

References maxDist.

◆ initialize()

void IBMTriel::initialize ( BoxGeometry const &  box_geo,
CellStructure const &  cell_structure 
)

Set the IBM Triel parameters.

Also calculate and store the reference state.

Definition at line 194 of file ibm_triel.cpp.

References a1, a2, area0, b1, b2, cosPhi0, get_ibm_particle_position(), BoxGeometry::get_mi_vector(), is_initialized, l0, lp0, p_ids, sinPhi0, and Utils::vector_product().

Member Data Documentation

◆ a1

double IBMTriel::a1

Definition at line 44 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ a2

double IBMTriel::a2

Definition at line 45 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ area0

double IBMTriel::area0

Definition at line 41 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ b1

double IBMTriel::b1

Definition at line 46 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ b2

double IBMTriel::b2

Definition at line 47 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ cosPhi0

double IBMTriel::cosPhi0

Definition at line 40 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ elasticLaw

tElasticLaw IBMTriel::elasticLaw

Definition at line 53 of file ibm_triel.hpp.

Referenced by calc_forces().

◆ is_initialized

bool IBMTriel::is_initialized

Definition at line 59 of file ibm_triel.hpp.

Referenced by initialize().

◆ k1

double IBMTriel::k1

Definition at line 54 of file ibm_triel.hpp.

Referenced by calc_forces().

◆ k2

double IBMTriel::k2

Definition at line 55 of file ibm_triel.hpp.

Referenced by calc_forces().

◆ l0

double IBMTriel::l0

Definition at line 37 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ lp0

double IBMTriel::lp0

Definition at line 38 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().

◆ maxDist

double IBMTriel::maxDist

Definition at line 52 of file ibm_triel.hpp.

Referenced by calc_forces(), and cutoff().

◆ num

constexpr int IBMTriel::num = 2
staticconstexpr

Definition at line 63 of file ibm_triel.hpp.

◆ p_ids

std::tuple<int, int, int> IBMTriel::p_ids

Particle ids.

Definition at line 58 of file ibm_triel.hpp.

Referenced by initialize().

◆ sinPhi0

double IBMTriel::sinPhi0

Definition at line 39 of file ibm_triel.hpp.

Referenced by calc_forces(), and initialize().


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