- 3.0.2 optimal control module.
PolicyHandler.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 
8 namespace ct {
9 namespace optcon {
10 
11 template <typename POLICY, size_t STATE_DIM, size_t CONTROL_DIM, typename SCALAR = double>
13 {
14 public:
15  EIGEN_MAKE_ALIGNED_OPERATOR_NEW
16 
17  PolicyHandler();
18 
19  virtual ~PolicyHandler();
20 
22 
35  virtual void designWarmStartingPolicy(const SCALAR& delay, const SCALAR& TimeHorizon, POLICY& policy);
36 
37 
39 
48  virtual void truncateSolutionFront(const SCALAR& delay, POLICY& policy, SCALAR& effectivelyTruncated);
49 
50 
52  void setPolicy(const POLICY& newPolicy);
53 
54 
55 protected:
56  POLICY initialPolicy_;
57 };
58 
59 } // namespace optcon
60 } // namespace ct
Definition: PolicyHandler.h:12
virtual void designWarmStartingPolicy(const SCALAR &delay, const SCALAR &TimeHorizon, POLICY &policy)
design a warm-starting policy for the optimal control problem solver
Definition: PolicyHandler-impl.h:22
EIGEN_MAKE_ALIGNED_OPERATOR_NEW PolicyHandler()
Definition: PolicyHandler-impl.h:12
POLICY initialPolicy_
Definition: PolicyHandler.h:56
CppAD::AD< CppAD::cg::CG< double > > SCALAR
virtual void truncateSolutionFront(const SCALAR &delay, POLICY &policy, SCALAR &effectivelyTruncated)
a method required for additional post-truncation.
Definition: PolicyHandler-impl.h:30
virtual ~PolicyHandler()
Definition: PolicyHandler-impl.h:17
void setPolicy(const POLICY &newPolicy)
set new policy to policy handler
Definition: PolicyHandler-impl.h:37