Object bouncers

Bouncers prevent liquid particles crossing boundaries of objects (maintaining no-through boundary conditions). The idea of the bouncers is to move the particles that crossed the object boundary after integration step back to the correct side. Particles are moved such that they appear very close (about \(10^{-5}\) units away from the boundary). Assuming that the objects never come too close to each other or the walls, that approach ensures that recovered particles will not penetrate into a different object or wall. In practice maintaining separation of at least \(10^{-3}\) units between walls and objects is sufficient. Note that particle velocities are also altered, which means that objects experience extra force from the collisions.

Summary

Bouncer Base class for bouncing particles off the objects
Ellipsoid() This bouncer will use the analytical ellipsoid representation to perform the bounce.
Mesh() This bouncer will use the triangular mesh associated with objects to detect boundary crossings.

Details

class Bouncer

Bases: object

Base class for bouncing particles off the objects

class Ellipsoid

Bases: _ymero.Bouncers.Bouncer

This bouncer will use the analytical ellipsoid representation to perform the bounce. No additional correction from the Object Belonging Checker is usually required. The velocity of the particles bounced from the ellipsoid is reversed with respect to the boundary velocity at the contact point.

__init__(name: str) → None
Parameters:name – name of the checker
class Mesh

Bases: _ymero.Bouncers.Bouncer

This bouncer will use the triangular mesh associated with objects to detect boundary crossings. Therefore it can only be created for Membrane and Rigid Object types of object vectors. Due to numerical precision, about \(1\) of \(10^5 - 10^6\) mesh crossings will not be detected, therefore it is advised to use that bouncer in conjunction with correction option provided by the Object Belonging Checker, see Object belonging checkers.

Note

In order to prevent numerical instabilities in case of light membrane particles, the new velocity of the bounced particles will be a random vector drawn from the Maxwell distibution of given temperature and added to the velocity of the mesh triangle at the collision point.

__init__(name: str, kbt: float = 0.5) → None
Parameters:
  • name – name of the bouncer
  • kbt – Maxwell distribution temperature defining post-collision velocity