Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
acado
code_generation
export_module.cpp
Go to the documentation of this file.
1
/*
2
* This file is part of ACADO Toolkit.
3
*
4
* ACADO Toolkit -- A Toolkit for Automatic Control and Dynamic Optimization.
5
* Copyright (C) 2008-2014 by Boris Houska, Hans Joachim Ferreau,
6
* Milan Vukov, Rien Quirynen, KU Leuven.
7
* Developed within the Optimization in Engineering Center (OPTEC)
8
* under supervision of Moritz Diehl. All rights reserved.
9
*
10
* ACADO Toolkit is free software; you can redistribute it and/or
11
* modify it under the terms of the GNU Lesser General Public
12
* License as published by the Free Software Foundation; either
13
* version 3 of the License, or (at your option) any later version.
14
*
15
* ACADO Toolkit is distributed in the hope that it will be useful,
16
* but WITHOUT ANY WARRANTY; without even the implied warranty of
17
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18
* Lesser General Public License for more details.
19
*
20
* You should have received a copy of the GNU Lesser General Public
21
* License along with ACADO Toolkit; if not, write to the Free Software
22
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
23
*
24
*/
25
26
27
34
#include <
acado/code_generation/export_module.hpp
>
35
#include <
acado/code_generation/integrators/integrator_export.hpp
>
36
37
BEGIN_NAMESPACE_ACADO
38
39
40
//
41
// PUBLIC MEMBER FUNCTIONS:
42
//
43
44
ExportModule::ExportModule
( ) :
UserInteraction
( )
45
{
46
setupOptions
( );
47
48
commonHeaderName
=
"acado.h"
;
49
}
50
51
52
ExportModule::~ExportModule
( )
53
{}
54
55
//
56
// PROTECTED MEMBER FUNCTIONS:
57
//
58
59
returnValue
ExportModule::setupOptions
( )
60
{
61
addOption
(
HESSIAN_APPROXIMATION
,
GAUSS_NEWTON
);
62
addOption
(
HESSIAN_REGULARIZATION
,
BLOCK_REG
);
63
addOption
(
CG_CONDENSED_HESSIAN_CHOLESKY
,
EXTERNAL
);
64
addOption
(
DISCRETIZATION_TYPE
,
MULTIPLE_SHOOTING
);
65
addOption
(
INTEGRATOR_TYPE
,
INT_RK4
);
66
addOption
(
DYNAMIC_SENSITIVITY
,
FORWARD
);
67
addOption
(
LINEAR_ALGEBRA_SOLVER
,
GAUSS_LU
);
68
addOption
(
UNROLL_LINEAR_SOLVER
,
false
);
69
addOption
(
NUM_INTEGRATOR_STEPS
, 30 );
70
addOption
(
MEASUREMENT_GRID
,
OFFLINE_GRID
);
71
addOption
(
INTEGRATOR_DEBUG_MODE
, 0 );
72
addOption
(
IMPLICIT_INTEGRATOR_MODE
,
IFTR
);
73
// addOption( LIFTED_INTEGRATOR_MODE, 1 );
74
addOption
(
LIFTED_GRADIENT_UPDATE
,
false
);
75
addOption
(
IMPLICIT_INTEGRATOR_NUM_ITS
, 5 );
76
addOption
(
IMPLICIT_INTEGRATOR_NUM_ITS_INIT
, 0 );
77
addOption
(
SPARSE_QP_SOLUTION
,
FULL_CONDENSING
);
78
addOption
(
CONDENSING_BLOCK_SIZE
, 0 );
79
addOption
(
FIX_INITIAL_STATE
,
true
);
80
addOption
(
QP_SOLVER
,
QP_QPOASES
);
81
addOption
(
MAX_NUM_QP_ITERATIONS
, -1 );
82
addOption
(
HOTSTART_QP
,
true
);
83
addOption
(
LEVENBERG_MARQUARDT
, 0.0 );
84
addOption
(
GENERATE_TEST_FILE
,
true
);
85
addOption
(
GENERATE_MAKE_FILE
,
true
);
86
addOption
(
GENERATE_SIMULINK_INTERFACE
,
false
);
87
addOption
(
GENERATE_MATLAB_INTERFACE
,
false
);
88
addOption
(
MEX_ITERATION_STEPS
, 1 );
89
addOption
(
MEX_VERBOSE
, 0 );
90
addOption
(
USE_SINGLE_PRECISION
,
false
);
91
addOption
(
PRINTLEVEL
,
MEDIUM
);
92
93
addOption
(
CG_USE_C99
,
NO
);
94
addOption
(
CG_USE_VARIABLE_WEIGHTING_MATRIX
,
NO
);
95
addOption
(
CG_COMPUTE_COVARIANCE_MATRIX
,
NO
);
96
addOption
(
CG_USE_OPENMP
,
NO
);
97
addOption
(
CG_HARDCODE_CONSTRAINT_VALUES
,
YES
);
98
addOption
(
CG_USE_ARRIVAL_COST
,
NO
);
99
100
addOption
(
CG_CONDENSED_HESSIAN_CHOLESKY
,
EXTERNAL
);
101
addOption
(
CG_FORCE_DIAGONAL_HESSIAN
,
NO
);
102
103
addOption
(
CG_MODULE_NAME
,
"acado"
);
104
addOption
(
CG_MODULE_PREFIX
,
"ACADO"
);
105
addOption
(
CG_EXPORT_FOLDER_NAME
,
"acado_export"
);
106
107
return
SUCCESSFUL_RETURN
;
108
}
109
110
CLOSE_NAMESPACE_ACADO
ExportModule::setupOptions
returnValue setupOptions()
Definition:
export_module.cpp:59
PRINTLEVEL
Definition:
acado_types.hpp:374
MEASUREMENT_GRID
Definition:
acado_types.hpp:398
MEDIUM
Definition:
acado_types.hpp:296
HESSIAN_REGULARIZATION
Definition:
acado_types.hpp:377
QP_SOLVER
Definition:
acado_types.hpp:386
export_module.hpp
SUCCESSFUL_RETURN
Definition:
acado_types.hpp:836
CG_MODULE_NAME
Definition:
acado_types.hpp:335
FIX_INITIAL_STATE
Definition:
acado_types.hpp:420
OFFLINE_GRID
Definition:
acado_types.hpp:273
HESSIAN_APPROXIMATION
Definition:
acado_types.hpp:376
CG_COMPUTE_COVARIANCE_MATRIX
Definition:
acado_types.hpp:342
BLOCK_REG
Definition:
acado_types.hpp:628
returnValue
Allows to pass back messages to the calling function.
Definition:
acado_types.hpp:1139
GAUSS_NEWTON
Definition:
acado_types.hpp:615
INT_RK4
Definition:
integrator_export_types.hpp:45
IMPLICIT_INTEGRATOR_MODE
Definition:
acado_types.hpp:344
MAX_NUM_QP_ITERATIONS
Definition:
acado_types.hpp:387
MEX_VERBOSE
Definition:
acado_types.hpp:357
QP_QPOASES
Definition:
acado_types.hpp:635
CLOSE_NAMESPACE_ACADO
#define CLOSE_NAMESPACE_ACADO
Definition:
acado_namespace_macros.hpp:58
GENERATE_SIMULINK_INTERFACE
Definition:
acado_types.hpp:423
DISCRETIZATION_TYPE
Definition:
acado_types.hpp:383
GENERATE_MATLAB_INTERFACE
Definition:
acado_types.hpp:424
GAUSS_LU
Definition:
acado_types.hpp:148
CG_USE_C99
Definition:
acado_types.hpp:341
ExportModule::commonHeaderName
std::string commonHeaderName
Definition:
export_module.hpp:135
SPARSE_QP_SOLUTION
Definition:
acado_types.hpp:410
DYNAMIC_SENSITIVITY
Definition:
acado_types.hpp:380
CG_USE_ARRIVAL_COST
Definition:
acado_types.hpp:338
YES
#define YES
Definition:
acado_types.hpp:51
USE_SINGLE_PRECISION
Definition:
acado_types.hpp:426
FORWARD
Definition:
integrator_export_types.hpp:67
NUM_INTEGRATOR_STEPS
Definition:
acado_types.hpp:354
CG_HARDCODE_CONSTRAINT_VALUES
Definition:
acado_types.hpp:343
CG_USE_VARIABLE_WEIGHTING_MATRIX
Definition:
acado_types.hpp:340
CG_MODULE_PREFIX
Definition:
acado_types.hpp:336
NO
#define NO
Definition:
acado_types.hpp:53
UNROLL_LINEAR_SOLVER
Definition:
acado_types.hpp:349
UserInteraction
Encapsulates all user interaction for setting options, logging data and plotting results.
Definition:
user_interaction.hpp:57
IFTR
Definition:
acado_types.hpp:160
LEVENBERG_MARQUARDT
Definition:
acado_types.hpp:373
CG_USE_OPENMP
Definition:
acado_types.hpp:339
IMPLICIT_INTEGRATOR_NUM_ITS
Definition:
acado_types.hpp:347
MULTIPLE_SHOOTING
Definition:
acado_types.hpp:203
GENERATE_TEST_FILE
Definition:
acado_types.hpp:421
FULL_CONDENSING
Definition:
acado_types.hpp:759
CONDENSING_BLOCK_SIZE
Definition:
acado_types.hpp:350
HOTSTART_QP
Definition:
acado_types.hpp:388
LINEAR_ALGEBRA_SOLVER
Definition:
acado_types.hpp:365
ExportModule::ExportModule
ExportModule()
Definition:
export_module.cpp:44
BEGIN_NAMESPACE_ACADO
#define BEGIN_NAMESPACE_ACADO
Definition:
acado_namespace_macros.hpp:57
IMPLICIT_INTEGRATOR_NUM_ITS_INIT
Definition:
acado_types.hpp:348
LIFTED_GRADIENT_UPDATE
Definition:
acado_types.hpp:346
CG_EXPORT_FOLDER_NAME
Definition:
acado_types.hpp:337
INTEGRATOR_DEBUG_MODE
Definition:
acado_types.hpp:351
ExportModule::~ExportModule
virtual ~ExportModule()
Definition:
export_module.cpp:52
MEX_ITERATION_STEPS
Definition:
acado_types.hpp:356
Options::addOption
returnValue addOption(OptionsName name, int value)
Definition:
options.cpp:301
CG_FORCE_DIAGONAL_HESSIAN
Definition:
acado_types.hpp:333
INTEGRATOR_TYPE
Definition:
acado_types.hpp:397
GENERATE_MAKE_FILE
Definition:
acado_types.hpp:422
CG_CONDENSED_HESSIAN_CHOLESKY
Definition:
acado_types.hpp:334
EXTERNAL
Definition:
acado_types.hpp:817
integrator_export.hpp
acado
Author(s): Milan Vukov, Rien Quirynen
autogenerated on Mon Jun 10 2019 12:34:34