Costate equation

The costate equation is related to the state equation used in optimal control. It is also referred to as auxiliary, adjoint, influence, or multiplier equation. It is stated as a vector of first order differential equations

\dot{\lambda}^{\mathsf{T}}(t)=-\frac{\partial H}{\partial x} $$ where the right-hand side is the vector of partial derivatives of the negative of the Hamiltonian with respect to the state variables.

Interpretation
The costate variables $$\lambda(t)$$ can be interpreted as Lagrange multipliers associated with the state equations. The state equations represent constraints of the minimization problem, and the costate variables represent the marginal cost of violating those constraints; in economic terms the costate variables are the shadow prices.

Solution
The state equation is subject to an initial condition and is solved forwards in time. The costate equation must satisfy a transversality condition and is solved backwards in time, from the final time towards the beginning. For more details see Pontryagin's maximum principle.