| 
									
										
										
										
											2010-07-13 05:34:03 +08:00
										 |  |  | /*
 | 
					
						
							|  |  |  |  * GaussianJunctionTree.h | 
					
						
							| 
									
										
										
										
											2010-07-14 06:03:18 +08:00
										 |  |  |  * Created on: Jul 12, 2010 | 
					
						
							|  |  |  |  * @author Kai Ni | 
					
						
							|  |  |  |  * @author Frank Dellaert | 
					
						
							|  |  |  |  * @brief: the Gaussian junction tree | 
					
						
							| 
									
										
										
										
											2010-07-13 05:34:03 +08:00
										 |  |  |  */ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #pragma once
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #include "JunctionTree.h"
 | 
					
						
							|  |  |  | #include "GaussianConditional.h"
 | 
					
						
							|  |  |  | #include "GaussianFactorGraph.h"
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | namespace gtsam { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 	/* ************************************************************************* */ | 
					
						
							|  |  |  | 	/**
 | 
					
						
							|  |  |  | 	 * GaussianJunctionTree that does the optimization | 
					
						
							|  |  |  | 	 */ | 
					
						
							| 
									
										
										
										
											2010-07-14 06:03:18 +08:00
										 |  |  | 	class GaussianJunctionTree: public JunctionTree<GaussianFactorGraph> { | 
					
						
							| 
									
										
										
										
											2010-07-13 05:34:03 +08:00
										 |  |  | 	public: | 
					
						
							| 
									
										
										
										
											2010-07-14 06:03:18 +08:00
										 |  |  | 		typedef JunctionTree<GaussianFactorGraph> Base; | 
					
						
							|  |  |  | 		typedef Base::sharedClique sharedClique; | 
					
						
							| 
									
										
										
										
											2010-07-13 05:34:03 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | 	protected: | 
					
						
							|  |  |  | 		// back-substitute in topological sort order (parents first)
 | 
					
						
							| 
									
										
										
										
											2010-07-14 06:03:18 +08:00
										 |  |  | 		void btreeBackSubstitue(BayesTree<GaussianConditional>::sharedClique current, VectorConfig& config); | 
					
						
							| 
									
										
										
										
											2010-07-13 05:34:03 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | 	public : | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 		GaussianJunctionTree() : Base() {} | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 		// constructor
 | 
					
						
							| 
									
										
										
										
											2010-07-14 06:03:18 +08:00
										 |  |  | 		GaussianJunctionTree(GaussianFactorGraph& fg, const Ordering& ordering) : Base(fg, ordering) {} | 
					
						
							| 
									
										
										
										
											2010-07-13 05:34:03 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | 		// optimize the linear graph
 | 
					
						
							|  |  |  | 		VectorConfig optimize(); | 
					
						
							|  |  |  | 	}; // GaussianJunctionTree
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | } // namespace gtsam
 |