Definitioncore
Hamiltonian of an optimal control problem
Also called control Hamiltonian, Pontryagin Hamiltonian.
The function H = lambda_0 L(x, u) + lambda^T f(x, u) of state, input and costate. The optimal input minimizes it at each time, and its gradients give the state and costate equations.
The Hamiltonian of an optimal control problem joins the running cost and the dynamics into one scalar function of the state , the input and a multiplier vector , the costate. In the maximum principle, the optimal input minimizes the Hamiltonian over the allowed inputs at each time, and the derivatives of the Hamiltonian give the equations of the state and the costate. This area uses the minimum form, with the sign convention of the definition below.
Definition
Take the optimal control problem with dynamics , , , and running cost , where and are in (and in , where the derivative in is used). The Hamiltonian is the function
The number is the cost multiplier. In the normal case and one writes . The abnormal case is explained on the page of the maximum principle. For time-varying data, .
Along a pair of functions and , the canonical equations are
The first is the dynamics. The second is the costate equation.
The minimized Hamiltonian is . The minimum condition of the maximum principle says that an optimal input satisfies at almost every .
The switching function of a control-affine problem, where and , is the coefficient of in : .
Examples and non-examples
A scalar problem. For , and , the normal Hamiltonian is . It is smallest at , so . The costate equation is . With , the horizon 1 and the terminal cost , the costate page shows and , which agrees with the direct computation on the optimal control problem page.
The linear quadratic regulator. For and with ,
is strictly convex in , and gives . The canonical equations become and . With , the pair solves the linear system with the Hamiltonian matrix
If , then , the LQR feedback. The factor 2 comes from the cost without a factor , the convention of this area.
A bounded input. For , and (a minimum-time problem), is linear in . Its minimum is at when , and the value is . The Hamiltonian is not differentiable in at its minimizer, and has no solution. This is why the minimum condition, and not , is the general rule. The bang-bang principle starts from this case.
Non-example: the Hamiltonian of mechanics. In the calculus of variations, with , the Hamiltonian of classical mechanics is , the Legendre transform of . It is not the control Hamiltonian, but the two are related: . So the costate is the negative of the momentum of mechanics, which matches the Euler-Lagrange equation page.
Non-example: the maximum form. Pontryagin et al. (1962) and Liberzon (2012) use the function with a constant and maximize it. With and it equals , so the maximum of one is the minimum of the other. The two forms give the same optimal inputs, but formulas copied between them change sign. On this site every page, the maximum principle page included, uses as defined above; that page shows the maximum form only to translate it.
Non-example: the Hamiltonian matrix. The Hamiltonian matrix is the matrix of the canonical equations of the LQR problem, shown above. It is a matrix, not a function, and it has a structure of its own (its eigenvalues are symmetric about the imaginary axis).
Related definitions
- Costate. The multiplier that solves , with end conditions from the transversality conditions.
- Constancy of the Hamiltonian. For a problem whose data do not depend on time, is constant along an optimal trajectory, and it is 0 if the final time is free. The proof is on the page of the maximum principle.
- Hamiltonian systems. If the minimizer is unique and smooth, the canonical equations with form the Hamiltonian system of the function . Its flow keeps the symplectic form.
- Hamiltonian in the HJB equation. The Hamilton-Jacobi-Bellman equation is , so the same minimized Hamiltonian appears there with replaced by the gradient of the value function.
- Singular arc. An interval on which the switching function is identically zero, so the minimum condition does not fix (singular arc).
References
- Daniel Liberzon, Calculus of Variations and Optimal Control Theory, A Concise Introduction, Princeton University Press, 2012, Section 2.4 (the Hamiltonian formalism of the calculus of variations), Section 3.4 (the variational approach and the Hamiltonian) and Section 4.1 (the statement of the maximum principle)
- Donald E. Kirk, Optimal Control Theory, An Introduction, Prentice-Hall, 1970 (Dover reprint, 2004), Section 5.1 (necessary conditions for optimal control, with the Hamiltonian)
- L. S. Pontryagin, V. G. Boltyanskii, R. V. Gamkrelidze and E. F. Mishchenko, The Mathematical Theory of Optimal Processes, translated by K. N. Trirogoff, edited by L. W. Neustadt, Interscience, 1962 (Russian edition 1961), Chapter 1 (the function H and the statement of the maximum principle)
Where this leads
About this page
The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.
| Ladder | Level | What the next level needs |
|---|---|---|
| Human proof | H0 no proof |
|
| Lean | L0 no Lean part |
|
| Visual | V0 none |
|
| Writing | W4 complete |
|
Tag VG8FXN Edit this page History Report an error Markdown