- 3.0.2 core module.
TestJacobian.h
Go to the documentation of this file.
1 /**********************************************************************************************************************
2 This file is part of the Control Toolbox (https://github.com/ethz-adrl/control-toolbox), copyright by ETH Zurich.
3 Licensed under the BSD-2 license (see LICENSE file in main directory)
4 **********************************************************************************************************************/
5 
6 #pragma once
7 
9 
10 namespace ct {
11 namespace core {
12 namespace generated {
13 
14 class TestJacobian : public core::Derivatives<3, 2, double>
15 {
16 public:
17  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
18 
19  typedef Eigen::Matrix<double, 2, 3> JAC_TYPE;
20  typedef Eigen::Matrix<double, 3, 1> X_TYPE;
21 
23  {
24  jac_.setZero();
25  v_.fill(0.0);
26  };
27 
28  TestJacobian(const TestJacobian& other)
29  {
30  jac_.setZero();
31  v_.fill(0.0);
32  }
33 
34  virtual ~TestJacobian(){};
35 
36  TestJacobian* clone() const override { return new TestJacobian(*this); }
37  JAC_TYPE jacobian(const Eigen::VectorXd& x_in) override;
38 
39 private:
40  JAC_TYPE jac_;
41  std::array<double, 0> v_;
42 };
43 
44 } // namespace generated
45 } // namespace core
46 } // namespace ct
Definition: TestJacobian.h:14
JAC_TYPE jacobian(const Eigen::VectorXd &x_in) override
Evaluates the jacobian with respect to the input.
Definition: TestJacobian.cpp:15
TestJacobian(const TestJacobian &other)
Definition: TestJacobian.h:28
General interface class for a Derivatives.
Definition: Derivatives.h:24
virtual ~TestJacobian()
Definition: TestJacobian.h:34
TestJacobian * clone() const override
deep copy for derived classes
Definition: TestJacobian.h:36
Eigen::Matrix< double, 3, 1 > X_TYPE
Definition: TestJacobian.h:20
TestJacobian()
Definition: TestJacobian.h:22
EIGEN_MAKE_ALIGNED_OPERATOR_NEW typedef Eigen::Matrix< double, 2, 3 > JAC_TYPE
Definition: TestJacobian.h:19