Namespaces | |
namespace | casadi_problem |
namespace | detail |
namespace | problems |
namespace | test |
namespace | vec_util |
Typedefs | |
using | PolymorphicPGASolver = PolymorphicInnerSolver< PGASolver > |
using | PolymorphicGAAPGASolver = PolymorphicInnerSolver< GAAPGASolver > |
using | PolymorphicPANOCSolver = PolymorphicInnerSolver< PANOCSolver< PolymorphicPANOCDirectionBase > > |
using | PolymorphicStructuredPANOCLBFGSSolver = PolymorphicInnerSolver< StructuredPANOCLBFGSSolver > |
using | PolymorphicALMSolver = ALMSolver< PolymorphicInnerSolverWrapper > |
using | PolymorphicLBFGSDirection = PolymorphicPANOCDirection< LBFGS > |
using | real_t = double |
Default floating point type. More... | |
using | realvec = Eigen::Matrix< real_t, Eigen::Dynamic, 1 > |
Default type for floating point vectors. More... | |
using | realmat = Eigen::Matrix< real_t, Eigen::Dynamic, Eigen::Dynamic > |
Default type for floating point matrices. More... | |
using | vec = realvec |
Default type for vectors. More... | |
using | rvec = Eigen::Ref< vec > |
Default type for mutable references to vectors. More... | |
using | crvec = Eigen::Ref< const vec > |
Default type for immutable references to vectors. More... | |
using | mat = realmat |
Default type for matrices. More... | |
using | rmat = Eigen::Ref< mat > |
Default type for mutable references to matrices. More... | |
using | crmat = Eigen::Ref< const mat > |
Default type for immutable references to matrices. More... | |
using | dim = std::pair< casadi_int, casadi_int > |
Enumerations | |
enum class | LBFGSStepSize { BasedOnGradientStepSize = 0 , BasedOnCurvature = 1 } |
Which method to use to select the L-BFGS step size. More... | |
enum class | PANOCStopCrit { ApproxKKT = 0 , ApproxKKT2 , ProjGradNorm , ProjGradNorm2 , ProjGradUnitNorm , ProjGradUnitNorm2 , FPRNorm , FPRNorm2 , Ipopt } |
enum class | SolverStatus { Unknown = 0 , Converged , MaxTime , MaxIter , NotFinite , NoProgress , Interrupted } |
Exit status of a numerical solver such as ALM or PANOC. More... | |
Functions | |
template<class InnerSolver > | |
auto | InnerSolverCallWrapper () |
InnerStatsAccumulator< PolymorphicInnerSolverWrapper::Stats > & | operator+= (InnerStatsAccumulator< PolymorphicInnerSolverWrapper::Stats > &acc, const PolymorphicInnerSolverWrapper::Stats &s) |
py::dict | stats_to_dict (const PANOCStats &s) |
py::dict | stats_to_dict (const InnerStatsAccumulator< PANOCStats > &s) |
py::dict | stats_to_dict (const StructuredPANOCLBFGSSolver::Stats &s) |
py::dict | stats_to_dict (const PGASolver::Stats &s) |
py::dict | stats_to_dict (const GAAPGASolver::Stats &s) |
py::dict | stats_to_dict (const InnerStatsAccumulator< StructuredPANOCLBFGSSolver::Stats > &s) |
py::dict | stats_to_dict (const InnerStatsAccumulator< PGASolver::Stats > &s) |
py::dict | stats_to_dict (const InnerStatsAccumulator< GAAPGASolver::Stats > &s) |
py::dict | stats_to_dict (const PolymorphicALMSolver::Stats &s) |
const char * | enum_name (PANOCStopCrit s) |
std::ostream & | operator<< (std::ostream &os, PANOCStopCrit s) |
InnerStatsAccumulator< PANOCStats > & | operator+= (InnerStatsAccumulator< PANOCStats > &acc, const PANOCStats &s) |
InnerStatsAccumulator< SecondOrderPANOCSolver::Stats > & | operator+= (InnerStatsAccumulator< SecondOrderPANOCSolver::Stats > &acc, const SecondOrderPANOCSolver::Stats &s) |
InnerStatsAccumulator< StructuredPANOCLBFGSStats > & | operator+= (InnerStatsAccumulator< StructuredPANOCLBFGSStats > &acc, const StructuredPANOCLBFGSStats &s) |
void | minimize_update_anderson (LimitedMemoryQR &qr, rmat G, crvec rₖ, crvec rₖ₋₁, crvec gₖ, rvec γ_LS, rvec xₖ_aa) |
Solve one step of Anderson acceleration to find a fixed point of a function g(x): More... | |
InnerStatsAccumulator< GAAPGASolver::Stats > & | operator+= (InnerStatsAccumulator< GAAPGASolver::Stats > &acc, const GAAPGASolver::Stats &s) |
InnerStatsAccumulator< LBFGSBStats > & | operator+= (InnerStatsAccumulator< LBFGSBStats > &acc, const LBFGSBStats &s) |
InnerStatsAccumulator< PGASolver::Stats > & | operator+= (InnerStatsAccumulator< PGASolver::Stats > &acc, const PGASolver::Stats &s) |
alpaqa::Problem | load_CasADi_problem (const std::string &filename, unsigned n=0, unsigned m=0, bool second_order=false) |
Load a problem generated by CasADi (without parameters). More... | |
ProblemWithParam | load_CasADi_problem_with_param (const std::string &filename, unsigned n=0, unsigned m=0, unsigned p=0, bool second_order=false) |
Load a problem generated by CasADi (with parameters). More... | |
template<class ObjFunT , class ObjGradFunT , class DirectionT > | |
PANOCStats | panoc_impl (ObjFunT &ψ, ObjGradFunT &grad_ψ, const Box &C, rvec x, real_t ε, const PANOCParams ¶ms, vec_allocator &alloc, DirectionT &direction_provider) |
template<class DirectionProviderT = LBFGS, class ObjFunT , class ObjGradFunT > | |
PANOCStats | panoc (ObjFunT &ψ, ObjGradFunT &grad_ψ, const Box &C, rvec x, real_t ε, const PANOCParams ¶ms, PANOCDirection< DirectionProviderT > direction, vec_allocator &alloc) |
template<class DirectionProviderT = LBFGS, class ObjFunT , class ObjGradFunT > | |
PANOCStats | panoc (ObjFunT &ψ, ObjGradFunT &grad_ψ, const Box &C, rvec x, real_t ε, const PANOCParams ¶ms, PANOCDirection< DirectionProviderT > direction) |
template<class Vec > | |
auto | project (const Vec &v, const Box &box) |
Project a vector onto a box. More... | |
template<class Vec > | |
auto | projecting_difference (const Vec &v, const Box &box) |
Get the difference between the given vector and its projection. More... | |
real_t | dist_squared (crvec v, const Box &box) |
Get the distance squared between the given vector and its projection. More... | |
real_t | dist_squared (crvec v, const Box &box, crvec Σ) |
Get the distance squared between the given vector and its projection in the Σ norm. More... | |
EvalCounter & | operator+= (EvalCounter &a, const EvalCounter &b) |
EvalCounter::EvalTimer & | operator+= (EvalCounter::EvalTimer &a, const EvalCounter::EvalTimer &b) |
EvalCounter | operator+ (EvalCounter a, const EvalCounter &b) |
template<class F > | |
auto | wrap_load (const std::string &so_name, const char *name, F f) |
template<class T , class... Args> | |
auto | wrapped_load (const std::string &so_name, const char *name, Args &&...args) |
const char * | enum_name (SolverStatus s) |
std::ostream & | operator<< (std::ostream &os, SolverStatus s) |
Variables | |
constexpr size_t | panoc_min_alloc_size = 10 |
constexpr real_t | inf = std::numeric_limits<real_t>::infinity() |
\( \infty \) More... | |
constexpr real_t | NaN = std::numeric_limits<real_t>::quiet_NaN() |
Not a number. More... | |
constexpr static auto | dims |
struct alpaqa::ALMParams |
Class Members | ||
---|---|---|
real_t | ε | Primal tolerance. |
real_t | δ | Dual tolerance. |
real_t | Δ | Factor used in updating the penalty parameters. |
real_t | Δ_lower | Factor to reduce ALMParams::Δ when inner convergence fails. |
real_t | Σ₀ |
Initial penalty parameter. When set to zero (which is the default), it is computed automatically, based on the constraint violation in the starting point and the parameter ALMParams::σ₀. |
real_t | σ₀ |
Initial penalty parameter factor. Active if ALMParams::Σ₀ is set to zero. |
real_t | Σ₀_lower | Factor to reduce the initial penalty factor by if convergence fails in in the first iteration. |
real_t | ε₀ | Initial primal tolerance. |
real_t | ε₀_increase | Factor to increase the initial primal tolerance if convergence fails in the first iteration. |
real_t | ρ | Update factor for primal tolerance. |
real_t | ρ_increase | Factor to increase the primal tolerance update factor by if convergence fails. |
real_t | θ | Error tolerance for penalty increase. |
real_t | M | Lagrange multiplier bound. |
real_t | Σ_max | Maximum penalty factor. |
real_t | Σ_min | Minimum penalty factor (used during initialization). |
unsigned int | max_iter | Maximum number of outer ALM iterations. |
microseconds | max_time | Maximum duration. |
unsigned | max_num_initial_retries | How many times can the initial penalty ALMParams::Σ₀ or ALMParams::σ₀ and the initial primal tolerance ALMParams::ε₀ be reduced. |
unsigned | max_num_retries | How many times can the penalty update factor ALMParams::Δ and the primal tolerance factor ALMParams::ρ be reduced. |
unsigned | max_total_num_retries | Combined limit for ALMParams::max_num_initial_retries and ALMParams::max_num_retries. |
unsigned | print_interval |
When to print progress. If set to zero, nothing will be printed. If set to N != 0, progress is printed every N iterations. |
bool | preconditioning | Apply preconditioning to the problem, based on the gradients in the starting point. |
bool | single_penalty_factor | Use one penalty factor for all m constraints. |
struct alpaqa::GAAPGAParams |
Class Members | ||
---|---|---|
LipschitzEstimateParams | Lipschitz | Parameters related to the Lipschitz constant estimate and step size. |
unsigned | limitedqr_mem | Length of the history to keep in the limited-memory QR algorithm. |
unsigned | max_iter | Maximum number of inner iterations. |
microseconds | max_time | Maximum duration. |
real_t | L_min | Minimum Lipschitz constant estimate. |
real_t | L_max | Maximum Lipschitz constant estimate. |
PANOCStopCrit | stop_crit | What stopping criterion to use. |
unsigned | print_interval |
When to print progress. If set to zero, nothing will be printed. If set to N != 0, progress is printed every N iterations. |
real_t | quadratic_upperbound_tolerance_factor | |
unsigned | max_no_progress | Maximum number of iterations without any progress before giving up. |
bool | full_flush_on_γ_change |
struct alpaqa::GAAPGAProgressInfo |
struct alpaqa::InnerStatsAccumulator |
struct alpaqa::InnerStatsAccumulator< GAAPGASolver::Stats > |
struct alpaqa::InnerStatsAccumulator< LBFGSBStats > |
struct alpaqa::InnerStatsAccumulator< PANOCStats > |
Class Members | ||
---|---|---|
microseconds | elapsed_time | |
unsigned | iterations | |
unsigned | linesearch_failures | |
unsigned | lbfgs_failures | |
unsigned | lbfgs_rejected | |
unsigned | τ_1_accepted | |
unsigned | count_τ | |
real_t | sum_τ |
struct alpaqa::InnerStatsAccumulator< PGASolver::Stats > |
struct alpaqa::InnerStatsAccumulator< SecondOrderPANOCSolver::Stats > |
Class Members | ||
---|---|---|
microseconds | elapsed_time | |
unsigned | iterations | |
unsigned | newton_failures | |
unsigned | linesearch_failures | |
unsigned | τ_1_accepted | |
unsigned | count_τ | |
real_t | sum_τ |
struct alpaqa::InnerStatsAccumulator< StructuredPANOCLBFGSStats > |
Class Members | ||
---|---|---|
microseconds | elapsed_time | Total elapsed time in the inner solver. |
unsigned | iterations | Total number of inner PANOC iterations. |
unsigned | linesearch_failures | Total number of PANOC line search failures. |
unsigned | lbfgs_failures | Total number of times that the L-BFGS direction was not finite. |
unsigned | lbfgs_rejected |
Total number of times that the L-BFGS update was rejected (i.e. it could have resulted in a non-positive definite Hessian estimate). |
unsigned | τ_1_accepted |
Total number of times that a line search parameter of \( \tau = 1 \) was accepted (i.e. no backtracking necessary). |
unsigned | count_τ | The total number of line searches performed (used for computing the average value of \( \tau \)). |
real_t | sum_τ | The sum of the line search parameter \( \tau \) in all iterations (used for computing the average value of \( \tau \)). |
struct alpaqa::LBFGSBStats |
Class Members | ||
---|---|---|
SolverStatus | status | |
real_t | ε | |
microseconds | elapsed_time | |
unsigned | iterations |
struct alpaqa::LBFGSParams |
Class Members | ||
---|---|---|
unsigned | memory | Length of the history to keep. |
struct LBFGSParams.cbfgs | cbfgs |
Parameters in the cautious BFGS update condition. \[ \frac{y^\top s}{s^\top s} \ge \epsilon \| g \|^\alpha \] |
bool | rescale_when_γ_changes |
struct alpaqa::LBFGSParams.cbfgs |
struct alpaqa::LipschitzEstimateParams |
Class Members | ||
---|---|---|
real_t | L₀ | Initial estimate of the Lipschitz constant of ∇ψ(x) |
real_t | ε | Relative step size for initial finite difference Lipschitz estimate. |
real_t | δ | Minimum step size for initial finite difference Lipschitz estimate. |
real_t | Lγ_factor | Factor that relates step size γ and Lipschitz constant. |
struct alpaqa::PANOCParams |
Class Members | ||
---|---|---|
LipschitzEstimateParams | Lipschitz | Parameters related to the Lipschitz constant estimate and step size. |
unsigned | max_iter | Maximum number of inner PANOC iterations. |
microseconds | max_time | Maximum duration. |
real_t | τ_min | Minimum weight factor between Newton step and projected gradient step. |
real_t | L_min | Minimum Lipschitz constant estimate. |
real_t | L_max | Maximum Lipschitz constant estimate. |
PANOCStopCrit | stop_crit | What stopping criterion to use. |
unsigned | max_no_progress | Maximum number of iterations without any progress before giving up. |
unsigned | print_interval |
When to print progress. If set to zero, nothing will be printed. If set to N != 0, progress is printed every N iterations. |
real_t | quadratic_upperbound_tolerance_factor | |
bool | update_lipschitz_in_linesearch | |
bool | alternative_linesearch_cond | |
LBFGSStepSize | lbfgs_stepsize |
struct alpaqa::PANOCProgressInfo |
struct alpaqa::PANOCStats |
Class Members | ||
---|---|---|
SolverStatus | status | |
real_t | ε | |
microseconds | elapsed_time | |
unsigned | iterations | |
unsigned | linesearch_failures | |
unsigned | lbfgs_failures | |
unsigned | lbfgs_rejected | |
unsigned | τ_1_accepted | |
unsigned | count_τ | |
real_t | sum_τ |
struct alpaqa::PGAParams |
Class Members | ||
---|---|---|
LipschitzEstimateParams | Lipschitz | Parameters related to the Lipschitz constant estimate and step size. |
unsigned | max_iter | Maximum number of inner iterations. |
microseconds | max_time | Maximum duration. |
real_t | L_min | Minimum Lipschitz constant estimate. |
real_t | L_max | Maximum Lipschitz constant estimate. |
PANOCStopCrit | stop_crit | What stop criterion to use. |
unsigned | print_interval |
When to print progress. If set to zero, nothing will be printed. If set to N != 0, progress is printed every N iterations. |
real_t | quadratic_upperbound_tolerance_factor |
struct alpaqa::PGAProgressInfo |
struct alpaqa::SecondOrderPANOCParams |
Class Members | ||
---|---|---|
LipschitzEstimateParams | Lipschitz | Parameters related to the Lipschitz constant estimate and step size. |
unsigned | max_iter | Maximum number of inner PANOC iterations. |
microseconds | max_time | Maximum duration. |
real_t | τ_min | Minimum weight factor between Newton step and projected gradient step. |
real_t | L_min | Minimum Lipschitz constant estimate. |
real_t | L_max | Maximum Lipschitz constant estimate. |
PANOCStopCrit | stop_crit | What stopping criterion to use. |
unsigned | max_no_progress | Maximum number of iterations without any progress before giving up. |
unsigned | print_interval |
When to print progress. If set to zero, nothing will be printed. If set to N != 0, progress is printed every N iterations. |
real_t | quadratic_upperbound_tolerance_factor | |
bool | update_lipschitz_in_linesearch | |
bool | alternative_linesearch_cond |
struct alpaqa::StructuredPANOCLBFGSParams |
Class Members | ||
---|---|---|
LipschitzEstimateParams | Lipschitz | Parameters related to the Lipschitz constant estimate and step size. |
unsigned | max_iter | Maximum number of inner PANOC iterations. |
microseconds | max_time | Maximum duration. |
real_t | τ_min | Minimum weight factor between Newton step and projected gradient step. |
real_t | L_min | Minimum Lipschitz constant estimate. |
real_t | L_max | Maximum Lipschitz constant estimate. |
real_t | nonmonotone_linesearch |
Factor used in update for exponentially weighted nonmonotone line search. Zero means monotone line search. |
PANOCStopCrit | stop_crit | What stopping criterion to use. |
unsigned | max_no_progress | Maximum number of iterations without any progress before giving up. |
unsigned | print_interval |
When to print progress. If set to zero, nothing will be printed. If set to N != 0, progress is printed every N iterations. |
real_t | quadratic_upperbound_tolerance_factor | |
bool | update_lipschitz_in_linesearch | |
bool | alternative_linesearch_cond | |
bool | hessian_vec | |
bool | hessian_vec_finite_differences | |
bool | full_augmented_hessian | |
unsigned | hessian_step_size_heuristic | |
LBFGSStepSize | lbfgs_stepsize |
struct alpaqa::StructuredPANOCLBFGSProgressInfo |
Class Members | ||
---|---|---|
unsigned | k | |
crvec | x | |
crvec | p | |
real_t | norm_sq_p | |
crvec | x_hat | |
real_t | φγ | |
real_t | ψ | |
crvec | grad_ψ | |
real_t | ψ_hat | |
crvec | grad_ψ_hat | |
real_t | L | |
real_t | γ | |
real_t | τ | |
real_t | ε | |
crvec | Σ | |
crvec | y | |
const Problem & | problem | |
const StructuredPANOCLBFGSParams & | params |
struct alpaqa::StructuredPANOCLBFGSStats |
Class Members | ||
---|---|---|
SolverStatus | status | |
real_t | ε | |
microseconds | elapsed_time | |
unsigned | iterations | |
unsigned | linesearch_failures | |
unsigned | lbfgs_failures | |
unsigned | lbfgs_rejected | |
unsigned | τ_1_accepted | |
unsigned | count_τ | |
real_t | sum_τ |
Definition at line 373 of file polymorphic-inner-solver.hpp.
Definition at line 374 of file polymorphic-inner-solver.hpp.
Definition at line 375 of file polymorphic-inner-solver.hpp.
Definition at line 377 of file polymorphic-inner-solver.hpp.
Definition at line 380 of file polymorphic-inner-solver.hpp.
Definition at line 128 of file polymorphic-panoc-direction.hpp.
Default type for vectors.
using dim = std::pair<casadi_int, casadi_int> |
Definition at line 86 of file CasADiLoader.cpp.
|
strong |
Which method to use to select the L-BFGS step size.
Enumerator | |
---|---|
BasedOnGradientStepSize | |
BasedOnCurvature |
Definition at line 6 of file lbfgs-stepsize.hpp.
|
strong |
Enumerator | |
---|---|
ApproxKKT | Find an ε-approximate KKT point in the ∞-norm: \[ \varepsilon = \left\| \gamma_k^{-1} (x^k - \hat x^k) + \nabla \psi(\hat x^k) - \nabla \psi(x^k) \right\|_\infty \] |
ApproxKKT2 | Find an ε-approximate KKT point in the 2-norm: \[ \varepsilon = \left\| \gamma_k^{-1} (x^k - \hat x^k) + \nabla \psi(\hat x^k) - \nabla \psi(x^k) \right\|_2 \] |
ProjGradNorm | ∞-norm of the projected gradient with step size γ: \[ \varepsilon = \left\| x^k - \Pi_C\left(x^k - \gamma_k \nabla \psi(x^k)\right) \right\|_\infty \] |
ProjGradNorm2 | 2-norm of the projected gradient with step size γ: \[ \varepsilon = \left\| x^k - \Pi_C\left(x^k - \gamma_k \nabla \psi(x^k)\right) \right\|_2 \] This is the same criterion as used by OpEn. |
ProjGradUnitNorm | ∞-norm of the projected gradient with unit step size: \[ \varepsilon = \left\| x^k - \Pi_C\left(x^k - \nabla \psi(x^k)\right) \right\|_\infty \] |
ProjGradUnitNorm2 | 2-norm of the projected gradient with unit step size: \[ \varepsilon = \left\| x^k - \Pi_C\left(x^k - \nabla \psi(x^k)\right) \right\|_2 \] |
FPRNorm | ∞-norm of fixed point residual: \[ \varepsilon = \gamma_k^{-1} \left\| x^k - \Pi_C\left(x^k - \gamma_k \nabla \psi(x^k)\right) \right\|_\infty \] |
FPRNorm2 | 2-norm of fixed point residual: \[ \varepsilon = \gamma_k^{-1} \left\| x^k - \Pi_C\left(x^k - \gamma_k \nabla \psi(x^k)\right) \right\|_2 \] |
Ipopt | The stopping criterion used by Ipopt, see https://link.springer.com/article/10.1007/s10107-004-0559-y equation (5). Given a candidate iterate \( \hat x^k \) and the corresponding candidate Lagrange multipliers \( \hat y^k \) for the general constraints \( g(x)\in D \), the multipliers \( w \) for the box constraints \( x\in C \) (that are otherwise not computed explicitly) are given by \[ w^k = v^k - \Pi_C(v^k), \] where \[ \begin{aligned} v^k &\triangleq \hat x^k - \nabla f(\hat x^k) - \nabla g(\hat x^k)\, \hat y^k \\ &= \hat x^k - \nabla \psi(\hat x^k) \end{aligned} \] The quantity that is compared to the (scaled) tolerance is then given by \[ \begin{aligned} \varepsilon' &= \left\| \nabla f(\hat x^k) + \nabla g(\hat x^k)\, \hat y^k + w^k \right\|_\infty \\ &= \left\| \hat x^k - \Pi_C\left(v^k\right) \right\|_\infty \end{aligned} \] Finally, the quantity is scaled by the factor \[ s_d \triangleq \max\left\{ s_\text{max},\;\frac{\|\hat y^k\|_1 + \|w^k\|_1}{2m + 2n} \right\} / s_\text{max}, \] i.e. \( \varepsilon = \varepsilon' / s_d \). |
Definition at line 8 of file panoc-stop-crit.hpp.
|
strong |
Exit status of a numerical solver such as ALM or PANOC.
Definition at line 7 of file solverstatus.hpp.
auto alpaqa::InnerSolverCallWrapper | ( | ) |
Definition at line 20 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 152 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 192 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 208 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 222 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 238 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 248 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 259 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 275 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 284 of file polymorphic-inner-solver.hpp.
|
inline |
Definition at line 382 of file polymorphic-inner-solver.hpp.
|
inline |
|
inline |
|
inline |
Definition at line 147 of file inner/decl/panoc.hpp.
|
inline |
Definition at line 127 of file decl/second-order-panoc.hpp.
|
inline |
Definition at line 162 of file decl/structured-panoc-lbfgs.hpp.
|
inline |
Solve one step of Anderson acceleration to find a fixed point of a function g(x):
\( g(x^\star) - x^\star = 0 \)
Updates the QR factorization of \( \mathcal{R}_k = QR \), solves the least squares problem to find \( \gamma_\text{LS} \), computes the next iterate \( x_{k+1} \), and stores the current function value \( g_k \) in the matrix \( G \), which is used as a circular buffer.
\[ \begin{aligned} \mathcal{R}_k &= \begin{pmatrix} \Delta r_{k-m_k} & \dots & \Delta r_{k-1} \end{pmatrix} \in \mathbb{R}^{n\times m_k} \\ \Delta r_i &= r_{i+1} - r_i \\ r_i &= g_i - x_i \\ g_i &= g(x_i) \\ \DeclareMathOperator*{\argmin}{argmin} \gamma_\text{LS} &= \argmin_\gamma \left\| \mathcal{R}_k \gamma - r_k \right\|_2 \\ \alpha_i &= \begin{cases} \gamma_\text{LS}[0] & i = 0 \\ \gamma_\text{LS}[i] - \gamma_\text{LS}[i-1] & 0 < i < m_k \\ 1 - \gamma_\text{LS}[m_k - 1] & i = m_k \end{cases} \\ x_{k+1} &= \sum_{i=0}^{m_k} \alpha_i\,g_i \end{aligned} \]
Definition at line 30 of file anderson-helpers.hpp.
|
inline |
Definition at line 361 of file guarded-aa-pga.hpp.
|
inline |
Definition at line 193 of file lbfgspp.hpp.
|
inline |
|
inline |
Definition at line 157 of file standalone/panoc.hpp.
PANOCStats alpaqa::panoc | ( | ObjFunT & | ψ, |
ObjGradFunT & | grad_ψ, | ||
const Box & | C, | ||
rvec | x, | ||
real_t | ε, | ||
const PANOCParams & | params, | ||
PANOCDirection< DirectionProviderT > | direction, | ||
vec_allocator & | alloc | ||
) |
Definition at line 370 of file standalone/panoc.hpp.
PANOCStats alpaqa::panoc | ( | ObjFunT & | ψ, |
ObjGradFunT & | grad_ψ, | ||
const Box & | C, | ||
rvec | x, | ||
real_t | ε, | ||
const PANOCParams & | params, | ||
PANOCDirection< DirectionProviderT > | direction | ||
) |
|
inline |
|
inline |
Get the difference between the given vector and its projection.
\[ v - \Pi_C(v) \]
[in] | v | The vector to project |
[in] | box | The box to project onto |
Definition at line 28 of file box.hpp.
Get the distance squared between the given vector and its projection.
\[ \left\| v - \Pi_C(v) \right\|_2^2 \]
[in] | v | The vector to project |
[in] | box | The box to project onto |
Definition at line 37 of file box.hpp.
Get the distance squared between the given vector and its projection in the Σ norm.
\[ \left\| v - \Pi_C(v) \right\|_\Sigma^2 = \left(v - \Pi_C(v)\right)^\top \Sigma \left(v - \Pi_C(v)\right) \]
[in] | v | The vector to project |
[in] | box | The box to project onto |
[in] | Σ | Diagonal matrix defining norm |
Definition at line 48 of file box.hpp.
|
inline |
Definition at line 191 of file include/alpaqa/util/problem.hpp.
|
inline |
Definition at line 202 of file include/alpaqa/util/problem.hpp.
|
inline |
Definition at line 214 of file include/alpaqa/util/problem.hpp.
auto alpaqa::wrap_load | ( | const std::string & | so_name, |
const char * | name, | ||
F | f | ||
) |
auto alpaqa::wrapped_load | ( | const std::string & | so_name, |
const char * | name, | ||
Args &&... | args | ||
) |
const char * alpaqa::enum_name | ( | SolverStatus | s | ) |
Definition at line 8 of file solverstatus.cpp.
std::ostream & alpaqa::operator<< | ( | std::ostream & | os, |
SolverStatus | s | ||
) |
|
constexpr |
Definition at line 154 of file standalone/panoc.hpp.
|
staticconstexpr |
Definition at line 83 of file CasADiLoader.cpp.