libmove3d-planners
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Friends Macros Groups Pages
EST.hpp
1 /*
2  * EST.hpp
3  *
4  * Created on: Sep 16, 2009
5  * Author: jmainpri
6  */
7 
8 #ifndef _EST_HPP_
9 #define _EST_HPP_
10 
11 #include "planner/Diffusion/TreePlanner.hpp"
12 #include <iostream>
13 
14 
19 {
20 public:
22  ESTExpansion(Graph * graph) : TreeExpansion(graph) {};
23 
25  virtual ~ESTExpansion() {};
26 
30  Node* getExpansionNode(std::vector<Node*>& nodes);
31 
35  std::tr1::shared_ptr<Configuration> getExpansionDirection(Node* expansionNode, Node* toComp);
36 
40  Node* expandProcessEST(Node* expansionNode, std::tr1::shared_ptr<Configuration> directionConfig,
41  unsigned& nbOfNodesAdded);
42 
46  void printAllNodes(std::vector<Node*>& nodes);
47 };
48 
49 
53 class EST: public TreePlanner
54 {
55 public:
57  EST(Robot * robot, Graph * graph) : TreePlanner(robot, graph) {
58  std::cout << "Construct the EST" << std::endl;
59  }
60 
62  virtual ~EST() { delete expansion; }
63 
68  virtual unsigned init();
69 
74  unsigned expandOneStep(Node * fromComp);
75 
76 private:
81  bool checkStopConditions();
82 
87  bool preConditions();
88 
94  confPtr_t sampleExpansionDirection(Node * directionNode);
95 
100  bool connectNodeToComp(Node * node, Node * compNode);
101 
103  void addNodeToSet(Node * node);
104 
105 private:
107  ESTExpansion * expansion;
108 
109  std::vector<Node *> sortedNodes;
110 };
111 
112 #endif
Expansion procedure of the tree planner.
Definition: TreePlanner.hpp:18
virtual ~ESTExpansion()
Destructor.
Definition: EST.hpp:25
Classe représentant un Node d'un Graph.
Definition: node.hpp:39
virtual unsigned init()
Initialize EST.
Definition: EST.cpp:168
virtual ~EST()
Destructor.
Definition: EST.hpp:62
Definition: TreePlanner.hpp:38
Definition: graph.hpp:28
This class holds a the robot represented by a kinematic chain.
Definition: robot.hpp:42
std::tr1::shared_ptr< Configuration > getExpansionDirection(Node *expansionNode, Node *toComp)
EST Special case.
Definition: EST.cpp:82
EST(Robot *robot, Graph *graph)
Constructor.
Definition: EST.hpp:57
Node * getExpansionNode(std::vector< Node * > &nodes)
EST Special case.
Definition: EST.cpp:30
ESTExpansion(Graph *graph)
Constructor.
Definition: EST.hpp:22
Expansion procedure of the Expansive Space Tree (EST) algorithm.
Definition: EST.hpp:18
The Expansive Space Tree (EST) algorithm.
Definition: EST.hpp:53
unsigned expandOneStep(Node *fromComp)
Perform a single expansion step of EST, growing the connected component to which the given node belon...
Definition: EST.cpp:191
void printAllNodes(std::vector< Node * > &nodes)
EST.
Node * expandProcessEST(Node *expansionNode, std::tr1::shared_ptr< Configuration > directionConfig, unsigned &nbOfNodesAdded)
EST Special case.
Definition: EST.cpp:93