Skip to content
Snippets Groups Projects
Commit 25cd3ff0 authored by Matti Pellika's avatar Matti Pellika
Browse files

prettier

parent 629fd5fb
No related branches found
No related tags found
No related merge requests found
......@@ -29,12 +29,6 @@ bool Less_Cell::operator()(const Cell* c1, const Cell* c2) const
return false;
}
bool Less_VertexNumIndex::operator()(const std::pair<MVertex*, int> v1,
const std::pair<MVertex*, int> v2) const
{
return (v1.first->getNum() < v2.first->getNum());
}
int Cell::_globalNum = 0;
Cell::Cell(MElement* element, int domain)
......@@ -65,15 +59,14 @@ Cell::Cell(Cell* parent, int i)
void Cell::_sortVertexIndices()
{
std::vector< std::pair<MVertex*, int> > si;
std::map<MVertex*, int, MVertexLessThanNum> si;
for(unsigned int i = 0; i < _v.size(); i++)
si.push_back( std::make_pair(_v[i], i) );
std::sort(si.begin(), si.end(), Less_VertexNumIndex());
si[_v[i]] = i;
for(unsigned int i = 0; i < si.size(); i++)
_si.push_back(si[i].second);
std::map<MVertex*, int, MVertexLessThanNum>::iterator it;
for(it = si.begin(); it != si.end(); it++)
_si.push_back(it->second);
}
inline int Cell::getSortedVertex(int vertex) const
......
......@@ -19,12 +19,6 @@ public:
bool operator()(const Cell* c1, const Cell* c2) const;
};
class Less_VertexNumIndex {
public:
bool operator()(const std::pair<MVertex*, int> v1,
const std::pair<MVertex*, int> v2) const;
};
// Class to save cell boundary orientation information
class BdInfo {
private:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment