API: Algorithms

SCvx*

Main.SCPLib.solve!Method

Solve non-convex OCP with SCvx* algorithm

Arguments

  • algo::SCvxStar: algorithm struct
  • prob::OptimalControlProblem: problem struct
  • x_ref: reference state history, size nx-by-N
  • u_ref: reference control history, size nu-by-N-1
  • maxiter::Int: maximum number of iterations
  • tol_feas::Float64: feasibility tolerance
  • tol_opt::Float64: optimality tolerance
  • tol_J0::Real: objective tolerance
  • verbosity::Int: verbosity level
  • store_iterates::Bool: whether to store iterates
source
Main.SCPLib.SCvxStarType

SCvx* algorithm

Arguments

  • nx::Int: number of states
  • N::Int: number of time steps
  • ng::Int: number of non-convex equality constraints
  • nh::Int: number of non-convex inequality constraints
  • Δ0::Float64: initial trust-region size
  • w0::Float64: initial penalty weight
  • rhos::Tuple{Real,Real,Real}: trust-region acceptance thresholds
  • alphas::Tuple{Real,Real}: trust-region size update factors
  • Δ_bounds::Tuple{Float64,Float64}: trust-region size bounds
  • gamma::Float64: stationarity tolerance update factor
  • beta::Float64: penalty weight update factor
  • w_max::Float64: maximum penalty weight
source

Prox-linear method

Main.SCPLib.solve!Method

Solve non-convex OCP with prox-linear algorithm

Arguments

  • algo::ProxLinear: algorithm struct
  • prob::OptimalControlProblem: problem struct
  • x_ref: reference state history, size nx-by-N
  • u_ref: reference control history, size nu-by-N-1
  • maxiter::Int: maximum number of iterations
  • tol_feas::Float64: feasibility tolerance
  • tol_opt::Float64: optimality tolerance
  • tol_J0::Real: objective tolerance
  • verbosity::Int: verbosity level
  • store_iterates::Bool: whether to store iterates
source
Main.SCPLib.ProxLinearType

Prox-linear algorithm

The weights are defined such that the penalized objective of the subproblems are:

\[L(Z) + w_ep * ||G(Z) + ∇G(Z_ref)*(Z - Z_ref)||_1 + w_prox/2 * ||Z - Z_ref||_2^2\]

where L(Z) is the original objective function, G(Z) are the non-convex constraints.

Arguments

  • w_ep::Float64: exact penalty term weight
  • w_prox::Float64: proximal term weight
  • proximal_u::Bool: whether to enforce proximal constraint on u
source

Fixed trust-region/weight

Main.SCPLib.solve!Method

Solve non-convex OCP with fixed trust-region-weight SCP Algorithm

This algorithm employs a fixed trust-region & accepts every convex subproblem step. Artificial infeasibility is avoided by introducing slack variables for nonlinear constraints that are penalized quadratically with a fixed weight.

Arguments

  • algo::FixedTRWSCP: algorithm struct
  • prob::OptimalControlProblem: problem struct
  • x_ref: reference state history, size nx-by-N
  • u_ref: reference control history, size nu-by-N-1
  • maxiter::Int: maximum number of iterations
  • tol_feas::Float64: feasibility tolerance
  • tol_opt::Float64: optimality tolerance
  • tol_J0::Real: objective tolerance
  • verbosity::Int: verbosity level
  • store_iterates::Bool: whether to store iterates
source