gtsam
Loading...
Searching...
No Matches
LPInitSolver.h
Go to the documentation of this file.
1/* ----------------------------------------------------------------------------
2
3 * GTSAM Copyright 2010, Georgia Tech Research Corporation,
4 * Atlanta, Georgia 30332-0415
5 * All Rights Reserved
6 * Authors: Frank Dellaert, et al. (see THANKS for the full author list)
7
8 * See LICENSE for the license information
9
10 * -------------------------------------------------------------------------- */
11
19
20#pragma once
21
22#include <gtsam/config.h>
23
24#ifdef GTSAM_ALLOW_DEPRECATED_SINCE_V43
25
27#include <gtsam_unstable/dllexport.h>
29
30namespace gtsam {
61class GTSAM_UNSTABLE_EXPORT LPInitSolver {
62 private:
63 const LP& lp_;
64
65 public:
67 LPInitSolver(const LP& lp) : lp_(lp) {}
68
70 VectorValues solve() const;
71
72 private:
74 LP::shared_ptr buildInitialLP(Key yKey) const;
75
80 GaussianFactorGraph::shared_ptr buildInitOfInitGraph() const;
81
84 double compute_y0(const VectorValues& x0) const;
85
87 std::vector<std::pair<Key, Matrix>> collectTerms(
88 const LinearInequality& factor) const;
89
91 InequalityFactorGraph addSlackVariableToInequalities(
92 Key yKey, const InequalityFactorGraph& inequalities) const;
93
94 // friend class for unit-testing private methods
95 friend class LPInitSolverInitializationTest;
96};
97
98} // namespace gtsam
99
100#endif // GTSAM_ALLOW_DEPRECATED_SINCE_V43
Linear Factor Graph where all factors are Gaussians.
Struct used to hold a Linear Programming Problem.
Global functions in a separate testing namespace.
Definition chartTesting.h:28