46 #include <lifev/core/fem/DOFInterface3Dto2D.hpp> 56 void RemoveMultiple (
const std::list<ID>& listToTreat, std::list< std::pair<ID, ID> >& finalList )
59 std::list<ID> temporaryList ( listToTreat );
65 std::pair <
ID,
ID> p0 ( temporaryList.front() , counter );
66 finalList.push_back ( p0 );
69 for ( std::list<ID>::iterator it = temporaryList.begin() ; it != temporaryList.end() ; ++ it )
71 if ( ( *it ) != finalList.back().first )
75 std::pair <ID, ID> p ( ( *it ) , counter );
76 finalList.push_back ( p );
106 M_vertexPerFaceList.clear();
107 M_vertexList.clear();
112 out <<
"------------------------------" << std::endl;
113 out <<
"myDofInterface reference: " << M_interfaceFlag << std::endl;
114 out <<
"Number of face connections (M_faceList): " << M_faceList.size() << std::endl;
117 unsigned int count ( 0 ), lines ( 10 );
118 out <<
"\tList of connections between Faces: (global, local)";
119 for ( std::vector< std::pair<ID, ID> >::const_iterator i = M_faceList.begin(); i != M_faceList.end(); ++i )
121 if ( count++ % lines == 0 )
125 out <<
"(" << i->first <<
"," << i->second <<
")\t";
129 out <<
"Number of connections between Vertices (M_vertexList): " << M_vertexList.size() << std::endl;
132 unsigned int count ( 0 ), lines ( 10 );
133 out <<
"\tList of connections between Vertices: (global, local)";
134 for ( std::list< std::pair<ID, ID> >::const_iterator it = M_vertexList.begin(); it != M_vertexList.end(); ++it )
136 if ( count++ % lines == 0 )
140 out <<
"(" << it->first <<
"," << it->second <<
")\t";
147 out <<
"------------------------------" << std::endl;
158 ASSERT_PRE ( M_finalized,
"The face List should be finalised before being accessed" );
160 return M_faceList[ i ].first;
169 M_faceList = dofi.M_faceList;
170 M_vertexPerFaceList = dofi.M_vertexPerFaceList;
171 M_vertexList = dofi.M_vertexList;
172 M_localDofMap = dofi.M_localDofMap;
185 ASSERT_PRE ( M_finalized,
"The list of vertices must be finalized before accessing to the interface vertices." );
186 for ( std::list< std::pair<ID, ID> >::const_iterator it = M_vertexList.begin(); it != M_vertexList.end(); ++it )
188 if ( it->first == idpoint3D )
193 ERROR_MSG (
"There is no such 3D index of vertex in the M_vertexList." );
void setup(const DOFLocalPattern &refFE1, const DOF &dof1)
const DOFLocalPattern * M_refFE1
DOFLocalPattern object used in the mesh in which we want to make the computations.
const DOF * M_dof1
DOF object of the mesh in which we want to make the computations.
void updateInverseJacobian(const UInt &iQuadPt)
ID vertex3Dto2D(const ID &idpoint3D) const
Transforms the 3d index of a vertex into its 2d (interface) index.
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') ...
DOFLocalPattern - A class to store the "couplings" between the basis functions.
std::ostream & showMe(bool verbose=false, std::ostream &out=std::cout) const
output
DOFInterface3Dto2D(const DOFLocalPattern &refFE, const DOF &dof1)
Constructor for interfacing DOF of the same type (DOFLocalPattern)
void RemoveMultiple(const std::list< ID > &listToTreat, std::list< std::pair< ID, ID > > &finalList)
useful function to sort a list and remove multiple numbers.
DOFInterface3Dto2D & operator=(const DOFInterface3Dto2D &dofi)
Assignment operator (we have a vector of DOFInterface3Dto2D)
void clearLists()
removes all unuseful list (all except M_faceList). use it properly!
markerID_Type M_interfaceFlag
reference of the interface
uint32_type UInt
generic unsigned integer (used mainly for addressing)
bool M_finalized
true if the lists have been updated.