# Optimization of a Convex Function involving Standard Normal CDF and PDF

Could someone provide closed form solutions, if any, and steps to get there for the following optimization problem? Please note this function has been shown to be a convex function and hence a minimum and unique solution exists for this optimization.

\begin{eqnarray*} \underset{\left\{ x\right\} }{\min}\left\{ \left[\theta x^{2}+\sigma\frac{\phi\left(\frac{\theta x}{\sigma}\right)}{\Phi\left(\frac{\theta x}{\sigma}\right)}\right]+\left[\theta\left(W-x\right)^{2}+\frac{\phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}{\Phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}\right]\right\} \end{eqnarray*}

Here, $\phi$ and $\mathbf{\Phi}$ are the standard normal PDF and CDF, respectively. \begin{eqnarray*} \text{Also, }W\geq x,\; x\geq 0,\;\theta>0,\:\sigma^{2}\text{ is the variance of a Normal Distribution.} \end{eqnarray*}

FOC of this function seems to give below, which we can see is zero at $x=W/2$. With $\sigma >0$ Am I missing something? \begin{eqnarray*} 4x-2W-\frac{\theta x\phi\left(\frac{\theta x}{\sigma}\right)}{\sigma\Phi\left(\frac{\theta x}{\sigma}\right)}-\frac{1}{\sigma}\left[\frac{\phi\left(\frac{\theta x}{\sigma}\right)}{\Phi\left(\frac{\theta x}{\sigma}\right)}\right]^{2}+\frac{\theta\left(W-x\right)\phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}{\sigma\Phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}+\frac{1}{\sigma}\left[\frac{\phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}{\Phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}\right]^{2} \end{eqnarray*}

How would this change, if the function (convex again) were as follows?

\begin{eqnarray*} \underset{\left\{ x\right\} }{\min}\left\{ \left[\theta x^{2}+\frac{\sigma x\phi\left(\frac{\theta x}{\sigma}\right)}{\Phi\left(\frac{\theta x}{\sigma}\right)}\right]+\left[\theta\left(W-x\right)^{2}+\frac{\sigma\left(W-x\right)\phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}{\Phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}\right]\right\} \end{eqnarray*}

• I'm not sure an easy closed form exists; you can find the derivatives in closed form, but setting them equal to 0 gives a transcendental equation that neither I nor Mathematica makes any headway on. Note also (pedantically) that a unique solution requires the function be strictly convex, though that is true here. Jun 24, 2015 at 5:32
• Thanks @Dougal, Would numerically solutions then be the only way to solve this? Could you please point me to some resources that you think might be relevant? Jun 24, 2015 at 8:32

I agree with @Dougal that there is no general closed-form solution. However, for the special case of $\sigma=1$ there is. Using Mathematica (v 10.1) define the following functions:

\[CapitalPhi][z_] := CDF[NormalDistribution[0, 1], z]
\[Phi][z_] := PDF[NormalDistribution[0, 1], z]
f[x_, \[Theta]_, \[Sigma]_,
w_] := \[Theta] x^2 + \[Theta] (w -
x)^2 + \[Sigma] \[Phi][\[Theta] x/\[Sigma]]/\[CapitalPhi][\
\[Theta] x/\[Sigma]] + \[Phi][\[Theta] (w -
x)/\[Sigma]]/\[CapitalPhi][\[Theta] (w - x)/\[Sigma]]


So f is your function of interest. Differentiate it with respect to x:

g = D[f[x, \[Theta], \[Sigma], w], x]


If we set $x = w/2$ for that derivative we get

We see that when $\sigma=1$, the derivative is zero for all values of $\theta$. There might be other special cases.

Addition: Just another observation: If $w$ and $\theta$ are kept fixed and $\sigma\to\infty$, then the result is $x = w/2 + 1/(2\pi)$. If $w$ and $\sigma$ are kept fixed and $\theta\to\infty$, then $x = w/2$. So it seems that $w/2 \le x \le w/2+1/(2\pi)$ for any values of $\theta$ and $\sigma$.

• That's a nice observation, Jim. The value $w/2$ would serve well as the start of a few Newton-Raphson iterations in the general case.
– whuber
Jun 24, 2015 at 14:20
• Thanks all. Any thoughts on how this would change if the function were: (reflection in question now)\begin{eqnarray*} \underset{\left\{ x\right\} }{\min}\left\{ \left[\theta x^{2}+\frac{\sigma x\phi\left(\frac{\theta x}{\sigma}\right)}{\Phi\left(\frac{\theta x}{\sigma}\right)}\right]+\left[\theta\left(W-x\right)^{2}+\frac{\sigma\left(W-x\right)\phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}{\Phi\left(\frac{\theta\left(W-x\right)}{\sigma}\right)}\right]\right\} \end{eqnarray*} Please let me know if this should be made a new question. Jun 25, 2015 at 3:46
• It looks like the minimum $x$ is again $w/2$ for all $\sigma>0$, $\theta>0$, and $w>0$.
– JimB
Jun 25, 2015 at 5:07
• @JimBaldwin Yes, given that the new function is convex, that's immediate from its symmetry about $W/2$. I've realized though that I'm not 100% sure the function is convex? I believe it, but haven't been (quickly) able to show it. Jun 25, 2015 at 5:54
• @Dougal, Please see the proof of convexity here: stats.stackexchange.com/questions/158042/…. A similar proof applies for the ratio of the density and distribution functions. Jun 25, 2015 at 8:08