[Doc] User guide to the duals: every kind, constraint ↔ dual, direct ↔ indirect
I maintainer di solito rispondono entro 1 giorno
@ocots ci sta già lavorando.
Dal 31/10/2026.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Part of control-toolbox/CTFlows.jl#512 (tracking of the constraint duals), workstream C.
Goal
A user-side guide to the duals of a solution. It should show users everything they can get, how each dual relates to its constraint, and how the direct and the indirect methods meet. #1015 (the page on the convention) and #1016 (the sign examples) are parts of it. This issue is the guide that puts them together and shows off the feature.
What the guide should show
- Every kind of dual, read by its label with
dual(sol, ocp, :label): path (pure state, mixed), state box, control box, boundary, and variable box. For each kind: what it is (a function of time or a number), its sign, and how it appears inplot(sol). - The link between a constraint and its dual.
- An inequality has a nonnegative dual however it is written; an equality or a two-sided constraint has a signed dual (
SGN2,SGN3). - The dual is
0where the constraint is inactive and nonzero on a boundary arc. - The same constraint as a box or as a path constraint gives the same dual (
SGN5). - The labels: why naming a constraint matters, and what happens without a name.
- An inequality has a nonnegative dual however it is written; an equality or a two-sided constraint has a signed dual (
- The link between the direct and the indirect method.
- The same problem solved by
solveand rebuilt withFlow(ocp, law; constraint=:label, multiplier=μ): the same costate and the same duals, compared on one plot. - The dictionary between the
μof the maximum principle anddual. - What the indirect side computes by itself (control box, boundary duals by transversality) and what the user gives (
μof a state or mixed constraint). - Multi-phase solutions: the jumps of the duals at the switching times (#992).
- The same problem solved by
- What a dual tells about the solution: sensitivity, a check of the extremal, and an unknown dual (
PreconditionError) rather than a wrong0.
Depends on
The features of control-toolbox/CTFlows.jl#512, workstreams A and B. Each section can be written as soon as its feature is released. Each example should also be a test (#1034).
Related: #1014, #1015, #1016, #1034, #992, #968.
🤖 Generated with Claude Code
- Lingua principale
- Julia
- Stelle
- 135
- Fork
- 11
- Merge medio
- 7h 51m
- PR unite (30g)
- 22
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di control-toolbox/OptimalControl.jl
-
Tests of the duals: every kind of constraint, direct vs indirect, pinned algorithmsForse già presa @ocots l’ha presa 6 giorni fa. Aperta
control-toolbox/OptimalControl.jl#1034 · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
[Doc] Examples for the sign convention of duals and costate (min/max, writing of constraints, direct vs indirect)Forse già presa @ocots l’ha presa 14 giorni fa. Aperta
control-toolbox/OptimalControl.jl#1016 · 1 commento · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
Documentation: sign conventions (min/max, p⁰, constraints, duals) and how they appear in a solutionForse già presa @ocots l’ha presa 16 giorni fa. Apertadocumentation
control-toolbox/OptimalControl.jl#1015 · 2 commenti · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
Tests fail on Julia 1.13: keyword-only anonymous function in test/problems/goddard.jlForse già presa @ocots l’ha presa 18 giorni fa. Aperta
control-toolbox/OptimalControl.jl#996 · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
Docs: use Makie.Figure() instead of Makie.plot() for an empty canvasForse già presa @ocots l’ha presa 19 giorni fa. Aperta
control-toolbox/OptimalControl.jl#994 · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di control-toolbox/OptimalControl.jl
Issue simili
-
Add project: Typst_jll.jlForse già presa @github-actions l’ha presa oggi. Apertaadd-project
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 76/100
YDX-2147483647/best-of-typst#590 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100