OOFEM  2.4
OOFEM.org - Object Oriented Finite Element Solver
oofem::SpatialLocalizerInterface Class Reference

The spatial localizer element interface associated to spatial localizer. More...

#include <spatiallocalizer.h>

+ Inheritance diagram for oofem::SpatialLocalizerInterface:
+ Collaboration diagram for oofem::SpatialLocalizerInterface:

Public Member Functions

 SpatialLocalizerInterface (Element *element)
 
The element interface required by SpatialLocalizerInterface
virtual int SpatialLocalizerI_containsPoint (const FloatArray &coords)
 Checks if element contains specified coordinate. More...
 
int SpatialLocalizerI_BBoxContainsPoint (const FloatArray &coords)
 Creates a bounding box of the nodes and checks if it includes the given coordinate. More...
 
virtual void SpatialLocalizerI_giveBBox (FloatArray &bb0, FloatArray &bb1)
 Creates a bounding box of the nodes and checks if it includes the given coordinate. More...
 
virtual double SpatialLocalizerI_giveClosestPoint (FloatArray &lcoords, FloatArray &closest, const FloatArray &gcoords)
 Gives the closest point on the element. More...
 
- Public Member Functions inherited from oofem::Interface
 Interface ()
 Constructor. More...
 
virtual ~Interface ()
 
virtual const char * giveClassName () const =0
 

Private Attributes

Elementelement
 

Detailed Description

The spatial localizer element interface associated to spatial localizer.

Definition at line 59 of file spatiallocalizer.h.

Constructor & Destructor Documentation

oofem::SpatialLocalizerInterface::SpatialLocalizerInterface ( Element element)
inline

Definition at line 65 of file spatiallocalizer.h.

Member Function Documentation

int oofem::SpatialLocalizerInterface::SpatialLocalizerI_BBoxContainsPoint ( const FloatArray coords)

Creates a bounding box of the nodes and checks if it includes the given coordinate.

Parameters
coordsGlobal coordinate.
Returns
Nonzero if given element bounding box contains given point.

Definition at line 83 of file spatiallocalizer.C.

References oofem::FloatArray::at(), oofem::FloatArray::giveSize(), oofem::min(), and SpatialLocalizerI_giveBBox().

int oofem::SpatialLocalizerInterface::SpatialLocalizerI_containsPoint ( const FloatArray coords)
virtual

Checks if element contains specified coordinate.

Default implementation uses Element::computeLocalCoordinates.

Parameters
coordsGlobal coordinate.
Returns
Nonzero if given element contains given point.

Reimplemented in oofem::Tr_Warp.

Definition at line 48 of file spatiallocalizer.C.

References oofem::Element::computeLocalCoordinates(), and element.

void oofem::SpatialLocalizerInterface::SpatialLocalizerI_giveBBox ( FloatArray bb0,
FloatArray bb1 
)
virtual

Creates a bounding box of the nodes and checks if it includes the given coordinate.

Parameters
bb0Lower bounding box.
bb1Upper bounding box.

Reimplemented in oofem::TR_SHELL01, and oofem::TR_SHELL02.

Definition at line 55 of file spatiallocalizer.C.

References oofem::FloatArray::beMaxOf(), oofem::FloatArray::beMinOf(), element, oofem::Node::giveCoordinates(), oofem::Element::giveNode(), and oofem::Element::giveNumberOfNodes().

Referenced by oofem::OctreeSpatialLocalizer::initElementDataStructure(), and SpatialLocalizerI_BBoxContainsPoint().

double oofem::SpatialLocalizerInterface::SpatialLocalizerI_giveClosestPoint ( FloatArray lcoords,
FloatArray closest,
const FloatArray gcoords 
)
virtual

Gives the closest point on the element.

Default implementation uses the element interpolation.

Parameters
[out]lcoordsLocal coordinates of closest point within the element.
[out]closestGlobal coordinates of closest point within the element.
gcoordsGlobal coordinates.
Returns
Distance between answer and gcoords. Zero if gcoords is within the element, negative if point could not be found.

Definition at line 68 of file spatiallocalizer.C.

References oofem::FloatArray::distance(), element, oofem::Element::giveInterpolation(), oofem::FEInterpolation::global2local(), and oofem::FEInterpolation::local2global().

Referenced by oofem::DummySpatialLocalizer::giveElementClosestToPoint(), and oofem::OctreeSpatialLocalizer::giveElementClosestToPointWithinOctant().

Member Data Documentation

Element* oofem::SpatialLocalizerInterface::element
private

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

This page is part of the OOFEM documentation. Copyright (c) 2011 Borek Patzak
Project e-mail: info@oofem.org
Generated at Tue Jan 2 2018 20:07:41 for OOFEM by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2011