Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
ElmerCSC
GitHub Repository: ElmerCSC/elmerfem
Path: blob/devel/meshgen2d/src/include/PQ.h
3203 views
1
#if !defined( MESH_PQ_H )
2
#define MESH_PQ_H
3
4
#include <list>
5
#include "Vertex.h"
6
7
8
#include <vector>
9
class pq
10
{
11
public:
12
pq(int chunk = 1024);
13
int size();
14
Vertex *first();
15
16
void insert( Vertex *vtx );
17
void removeRelevants( std::list< Vertex* >& vl );
18
void remove( Vertex *vtx );
19
20
void debug();
21
22
private:
23
void upheap( const int p );
24
void downheap( const int p );
25
void pq_reserve(int sz);
26
27
Vertex** store;
28
int last;
29
int pq_size;
30
};
31
32
#endif /* MESH_PQ_H */
33
34