  We consider nonlinear optimal control problems (OCPs) for which all problem
data are polynomial. In the first part of the paper, we review how occupation
measures can be used to approximate pointwise the optimal value function of a
given OCP, using a hierarchy of linear matrix inequality (LMI) relaxations. In
the second part, we extend the methodology to approximate the optimal value
function on a given set and we use such a function to constructively and
computationally derive an almost optimal control law. Numerical examples show
the effectiveness of the approach.
