Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is function $$f(x, y) = \left(\frac{x}{y} - a\right)^2 \left(\frac{y}{x} - \frac{1}{a}\right)^2$$ convex on the domain $$\{(x,y): x, y \in \mathbb{R}, x >0, y >0 \}\quad?$$

Now I think that it is not convex. I calculated $$f''_{xx}=\frac{2(x^2 - 3 a^2y^2 + 2xay)}{ayx^4}$$ which can be negative when $x$ is small and $y$ is large. It means that the hessian cannot be positive definite, so $f(x,y)$ is not convex. Is that right?

EDIT: Correct calculations $$ f''_{xx} = \frac{3a^2y^2}{x^4} +\frac{1}{a^2y^2} - \frac{4ay}{x^3} $$

share|cite|improve this question
up vote 3 down vote accepted

Let's generalize. When is a function of the form $f(x,y)=g(x/y)$ convex in the positive quadrant? We have $\nabla f = \langle y^{-1} g', -xy^{-2}g'\rangle $, and therefore the Hessian is $$ D^2f = \begin{pmatrix} y^{-2} g'' & -xy^{-3}g'' - y^{-2}g' \\ -xy^{-3}g'' - y^{-2}g' & x^2y^{-4} g'' + 2xy^{-3}g' \end{pmatrix} \tag1$$ The determinant simplifies nicely: $$ \det D^2f = x^2y^{-6} (g'')^2+2xy^{-5}g''g' - (xy^{-3}g'' + y^{-2}g')^2 = -y^{-4} (g')^2 \tag2$$ Well, isn't this sad. The function $f$ is not convex unless it is constant.

share|cite|improve this answer
+1. Proving a more general result more easily than the specific one one has in mind. So typical of the mathematician's approach... :-) – Did Mar 1 '13 at 9:32
@5pm if $g''$ is positive then $D^2f$ is negative definite? – ashim Mar 4 '13 at 21:32
@ashim Since the determinant of $D^2f$ is $\le 0$, the matrix $D^2f$ cannot be either positive-definite or negative-definite. – user53153 Mar 4 '13 at 21:34
If $f : [0, 1] \to \mathbb{R}$ be a function defined by $f(x) = - \sqrt{1 - x^{2}}$. I want to show that $f$ is convex on $[0, 1]$, but I know that $f''(x) \geq 0$ for each $x \in (0, 1)$. It follows that $f$ is convex on $(0, 1)$. How can I prove for $[0, 1]$ ? – nameless Oct 23 '13 at 15:44

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.