KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
Public Member Functions | Static Public Attributes | List of all members
Kratos::NodeConfigureForNodeSearch Class Reference

Configuration file for nodes. More...

#include <node_configure_for_node_search.h>

Collaboration diagram for Kratos::NodeConfigureForNodeSearch:

Public Types

Type Definitions
typedef SpatialSearch SearchType
 
typedef SearchType::PointType PointType
 
typedef SearchType::NodesContainerType::ContainerType ContainerType
 
typedef SearchType::NodesContainerType NodesContainerType
 
typedef SearchType::NodeType NodeType
 
typedef ContainerType::value_type PointerType
 
typedef ContainerType::iterator IteratorType
 
typedef SearchType::NodesContainerType::ContainerType ResultContainerType
 
typedef ResultContainerType::iterator ResultIteratorType
 
typedef std::vector< double >::iterator DistanceIteratorType
 

Public Member Functions

 KRATOS_CLASS_POINTER_DEFINITION (NodeConfigureForNodeSearch)
 Pointer definition of NodeConfigureForNodeSearch. More...
 
Life Cycle
 NodeConfigureForNodeSearch ()
 Default constructor. More...
 
virtual ~NodeConfigureForNodeSearch ()
 Default destructor. More...
 

Static Public Attributes

static constexpr auto Epsilon = std::numeric_limits<double>::epsilon()
 Compile time definitions. More...
 
static constexpr auto Dimension = 3
 

Operations

virtual std::string Info () const
 Turn back information as a string. More...
 
virtual void PrintInfo (std::ostream &rOStream) const
 Print information about this object. More...
 
virtual void PrintData (std::ostream &rOStream) const
 Print object's data. More...
 
static void CalculateBoundingBox (const PointerType &rObject, PointType &rLowPoint, PointType &rHighPoint)
 Calculates the bounding box for the given object. More...
 
static void CalculateBoundingBox (const PointerType &rObject, PointType &rLowPoint, PointType &rHighPoint, const double Radius)
 Calculates the bounding box for the given object extended with a Radius. More...
 
static void CalculateCenter (const PointerType &rObject, PointType &rCenter)
 Calculates the Center of the object. More...
 
static bool Intersection (const PointerType &rObj_1, const PointerType &rObj_2, const double Radius)
 Tests the intersection of two objects extended with a given radius. More...
 
static bool IntersectionBox (const PointerType &rObject, const PointType &rLowPoint, const PointType &rHighPoint)
 Tests the intersection of one object with a boundingbox described by 'rLowPoint' and 'rHighPoint'. More...
 
static bool IntersectionBox (const PointerType &rObject, const PointType &rLowPoint, const PointType &rHighPoint, const double Radius)
 Tests the intersection of one object with a boundingbox described by 'rLowPoint' and 'rHighPoint'. More...
 
static void Distance (const PointerType &rObj_1, const PointerType &rObj_2, double &distance)
 Calculates the distance between two objects. More...
 

Detailed Description

Configuration file for nodes.

This class provides a configuration file for nodes to perform a node search depending on the euclidean distance between two nodes.

Author
Manuel Messmer

Member Typedef Documentation

◆ ContainerType

typedef SearchType::NodesContainerType::ContainerType Kratos::NodeConfigureForNodeSearch::ContainerType

◆ DistanceIteratorType

◆ IteratorType

typedef ContainerType::iterator Kratos::NodeConfigureForNodeSearch::IteratorType

◆ NodesContainerType

◆ NodeType

◆ PointerType

typedef ContainerType::value_type Kratos::NodeConfigureForNodeSearch::PointerType

◆ PointType

◆ ResultContainerType

◆ ResultIteratorType

typedef ResultContainerType::iterator Kratos::NodeConfigureForNodeSearch::ResultIteratorType

◆ SearchType

Constructor & Destructor Documentation

◆ NodeConfigureForNodeSearch()

Kratos::NodeConfigureForNodeSearch::NodeConfigureForNodeSearch ( )
inline

Default constructor.

◆ ~NodeConfigureForNodeSearch()

virtual Kratos::NodeConfigureForNodeSearch::~NodeConfigureForNodeSearch ( )
inlinevirtual

Default destructor.

Member Function Documentation

◆ CalculateBoundingBox() [1/2]

static void Kratos::NodeConfigureForNodeSearch::CalculateBoundingBox ( const PointerType rObject,
PointType rLowPoint,
PointType rHighPoint 
)
inlinestatic

Calculates the bounding box for the given object.

For this configuation file, the bounding box is equal to the point given in 'rObject'.

Parameters
rObjectPoint for which the bounding box will be calculated.
rLowPointLower point of the boundingbox.
rHighPointHigher point of the boundingbox.

◆ CalculateBoundingBox() [2/2]

static void Kratos::NodeConfigureForNodeSearch::CalculateBoundingBox ( const PointerType rObject,
PointType rLowPoint,
PointType rHighPoint,
const double  Radius 
)
inlinestatic

Calculates the bounding box for the given object extended with a Radius.

For this configuation file, the bounding box is equal to the point given in 'rObject' + - a radius.

Parameters
rObjectPoint for which the bounding box will be calculated.
rLowPointLower point of the boundingbox.
rHighPointHigher point of the boundingbox.
RadiusThe extension radius to be applied to the boundingbox.

◆ CalculateCenter()

static void Kratos::NodeConfigureForNodeSearch::CalculateCenter ( const PointerType rObject,
PointType rCenter 
)
inlinestatic

Calculates the Center of the object.

Parameters
rObjectPoint for which the bounding box will be calculated.
rCenterThe center point of the object.

◆ Distance()

static void Kratos::NodeConfigureForNodeSearch::Distance ( const PointerType rObj_1,
const PointerType rObj_2,
double distance 
)
inlinestatic

Calculates the distance between two objects.

Parameters
rObj_1First point.
rObj_2Second point
distanceThe euclidean distance between 'rObj_1' and 'rObj_2'.

◆ Info()

virtual std::string Kratos::NodeConfigureForNodeSearch::Info ( ) const
inlinevirtual

Turn back information as a string.

◆ Intersection()

static bool Kratos::NodeConfigureForNodeSearch::Intersection ( const PointerType rObj_1,
const PointerType rObj_2,
const double  Radius 
)
inlinestatic

Tests the intersection of two objects extended with a given radius.

For this configuation file, tests if euclidean distance between the two nodes is smaller than the provided 'Radius' within an Epsilon tolerance range.

Parameters
rObj_1First point of the test.
rObj_2Second point of the test.
RadiusThe extension radius to be applied in the intersection.
Returns
Boolean indicating the result of the intersection test.

◆ IntersectionBox() [1/2]

static bool Kratos::NodeConfigureForNodeSearch::IntersectionBox ( const PointerType rObject,
const PointType rLowPoint,
const PointType rHighPoint 
)
inlinestatic

Tests the intersection of one object with a boundingbox described by 'rLowPoint' and 'rHighPoint'.

For this configuation file, tests if one point is inside the boundingbox described by 'rLowPoint' and 'rHighPoint' within an Epsilon tolerance range.

Parameters
rObjectPoint of the tests.
rLowPointLower point of the boundingbox.
rHighPointHigher point of the boundingbox.
Returns
Boolean indicating the result of the intersection test.

◆ IntersectionBox() [2/2]

static bool Kratos::NodeConfigureForNodeSearch::IntersectionBox ( const PointerType rObject,
const PointType rLowPoint,
const PointType rHighPoint,
const double  Radius 
)
inlinestatic

Tests the intersection of one object with a boundingbox described by 'rLowPoint' and 'rHighPoint'.

For this configuation file, tests if one point extended by radius is inside the boundingbox described by 'rLowPoint' and 'rHighPoint' within an Epsilon tolerance range.

Parameters
rObjectPoint of the tests.
rLowPointLower point of the boundingbox.
rHighPointHigher point of the boundingbox.
RadiusThe extension radius to be applied in the intersection.
Returns
Boolean indicating the result of the intersection test.

◆ KRATOS_CLASS_POINTER_DEFINITION()

Kratos::NodeConfigureForNodeSearch::KRATOS_CLASS_POINTER_DEFINITION ( NodeConfigureForNodeSearch  )

Pointer definition of NodeConfigureForNodeSearch.

◆ PrintData()

virtual void Kratos::NodeConfigureForNodeSearch::PrintData ( std::ostream &  rOStream) const
inlinevirtual

Print object's data.

◆ PrintInfo()

virtual void Kratos::NodeConfigureForNodeSearch::PrintInfo ( std::ostream &  rOStream) const
inlinevirtual

Print information about this object.

Member Data Documentation

◆ Dimension

constexpr auto Kratos::NodeConfigureForNodeSearch::Dimension = 3
staticconstexpr

◆ Epsilon

constexpr auto Kratos::NodeConfigureForNodeSearch::Epsilon = std::numeric_limits<double>::epsilon()
staticconstexpr

Compile time definitions.

Parameters
EpsilonError tolerance for comparison operations with doubles
DimensionDimension of the problem. Fixed to 3.

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