From 4aa7225585cb17c61d90946b3e94ca5082cdbcaf Mon Sep 17 00:00:00 2001 From: dellaert Date: Mon, 25 May 2015 18:30:40 -0700 Subject: [PATCH] Get rid of g() and h() --- gtsam/base/Group.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/gtsam/base/Group.h b/gtsam/base/Group.h index a5ae6ba1c..f520b2ff7 100644 --- a/gtsam/base/Group.h +++ b/gtsam/base/Group.h @@ -133,9 +133,6 @@ class DirectProduct: public std::pair { BOOST_CONCEPT_ASSERT((IsGroup)); BOOST_CONCEPT_ASSERT((IsGroup)); - const G& g() const {return this->first;} - const H& h() const {return this->second;} - public: /// Default constructor yields identity DirectProduct():std::pair(traits::Identity(),traits::Identity()) {} @@ -144,10 +141,11 @@ public: DirectProduct(const G& g, const H& h):std::pair(g,h) {} Derived operator*(const Derived& other) const { - return Derived(traits::Compose(g(),other.g()), traits::Compose(h(),other.h())); + return Derived(traits::Compose(this->first, other.first), + traits::Compose(this->second, other.second)); } Derived inverse() const { - return Derived(g().inverse(), h().inverse()); + return Derived(this->first.inverse(), this->second.inverse()); } };