re-org code
parent
6aa47963e9
commit
422a4ae16d
|
|
@ -15,6 +15,13 @@ using namespace std;
|
|||
|
||||
namespace gtsam {
|
||||
|
||||
/* ************************************************************************* */
|
||||
Ordering::Ordering(const std::list<Symbol> & L):nVars_(0) {
|
||||
int i = 0;
|
||||
BOOST_FOREACH( const Symbol& s, L )
|
||||
insert(s, i++) ;
|
||||
}
|
||||
|
||||
/* ************************************************************************* */
|
||||
void Ordering::permuteWithInverse(const Permutation& inversePermutation) {
|
||||
BOOST_FOREACH(Ordering::value_type& key_order, *this) {
|
||||
|
|
|
|||
|
|
@ -38,10 +38,7 @@ public:
|
|||
typedef Map::const_iterator const_iterator;
|
||||
|
||||
Ordering() : nVars_(0) {}
|
||||
Ordering(const std::list<Symbol> & L):nVars_(0) {
|
||||
int i = 0;
|
||||
BOOST_FOREACH( const Symbol& s, L) insert(s, i++) ;
|
||||
}
|
||||
Ordering(const std::list<Symbol> & L) ;
|
||||
|
||||
/** One greater than the maximum ordering index. */
|
||||
Index nVars() const { return nVars_; }
|
||||
|
|
|
|||
Loading…
Reference in New Issue