walberla::geometry::Ellipsoid Class Reference

Detailed Description

Class representing an Ellipsoid in 3D.

Implements body concept, i.e. a fastOverlapCheck and a contains() function, which can be used to initialize fields. For details about the body concept see BodyOverlapFunctions.h

#include <Ellipsoid.h>

Public Member Functions

 Ellipsoid (const Vector3< real_t > &midpoint, Vector3< real_t > axis1, Vector3< real_t > axis2, const Vector3< real_t > &radii)
 Ellipsoid constructor. More...
 
const AABB & boundingBox () const
 
bool contains (const Vector3< real_t > &point) const
 
const Vector3< real_tmidpoint () const
 
real_t maxRadius () const
 
real_t minRadius () const
 

Private Member Functions

void updateBoundingBox ()
 

Private Attributes

Vector3< real_tmidpoint_
 
Matrix3< real_tmat_
 
Matrix3< real_trotationMatrix_
 
Vector3< real_tradii_
 
real_t maxRadius_
 
real_t minRadius_
 
AABB boundingBox_
 

Constructor & Destructor Documentation

◆ Ellipsoid()

walberla::geometry::Ellipsoid::Ellipsoid ( const Vector3< real_t > &  midpoint,
Vector3< real_t axis1,
Vector3< real_t axis2,
const Vector3< real_t > &  radii 
)
explicit

Ellipsoid constructor.

Parameters
midpointmidpoint of the ellipsoid
axis1the first semi-axis of the ellipsoid ( associated with radius1 ) not required to be normalized, is normalized internally
axis2second semi-axis (must not be parallel to axis1 ) should ideally be perpendicular to axis1 if not perpendicular, axis2 is made perpendicular to axis1 using one Gram-Schmitt step. The third semi-axis is computed as cross-product of axis1 and axis2
radiithe length of the semi axes

Member Function Documentation

◆ boundingBox()

const AABB& walberla::geometry::Ellipsoid::boundingBox ( ) const
inline

◆ contains()

bool walberla::geometry::Ellipsoid::contains ( const Vector3< real_t > &  point) const

◆ maxRadius()

real_t walberla::geometry::Ellipsoid::maxRadius ( ) const
inline

◆ midpoint()

const Vector3<real_t> walberla::geometry::Ellipsoid::midpoint ( ) const
inline

◆ minRadius()

real_t walberla::geometry::Ellipsoid::minRadius ( ) const
inline

◆ updateBoundingBox()

void walberla::geometry::Ellipsoid::updateBoundingBox ( )
private

Member Data Documentation

◆ boundingBox_

AABB walberla::geometry::Ellipsoid::boundingBox_
private

◆ mat_

Matrix3<real_t> walberla::geometry::Ellipsoid::mat_
private

◆ maxRadius_

real_t walberla::geometry::Ellipsoid::maxRadius_
private

◆ midpoint_

Vector3<real_t> walberla::geometry::Ellipsoid::midpoint_
private

◆ minRadius_

real_t walberla::geometry::Ellipsoid::minRadius_
private

◆ radii_

Vector3<real_t> walberla::geometry::Ellipsoid::radii_
private

◆ rotationMatrix_

Matrix3<real_t> walberla::geometry::Ellipsoid::rotationMatrix_
private

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