hpp-constraints 6.0.0
Definition of basic geometric constraints for motion planning
Loading...
Searching...
No Matches
explicit.hh
Go to the documentation of this file.
1// Copyright (c) 2015, LAAS-CNRS
2// Authors: Florent Lamiraux
3//
4
5// Redistribution and use in source and binary forms, with or without
6// modification, are permitted provided that the following conditions are
7// met:
8//
9// 1. Redistributions of source code must retain the above copyright
10// notice, this list of conditions and the following disclaimer.
11//
12// 2. Redistributions in binary form must reproduce the above copyright
13// notice, this list of conditions and the following disclaimer in the
14// documentation and/or other materials provided with the distribution.
15//
16// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
18// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
19// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
20// HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
21// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
22// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
27// DAMAGE.
28
29#ifndef HPP_CONSTRAINTS_EXPLICIT_HH
30#define HPP_CONSTRAINTS_EXPLICIT_HH
31
33
34namespace hpp {
35namespace constraints {
38
133 public:
135 virtual ImplicitPtr_t copy() const;
136
155 const LiegroupSpacePtr_t& configSpace,
156 const DifferentiableFunctionPtr_t& function, const segments_t& inputConf,
157 const segments_t& outputConf, const segments_t& inputVelocity,
158 const segments_t& outputVelocity,
159 const ComparisonTypes_t& comp = ComparisonTypes_t(),
160 std::vector<bool> mask = std::vector<bool>());
161
164
168 return inputToOutput_;
169 }
170
172 const segments_t& outputConf() const { return outputConf_; }
174 const segments_t& outputVelocity() const { return outputVelocity_; }
176 const segments_t& inputConf() const { return inputConf_; }
178 const segments_t& inputVelocity() const { return inputVelocity_; }
187 virtual void outputValue(LiegroupElementRef result, vectorIn_t qin,
188 LiegroupElementConstRef rhs) const;
189
203 matrixOut_t jacobian) const;
204
205 protected:
223 Explicit(const LiegroupSpacePtr_t& configSpace,
224 const DifferentiableFunctionPtr_t& function,
225 const segments_t& inputConf, const segments_t& outputConf,
226 const segments_t& inputVelocity, const segments_t& outputVelocity,
227 const ComparisonTypes_t& comp, std::vector<bool> mask);
228
238 Explicit(const DifferentiableFunctionPtr_t& implicitFunction,
239 const DifferentiableFunctionPtr_t& function,
240 const segments_t& inputConf, const segments_t& outputConf,
241 const segments_t& inputVelocity, const segments_t& outputVelocity,
242 const ComparisonTypes_t& comp, std::vector<bool> mask);
243
245 Explicit(const Explicit& other);
246
247 bool isEqual(const Implicit& other, bool swapAndTest) const;
248
249 // Store weak pointer to itself
250 void init(const ExplicitWkPtr_t& weak);
251
252 protected:
253 // Relation between input and output configuration variables
259
261
262 private:
263 ExplicitWkPtr_t weak_;
264
265 HPP_SERIALIZABLE();
266}; // class Explicit
268} // namespace constraints
269} // namespace hpp
270
271BOOST_CLASS_EXPORT_KEY(hpp::constraints::Explicit)
272
273#endif // HPP_CONSTRAINTS_EXPLICIT_HH
Definition explicit.hh:132
Explicit()
Definition explicit.hh:260
bool isEqual(const Implicit &other, bool swapAndTest) const
segments_t inputVelocity_
Definition explicit.hh:257
Explicit(const DifferentiableFunctionPtr_t &implicitFunction, const DifferentiableFunctionPtr_t &function, const segments_t &inputConf, const segments_t &outputConf, const segments_t &inputVelocity, const segments_t &outputVelocity, const ComparisonTypes_t &comp, std::vector< bool > mask)
(const LiegroupSpacePtr_t&, constDifferentiableFunctionPtr_t&, const segments_t& inputConf,...
const segments_t & inputConf() const
Get input configuration variables.
Definition explicit.hh:176
const segments_t & outputConf() const
Get output configuration variables.
Definition explicit.hh:172
Explicit(const Explicit &other)
Copy constructor.
Explicit(const LiegroupSpacePtr_t &configSpace, const DifferentiableFunctionPtr_t &function, const segments_t &inputConf, const segments_t &outputConf, const segments_t &inputVelocity, const segments_t &outputVelocity, const ComparisonTypes_t &comp, std::vector< bool > mask)
segments_t outputVelocity_
Definition explicit.hh:258
virtual ImplicitPtr_t copy() const
Copy object and return shared pointer to copy.
const segments_t & inputVelocity() const
Get input degrees of freedom.
Definition explicit.hh:178
segments_t inputConf_
Definition explicit.hh:255
virtual void jacobianOutputValue(vectorIn_t qin, LiegroupElementConstRef g_value, LiegroupElementConstRef rhs, matrixOut_t jacobian) const
DifferentiableFunctionPtr_t explicitFunction() const
Definition explicit.hh:167
DifferentiableFunctionPtr_t inputToOutput_
Definition explicit.hh:254
static ExplicitPtr_t create(const LiegroupSpacePtr_t &configSpace, const DifferentiableFunctionPtr_t &function, const segments_t &inputConf, const segments_t &outputConf, const segments_t &inputVelocity, const segments_t &outputVelocity, const ComparisonTypes_t &comp=ComparisonTypes_t(), std::vector< bool > mask=std::vector< bool >())
virtual void outputValue(LiegroupElementRef result, vectorIn_t qin, LiegroupElementConstRef rhs) const
static ExplicitPtr_t createCopy(const ExplicitPtr_t &other)
Create a copy and return shared pointer.
const segments_t & outputVelocity() const
Get output degrees of freedom.
Definition explicit.hh:174
segments_t outputConf_
Definition explicit.hh:256
void init(const ExplicitWkPtr_t &weak)
Definition implicit.hh:119
#define HPP_CONSTRAINTS_DLLAPI
Definition config.hh:88
std::vector< ComparisonType > ComparisonTypes_t
Definition fwd.hh:180
shared_ptr< Explicit > ExplicitPtr_t
Definition fwd.hh:183
pinocchio::LiegroupSpacePtr_t LiegroupSpacePtr_t
Definition fwd.hh:69
shared_ptr< DifferentiableFunction > DifferentiableFunctionPtr_t
Definition fwd.hh:113
shared_ptr< Implicit > ImplicitPtr_t
Definition fwd.hh:173
pinocchio::vectorIn_t vectorIn_t
Definition fwd.hh:60
Eigen::Ref< matrix_t > matrixOut_t
Definition fwd.hh:58
std::vector< segment_t > segments_t
Definition fwd.hh:84
pinocchio::LiegroupElementConstRef LiegroupElementConstRef
Definition fwd.hh:67
pinocchio::LiegroupElementRef LiegroupElementRef
Definition fwd.hh:66
Definition active-set-differentiable-function.hh:36