  In this paper, we study representation formulas for finite-horizon optimal
control problems with or without state constraints, unifying two different
viewpoints: the Lagrangian and dynamic programming (DP) frameworks. In a recent
work [1], the generalized Lax formula is obtained via DP for optimal control
problems with state constraints and nonlinear systems. We revisit the formula
from the Lagrangian perspective to provide a unified framework for
understanding and implementing the nontrivial representation of the value
function. Our simple derivation makes direct use of the Lagrangian formula from
the theory of Hamilton-Jacobi (HJ) equations. We also discuss a rigorous way to
construct an optimal control using a $\delta$-net, as well as a numerical
scheme for controller synthesis via convex optimization.
