LifeV
DOFInterface3Dto2D Class Reference

#include <DOFInterface3Dto2D.hpp>

+ Inheritance diagram for DOFInterface3Dto2D:
+ Collaboration diagram for DOFInterface3Dto2D:

Private Attributes

markerID_Type M_interfaceFlag
 reference of the interface More...
 
const DOFLocalPatternM_refFE1
 DOFLocalPattern object used in the mesh in which we want to make the computations. More...
 
const DOFM_dof1
 DOF object of the mesh in which we want to make the computations. More...
 
std::vector< std::pair< ID, ID > > M_faceList
 
std::list< IDM_vertexPerFaceList
 
std::list< std::pair< ID, ID > > M_vertexList
 
bool M_finalized
 true if the lists have been updated. More...
 

Constructor & Destructor

 DOFInterface3Dto2D ()
 default constructor More...
 
 DOFInterface3Dto2D (const DOFLocalPattern &refFE, const DOF &dof1)
 Constructor for interfacing DOF of the same type (DOFLocalPattern) More...
 

Methods

void setup (const DOFLocalPattern &refFE1, const DOF &dof1)
 
template<typename MeshType >
void update (const MeshType &mesh1, const markerID_Type &flag1)
 This method builds the DOF connections at the interface. More...
 
template<typename MeshType >
void generate2DMesh (std::string fname, const MeshType &mesh1) const
 Creates an Inria medit type mesh for the interface (pseudo 3D) More...
 
void clearLists ()
 removes all unuseful list (all except M_faceList). use it properly! More...
 
std::ostream & showMe (bool verbose=false, std::ostream &out=std::cout) const
 output More...
 

Operators

ID operator[] (const UInt &i) const
 Returns the identity of the i-th elements in the (finalised) face list (counting from 0 ' a la C') More...
 
DOFInterface3Dto2Doperator= (const DOFInterface3Dto2D &dofi)
 Assignment operator (we have a vector of DOFInterface3Dto2D) More...
 

Get Methods

const markerID_TypeinterfaceFlag () const
 Returns the reference of the interface. More...
 
const bool & finalized () const
 true if the lists have been updated. More...
 

Private Methods

ID vertex3Dto2D (const ID &idpoint3D) const
 Transforms the 3d index of a vertex into its 2d (interface) index. More...
 
template<typename MeshType >
void updateFaceConnections (const MeshType &mesh1, const markerID_Type &flag1)
 This method builds the connections between faces at the interface (M_faceList container) More...
 
template<typename MeshType >
void updateVertices (const MeshType &mesh1)
 This method builds the list of vertices at the interface (M_vertexList container) More...
 
template<typename MeshType >
void updateDofConnections (const MeshType &mesh1)
 This method builds the connections between DOF at the interface (_locDof container) More...
 

Additional Inherited Members

- Public Member Functions inherited from DOFInterface
 DOFInterface ()
 Default Constructor. More...
 
virtual ~DOFInterface ()
 Virtual Destructor. More...
 
ID getInterfaceDof (const ID &i) const
 This method returns the corresponding dof number of the mesh2 at the interface for a specific dof number at the interface in mesh1. More...
 
bool isMyInterfaceDof (const ID &i) const
 This method says whether a specific dof number at the interface in mesh1 is on this processor. More...
 
std::ostream & showMe (bool verbose=false, std::ostream &out=std::cout) const
 output More...
 
void buildInverse (const DOFInterface &dofBase)
 Makes this DOFInterface to be the inverse map as the one defined by dofBase. More...
 
void set (const ID &key, const ID &value)
 Set value to be associated to key. More...
 
size_t nbInterfaceDof () const
 This method returns the number of dof that live on the interface. More...
 
const std::map< ID, ID > & localDofMap ()
 Return the correspondance map. More...
 
- Protected Attributes inherited from DOFInterface
std::map< ID, IDM_localDofMap
 STL map container which holds the connections between DOF at the interface. More...
 

Detailed Description

Base class which holds the connections of the dof between a 3D mesh and its 2D interface

The connections may be built by calling the update method.

Definition at line 67 of file DOFInterface3Dto2D.hpp.

Constructor & Destructor Documentation

◆ DOFInterface3Dto2D() [1/2]

DOFInterface3Dto2D ( )
inline

default constructor

Definition at line 76 of file DOFInterface3Dto2D.hpp.

◆ DOFInterface3Dto2D() [2/2]

DOFInterface3Dto2D ( const DOFLocalPattern refFE,
const DOF dof1 
)

Constructor for interfacing DOF of the same type (DOFLocalPattern)

Parameters
refFethe part of the reference FE that contains the dof patterns (nbDofPerEdge...)
dof1the DOF object of the mesh in which we want to make the computations

Definition at line 85 of file DOFInterface3Dto2D.cpp.

Member Function Documentation

◆ setup()

void setup ( const DOFLocalPattern refFE1,
const DOF dof1 
)

Definition at line 96 of file DOFInterface3Dto2D.cpp.

◆ update()

void update ( const MeshType mesh1,
const markerID_Type flag1 
)

This method builds the DOF connections at the interface.

Parameters
mesh1the mesh in which we want to make the computations
flag1the marker of the interface in the mesh1

the lists are updated

Definition at line 244 of file DOFInterface3Dto2D.hpp.

◆ generate2DMesh()

void generate2DMesh ( std::string  fname,
const MeshType mesh1 
) const

Creates an Inria medit type mesh for the interface (pseudo 3D)

Write the 2D Inria mesh of the interface referenced by the number M_interfaceFlag.

It uses a inria "me.hpp" format. (for medit)

You should have filled the lists of vertices and faces before. (Call update once previously).

Write the coordinates of the vertices

Write the face table

Definition at line 265 of file DOFInterface3Dto2D.hpp.

◆ clearLists()

void clearLists ( )

removes all unuseful list (all except M_faceList). use it properly!

Definition at line 104 of file DOFInterface3Dto2D.cpp.

◆ showMe()

std::ostream & showMe ( bool  verbose = false,
std::ostream &  out = std::cout 
) const

output

print M_locDofMap

Definition at line 110 of file DOFInterface3Dto2D.cpp.

+ Here is the caller graph for this function:

◆ operator[]()

ID operator[] ( const UInt i) const

Returns the identity of the i-th elements in the (finalised) face list (counting from 0 ' a la C')

Definition at line 156 of file DOFInterface3Dto2D.cpp.

◆ operator=()

DOFInterface3Dto2D & operator= ( const DOFInterface3Dto2D dofi)

Assignment operator (we have a vector of DOFInterface3Dto2D)

Definition at line 164 of file DOFInterface3Dto2D.cpp.

◆ interfaceFlag()

const markerID_Type& interfaceFlag ( ) const
inline

Returns the reference of the interface.

Definition at line 142 of file DOFInterface3Dto2D.hpp.

◆ finalized()

const bool& finalized ( ) const
inline

true if the lists have been updated.

Definition at line 148 of file DOFInterface3Dto2D.hpp.

◆ vertex3Dto2D()

ID vertex3Dto2D ( const ID idpoint3D) const
private

Transforms the 3d index of a vertex into its 2d (interface) index.

This is a simple algorithm... Find out something better some day...?

Definition at line 183 of file DOFInterface3Dto2D.cpp.

◆ updateFaceConnections()

void updateFaceConnections ( const MeshType mesh1,
const markerID_Type flag1 
)
private

This method builds the connections between faces at the interface (M_faceList container)

Parameters
mesh1the mesh in which we want to make the computations
flag1the marker of the interface in the mesh1

Face on the interface counter

Loop on boundary faces on mesh1

The face marker

Is the face on the interface?

local face number

Definition at line 333 of file DOFInterface3Dto2D.hpp.

◆ updateVertices()

void updateVertices ( const MeshType mesh1)
private

This method builds the list of vertices at the interface (M_vertexList container)

Parameters
mesh1the mesh in which we want to make the computations

Definition at line 366 of file DOFInterface3Dto2D.hpp.

◆ updateDofConnections()

void updateDofConnections ( const MeshType mesh1)
private

This method builds the connections between DOF at the interface (_locDof container)

Parameters
mesh1the mesh in which we want to make the computations
dof1the DOF object of the mesh in which we want to make the computations

May be : invert the 2 ??

local DOF (total dof on the interface)

local DOF (total dof on the interface)

local DOF (total dof on the interface)

Definition at line 391 of file DOFInterface3Dto2D.hpp.

Field Documentation

◆ M_interfaceFlag

markerID_Type M_interfaceFlag
private

reference of the interface

Definition at line 192 of file DOFInterface3Dto2D.hpp.

◆ M_refFE1

const DOFLocalPattern* M_refFE1
private

DOFLocalPattern object used in the mesh in which we want to make the computations.

Definition at line 195 of file DOFInterface3Dto2D.hpp.

◆ M_dof1

const DOF* M_dof1
private

DOF object of the mesh in which we want to make the computations.

Definition at line 198 of file DOFInterface3Dto2D.hpp.

◆ M_faceList

std::vector< std::pair<ID, ID> > M_faceList
private

STL list which holds the connections between faces at the interface -> first : global (3D) face number -> second : interface (2D) face number

The name has changed : it was _elc before. (V.M.)

Definition at line 206 of file DOFInterface3Dto2D.hpp.

◆ M_vertexPerFaceList

std::list<ID> M_vertexPerFaceList
private

Auxiliary STL list which holds the connections between vertices at the interface (vertices appear more than once. (Mathematically, it is a family)) Empty after calling update

Definition at line 212 of file DOFInterface3Dto2D.hpp.

◆ M_vertexList

std::list< std::pair<ID, ID> > M_vertexList
private

STL list which holds the connections between vertices at the interface -> first : global (3D) vertex number -> second : interface (2D) vertex number

Definition at line 218 of file DOFInterface3Dto2D.hpp.

◆ M_finalized

bool M_finalized
private

true if the lists have been updated.

Definition at line 221 of file DOFInterface3Dto2D.hpp.


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