One Optimization Problem,
Several Ways to See It

Eric Milner’s Prize Lecture

Keivan Mirzaei
University of Calgary

The optimization problem

We usually call \(G\colon\mathbb R^d\to\mathbb R\) the cost function. Assuming it attains a minimum, solve

\[\min_{x\in\mathbb R^d}G(x).\]

is an input that gives the lowest value.

\[x_*\in\operatorname*{arg\,min}_{x\in\mathbb R^d}G(x).\]

is the height \(G(x_*)\) at that input.

Where does this problem appear?

Depot Customer Route

Choose depot coordinates.

Minimize total distance to customers.

Node Weight

Choose weights and biases.

Minimize average loss on the training data.

Fitted model Observed data

Choose model parameters.

Minimize negative log-likelihood.

Choose an application

Which way is downhill?

At \(x\), a small move \(v\) changes the height by approximately

\[G(x+v)-G(x)\approx\nabla G(x)\cdot v.\]

When the gradient is nonzero, its opposite is the steepest downhill direction. Gradient flow follows it continuously.

\[\dot{x}(t)=-\nabla G(x(t)),\qquad x(0)=x_0.\]

0.00 s

Discretizing gradient flow in time

\[\dot x(t)=-\nabla G(x(t)).\]

Forward Euler approximates the velocity at \(t_k\) by the forward difference over the time step \(\eta=t_{k+1}-t_k\).

\[\frac{x_{k+1}-x_k}{\eta}=-\nabla G(x_k).\]

Gradient descent algorithm

\[x_{k+1}=x_k-\eta\nabla G(x_k).\]

Backward Euler approximates the velocity at \(t_{k+1}\) by the backward difference over the same time step \(\eta=t_{k+1}-t_k\).

\[\frac{x_{k+1}-x_k}{\eta}=-\nabla G(x_{k+1}).\]

Implicit gradient descent

\[x_{k+1}=x_k-\eta\nabla G(x_{k+1}).\]

0 / 5
0 / 5

Proximal point method

Choose the next point by balancing its height with the cost of moving.

\(\displaystyle\min_{y\in\mathbb R^d}\) \(\Biggl\{\) \(\displaystyle\underbrace{G(y)}_{\text{destination cost}}\) \(+\) \(\displaystyle\underbrace{\frac{\|y-x_k\|^2}{2\eta}}_{\text{movement cost}}\) \(\Biggr\}.\)

At the minimizer \(y=x_{k+1}\), the gradient of this objective is zero.

\[\nabla G(x_{k+1})+\frac{x_{k+1}-x_k}{\eta}=0.\]

Implicit gradient descent

\[x_{k+1}=x_k-\eta\nabla G(x_{k+1}).\]

The deterministic optimal control approach

Start at \(X_0=x_0\) and choose a velocity \(u_t\) over one unit of time.

\[\dot X_t=u_t,\qquad 0\le t\le 1.\]

Choose \(u\) to minimize the final height plus the energy used along the way.

\(\displaystyle\min_u\Biggl\{\) \(\displaystyle\underbrace{G(X_1)}_{\text{destination cost}}\) \(+\) \(\displaystyle\underbrace{\frac{1}{2\eta}\int_0^1\|u_t\|^2\,dt}_{\text{steering cost}}\) \(\Biggr\}.\)
Position \(X_t\)
On the landscape \(G\)
Choose a control
0.00 s
Path energy

The cheapest path gives the proximal penalty

Fix a destination \(y\). The cheapest path from \(x_0\) to \(y\) in one unit of time is the straight line at constant velocity \(u_t=y-x_0\).

\[ \int_0^1\frac{\|y-x_0\|^2}{2\eta}\,dt =\frac{\|y-x_0\|^2}{2\eta}. \]

Now choose the destination

\[ \begin{aligned} &\inf_u\left\{G(X_1)+\frac1{2\eta}\int_0^1\|u_t\|^2\,dt\right\}\\ &\qquad=\inf_y\left\{G(y)+\frac{\|y-x_0\|^2}{2\eta}\right\}. \end{aligned} \]

The minimizing destination is the next iterate of the proximal point method.

How the methods connect

What can go wrong?

  • Regularity
  • Hidden convexity
  • Local vs. global
Higher local minimum Global minimum
A landscape with sharp corners

A new set of approaches

Let’s leave some room for uncertainty

Where do you think \(x_*\) is?

“My best guess is around 0.8.”

Instead of looking for a point \(x_*\), we look for a distribution \(\mu_*\).

Example draws
A distribution around our guess
The same points on \(G\)

A proximal point step for distributions

Update a point

\(\displaystyle\min_y\Biggl\{\) \(\displaystyle\underbrace{G(y)}_{\text{destination cost}}\) \(+\) \(\displaystyle\underbrace{\frac{\|y-x_k\|^2}{2\eta}}_{\text{movement cost}}\) \(\Biggr\}\)

Choose \(y\) to lower the cost while staying close to \(x_k\).

Update a distribution

\(\displaystyle\min_\mu\Biggl\{\) \(\displaystyle\underbrace{\mathbb E_\mu[G]}_{\text{average cost}}\) \(+\) \(\displaystyle\underbrace{\frac{1}{\eta}D_{\rm KL}(\mu\Vert\gamma)}_{\text{KL penalty}}\) \(\Biggr\}\)

Choose \(\mu\) to lower the average cost. Relative entropy penalizes changes from the reference distribution \(\gamma\).

A smaller step size \(\eta>0\) makes change more costly.

KL divergence

The Kullback–Leibler (KL) divergence is also called relative entropy. Let \(p\) be the density of \(\mu\) and \(q\) the density of the reference \(\gamma\).

\[ D_{\rm KL}(\mu\Vert\gamma)=\int_{\mathbb R}p(x)\log\!\frac{p(x)}{q(x)}\,dx. \]

\(\mu=\mathcal N(m,\sigma^2)\) \(\gamma=\mathcal N(0,1)\)

How much weight should a low point receive?

By the Gibbs variational inequality, the minimizer of the regularized problem has the Gibbs density.

Gibbs distribution

\[\mu^*(dy)\propto e^{-\eta G(y)}\,\gamma(dy).\]

Laplace principle

\[ \lim_{\eta\to\infty}-\frac{1}{\eta}\log\!\int_{\mathbb R^d} e^{-\eta G(y)}\,\gamma(dy)=\min G. \]

The Gibbs distribution concentrates near the global minimizer \(x_*\).

Reference Gibbs
The same landscape \(G\)
Reference and Gibbs densities

Generalized Bayes and MAP

Use \(\gamma\) as the prior distribution and \(G\) as a loss that measures how poorly \(y\) fits the data. Generalized Bayes gives the Gibbs posterior

\[ \mu^*(dy)\propto e^{-\eta G(y)}\,\gamma(dy). \]

With the negative log-likelihood \(G(y)=-\log p(\mathcal D\mid y)\) and \(\eta=1\), we recover the usual Bayesian posterior.

A maximum a posteriori (MAP) estimate is a parameter value where the posterior density is highest.

The proximal point reappears

Choose the Gaussian reference \(\gamma=\mathcal N(x_0,I)\). Its density is proportional to \(e^{-\|y-x_0\|^2/2}\).

The Gaussian contributes the squared-distance penalty.

\[ p^*(y)\propto \exp\!\left[-\eta\left(G(y)+\frac{\|y-x_0\|^2}{2\eta}\right)\right]. \]

The density peaks where the proximal objective is smallest.

A Gibbs mode is a proximal point and is a MAP estimate when \(p^*\) is used as a posterior.

Proximal objective   \(G(y)+\frac{\|y-x_0\|^2}{2\eta}\)
Gibbs density   \(p^*(y)\propto e^{-\eta G(y)-\|y-x_0\|^2/2}\)

The stochastic optimal control approach

Bring back the moving particle. Its motion now combines a steering velocity \(u_t\) and random motion \(W_t\).

\[dX_t=u_t\,dt+dW_t,\qquad X_0=x_0.\]

Choose \(u\) to minimize the expected total cost.

\(\displaystyle\min_u\mathbb E\!\Biggl[\) \(\displaystyle\underbrace{G(X_1)}_{\text{destination cost}}\) \(+\) \(\displaystyle\underbrace{\frac{1}{2\eta}\int_0^1\|u_t\|^2\,dt}_{\text{steering cost}}\) \(\Biggr].\)

Noise helps exploration by spreading paths across the landscape. A larger \(\eta\) favors exploitation by making it cheaper to steer toward lower-cost destinations.

Objective \(G\) and illustrative paths \(X_t\)
Choose a steering option
0.00 s

How to solve the control problem

Let \(V(t,y)\) be the minimum expected remaining cost from \(X_t=y\).

  1. Dynamic programming principle (DPP)
    HJB
    \(\partial_t V+\tfrac12\Delta V-\tfrac{\eta}{2}\|\nabla V\|^2=0,\) \(V(1,y)=G(y).\)
  2. Cole–Hopf transform \(H=e^{-\eta V}\)
    Heat equation
    \(\partial_t H+\tfrac12\Delta H=0,\) \(H(1,y)=e^{-\eta G(y)}.\)
  3. Feynman–Kac formula
    Final solution
    \(H(t,y)=\mathbb E\!\left[e^{-\eta G(y+W_{1-t})}\right],\) \(V(t,y)=-\tfrac{1}{\eta}\log H(t,y),\) \(u^*(t,y)=\nabla_y\log H(t,y).\)

Two approaches, the same Gibbs law

With no steering, the endpoint has the Gaussian reference law \(\gamma=\mathcal N(x_0,I)\).

With optimal steering

\[X_1^*\sim\mu^*,\qquad \mu^*(dy)\propto e^{-\eta G(y)}\,\gamma(dy).\]

With optimal steering, the endpoint distribution is the Gibbs distribution.

Move the time slider to see how the slope at the dot determines which way to steer.

Terminal weights Heat average
Gibbs step size \(\eta=\)4.00

Particle steering lab

Release 12 particles from \(x_0\). Each follows the heat-based steering rule and gets its own random pushes.

Change \(\eta\) and replay with the same noise. The Gibbs density shows where endpoints tend to land.

Best endpoint
—
Objective gap
—
Global minimum Best endpoint
0.00 s

The Nash equilibrium problem

Two players each minimize their own cost. Player 1 steers \(X_t\) with \(u_1\) and pays endpoint cost \(G_1(X_1,Y_1)\). Player 2 steers \(Y_t\) with \(u_2\) and pays endpoint cost \(G_2(X_1,Y_1)\).

\[ \begin{cases} dX_t=u_1(t,X_t,Y_t)\,dt+dW_t^1,\\ dY_t=u_2(t,X_t,Y_t)\,dt+dW_t^2. \end{cases} \]

Each steering rule uses both current positions, so we solve the equations together. At a Nash equilibrium, neither player can lower their cost by changing their choice alone.

Joint work with Jinniao Qiu and Adam Smyl, Stochastic Control Methods for Two-Player Nash Equilibrium.

From deterministic to stochastic

Thank you

Questions?