hpp-constraints  4.11.0
Definition of basic geometric constraints for motion planning
explicit.hh
Go to the documentation of this file.
1 // Copyright (c) 2015, LAAS-CNRS
2 // Authors: Florent Lamiraux
3 //
4 // This file is part of hpp-constraints.
5 // hpp-constraints is free software: you can redistribute it
6 // and/or modify it under the terms of the GNU Lesser General Public
7 // License as published by the Free Software Foundation, either version
8 // 3 of the License, or (at your option) any later version.
9 //
10 // hpp-constraints is distributed in the hope that it will be
11 // useful, but WITHOUT ANY WARRANTY; without even the implied warranty
12 // of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 // General Lesser Public License for more details. You should have
14 // received a copy of the GNU Lesser General Public License along with
15 // hpp-constraints. If not, see <http://www.gnu.org/licenses/>.
16 
17 #ifndef HPP_CONSTRAINTS_EXPLICIT_HH
18 # define HPP_CONSTRAINTS_EXPLICIT_HH
19 
21 
22 namespace hpp {
23  namespace constraints {
26 
119  {
120  public:
122  virtual ImplicitPtr_t copy () const;
123 
141  static ExplicitPtr_t create
142  (const LiegroupSpacePtr_t& configSpace,
143  const DifferentiableFunctionPtr_t& function,
144  const segments_t& inputConf,
145  const segments_t& outputConf,
146  const segments_t& inputVelocity,
147  const segments_t& outputVelocity,
148  const ComparisonTypes_t& comp = ComparisonTypes_t(),
149  std::vector<bool> mask = std::vector<bool>());
150 
152  static ExplicitPtr_t createCopy (const ExplicitPtr_t& other);
153 
157  {
158  return inputToOutput_;
159  }
160 
162  const segments_t& outputConf () const
163  {
164  return outputConf_;
165  }
167  const segments_t& outputVelocity () const
168  {
169  return outputVelocity_;
170  }
172  const segments_t& inputConf () const
173  {
174  return inputConf_;
175  }
177  const segments_t& inputVelocity () const
178  {
179  return inputVelocity_;
180  }
189  virtual void outputValue(LiegroupElementRef result, vectorIn_t qin,
190  LiegroupElementConstRef rhs) const;
191 
202  virtual void jacobianOutputValue(vectorIn_t qin, LiegroupElementConstRef
203  f_value, LiegroupElementConstRef rhs,
204  matrixOut_t jacobian) const;
205  protected:
223  Explicit
224  (const LiegroupSpacePtr_t& configSpace,
225  const DifferentiableFunctionPtr_t& function,
226  const segments_t& inputConf,
227  const segments_t& outputConf,
228  const segments_t& inputVelocity,
229  const segments_t& outputVelocity,
230  const ComparisonTypes_t& comp,
231  std::vector<bool> mask);
232 
239  Explicit
240  (const DifferentiableFunctionPtr_t& implicitFunction,
241  const DifferentiableFunctionPtr_t& function,
242  const segments_t& inputConf,
243  const segments_t& outputConf,
244  const segments_t& inputVelocity,
245  const segments_t& outputVelocity,
246  const ComparisonTypes_t& comp,
247  std::vector<bool> mask);
248 
250  Explicit (const Explicit& other);
251 
252  // Store weak pointer to itself
253  void init (const ExplicitWkPtr_t& weak);
254  protected:
255  // Relation between input and output configuration variables
261 
262  Explicit() {}
263  private:
264  ExplicitWkPtr_t weak_;
265 
266  HPP_SERIALIZABLE();
267  }; // class Explicit
269  } // namespace constraints
270 } // namespace hpp
271 
272 BOOST_CLASS_EXPORT_KEY(hpp::constraints::Explicit)
273 
274 #endif // HPP_CONSTRAINTS_EXPLICIT_HH
segments_t inputConf_
Definition: explicit.hh:257
pinocchio::vectorIn_t vectorIn_t
Definition: fwd.hh:48
DifferentiableFunctionPtr_t inputToOutput_
Definition: explicit.hh:256
const segments_t & outputVelocity() const
Get output degrees of freedom.
Definition: explicit.hh:167
Definition: active-set-differentiable-function.hh:24
pinocchio::LiegroupSpacePtr_t LiegroupSpacePtr_t
Definition: fwd.hh:57
pinocchio::LiegroupElementConstRef LiegroupElementConstRef
Definition: fwd.hh:55
std::vector< segment_t > segments_t
Definition: fwd.hh:72
Definition: explicit.hh:118
const segments_t & inputConf() const
Get input configuration variables.
Definition: explicit.hh:172
std::vector< ComparisonType > ComparisonTypes_t
Definition: fwd.hh:176
shared_ptr< Explicit > ExplicitPtr_t
Definition: fwd.hh:179
segments_t outputVelocity_
Definition: explicit.hh:260
DifferentiableFunctionPtr_t explicitFunction() const
Definition: explicit.hh:156
const segments_t & inputVelocity() const
Get input degrees of freedom.
Definition: explicit.hh:177
shared_ptr< DifferentiableFunction > DifferentiableFunctionPtr_t
Definition: fwd.hh:101
#define HPP_CONSTRAINTS_DLLAPI
Definition: config.hh:64
pinocchio::LiegroupElementRef LiegroupElementRef
Definition: fwd.hh:54
Explicit()
Definition: explicit.hh:262
Eigen::Ref< matrix_t > matrixOut_t
Definition: fwd.hh:46
const segments_t & outputConf() const
Get output configuration variables.
Definition: explicit.hh:162
segments_t outputConf_
Definition: explicit.hh:258
shared_ptr< Implicit > ImplicitPtr_t
Definition: fwd.hh:163
Definition: implicit.hh:114
segments_t inputVelocity_
Definition: explicit.hh:259