5 #include <frechet/reachability/graph.h> 6 #include <boost/graph/transitive_closure.hpp> 7 #include <boost/graph/copy.hpp> 8 #include <boost/graph/graphviz.hpp> 11 : model(amodel), g(ag), i2v()
38 :
Graph(that.model,nullptr)
44 :
Graph(that.model,nullptr)
56 return boost::num_vertices(*g);
61 return boost::num_edges(*g);
66 Q_ASSERT(&model == &that.
model);
80 boost::graph_traits<graph_t>::edge_iterator ei, ei_end;
81 for (boost::tie(ei, ei_end) = boost::edges(*B.
g); ei != ei_end; ++ei)
86 int i1 = boost::get(v2i,v1);
87 int i2 = boost::get(v2i,v2);
89 this->add_edge(i1,i2);
110 Q_ASSERT(&model == &that.
model);
119 for( ; i1; i1=i1->
next(), i2=i2->
next())
126 add_edge(i1->index(), i->index());
134 auto f = i2v.find(i);
137 v = boost::add_vertex(
Index(i,i),*g);
138 i2v.insert(std::make_pair(i,v));
143 Q_ASSERT(boost::get(boost::get(boost::vertex_index,*g),v) == i);
153 boost::add_edge(v1,v2,*g);
159 boost::adjacency_list<>* tc =
new graph_t();
160 boost::transitive_closure (*g,*tc);
169 boost::transitive_closure (*g,*tc);
Graph & operator+=(const Graph &)
void swap(gpuword **A, gpuword **B)
boost::graph_traits< graph_t >::vertex_descriptor vertex_t
Graph::ptr transitiveClosure() const
model the mapping of free-space intervals to nodes in a frechet::reach::Graph.
void transitiveClosureInPlace()
boost::adjacency_list< boost::setS, boost::listS, boost::directedS, Index > graph_t
non-accesible. no interval is reachable from this one
The StructureIterator class.
void indexify(Structure &str, int i0) const
boundary interval in the reachability structure. Represents an interval on the boundary of the FreeSp...
Type type
reachability label
boost::property< boost::vertex_index_t, std::size_t, Name > Index
boost::shared_ptr< Graph > ptr
Graph(const GraphModel &model, graph_t *ag)
Represents a Reachability Graph. Vertices correspond to intervals in the reachability structure,...
void add_edge(int i, int j)
void refine(Structure &str, int i0) const
The Reachability Structure; maintains a list of intervals on the border of Free Space,...
boost::property_map< graph_t, boost::vertex_index_t >::type Vertex2IndexMap
Graph & operator=(const Graph &)