Tissue Forge C++ 0.2.1
Interactive, particle-based physics, chemistry and biology modeling and simulation environment
Loading...
Searching...
No Matches
TissueForge::BoundaryCondition Struct Reference

A condition on a boundary of the universe. More...

#include <tfBoundaryConditions.h>

Collaboration diagram for TissueForge::BoundaryCondition:

Public Member Functions

void set_potential (struct ParticleType *ptype, struct Potential *pot)
 
std::string kindStr () const
 
std::string str (bool show_name) const
 
unsigned init (const unsigned &kind)
 
unsigned init (const FVector3 &velocity, const FPTYPE *restore=NULL)
 
unsigned init (const std::unordered_map< std::string, unsigned int > vals, const std::unordered_map< std::string, FVector3 > vels, const std::unordered_map< std::string, FPTYPE > restores)
 

Public Attributes

BoundaryConditionKind kind
 
int id
 
FVector3 velocity
 the velocity on the boundary
 
FPTYPE restore
 restoring percent.
 
const char * name
 name of the boundary
 
FVector3 normal
 vector normal to the boundary
 
struct Potential ** potenntials
 
FPTYPE radius
 

Detailed Description

A condition on a boundary of the universe.

Member Function Documentation

◆ set_potential()

void TissueForge::BoundaryCondition::set_potential ( struct ParticleType * ptype,
struct Potential * pot )

sets the potential for the given particle type.

Member Data Documentation

◆ potenntials

struct Potential** TissueForge::BoundaryCondition::potenntials

pointer to offset in main array allocated in BoundaryConditions.

◆ restore

FPTYPE TissueForge::BoundaryCondition::restore

restoring percent.

When objects hit this boundary, they get reflected back at restore percent, so if restore is 0.5, and object hitting the boundary at 3 length / time recoils with a velocity of 1.5 lengths / time.


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