OptimizationSystem

System Constructors

ModelingToolkit.OptimizationSystemType
struct OptimizationSystem <: ModelingToolkit.AbstractSystem

A scalar equation for optimization.

Fields

  • op

    Vector of equations defining the system.

  • states

    Unknown variables.

  • ps

    Parameters.

  • pins

  • observed

  • name

    Name: the name of the system

  • systems

    systems: The internal systems

Examples

@variables x y z
@parameters σ ρ β

op = σ*(y-x) + x*(ρ-z)-y + x*y - β*z
os = OptimizationSystem(eqs, [x,y,z],[σ,ρ,β])
source

Composition and Accessor Functions

  • sys.eqs or equations(sys): The equation to be minimized.
  • sys.states or states(sys): The set of states for the optimization.
  • sys.parameters or parameters(sys): The parameters for the optimization.

Transformations

Applicable Calculation and Generation Functions

calculate_gradient
calculate_hessian
generate_gradient
generate_hessian
hessian_sparsity

Problem Constructors

DiffEqBase.OptimizationProblemType
function DiffEqBase.OptimizationProblem{iip}(sys::OptimizationSystem,
                                          parammap=DiffEqBase.NullParameters();
                                          u0=nothing, lb=nothing, ub=nothing,
                                          hes = false, sparse = false,
                                          checkbounds = false,
                                          linenumbers = true, parallel=SerialForm(),
                                          kwargs...) where iip

Generates an OptimizationProblem from an OptimizationSystem and allows for automatically symbolically calculating numerical enhancements.

source