<s>[INST] Is $\frac{1}{xy}$ convex for $x,y>0$ Is the function $$f(x,y) = \frac{1}{xy}$$ 
convex for $x,y>0$. I computed the hessian but it is very complicated and I do not know how to show it is positive semi definite. 
 [/INST] The Hessian is
$$\left( \begin{matrix} \frac{2}{x^3y} & \frac{1}{x^2y^2} \\ \frac{1}{x^2y^2} & \frac{2}{xy^3}\end{matrix} \right).$$
Now fix $x,y \ge 0$ , then we must show that for $a,b \in \mathbb{R}$ we have 
$$2g(a,b)=\left( \begin{matrix} a& b \end{matrix} \right) \left( \begin{matrix} \frac{2}{x^3y} & \frac{1}{x^2y^2} \\ \frac{1}{x^2y^2} & \frac{2}{xy^3}\end{matrix} \right)\left( \begin{matrix}a \\ b \end{matrix} \right) = 2 \left( \frac{a^2}{x^3y}+\frac{b^2}{xy^3}+\frac{ab}{x^2y^2} \right) \ge 0.$$
Let $v=ax^{-\frac{3}{2}}y^{-\frac{1}{2}}$ and $w=bx^{-\frac{1}{2}}y^{-\frac{3}{2}}$, then $g(a,b) = v^2+w^2+vw$.
So we can wlog assume $v < 0 < w$, then $-v \le w$ gives $-vw \le w^2$ or $w^2+vw\le 0$. Likewise $-v > w$ gives $v^2 > -vw$ or $v^2+vw>0$.
So we have $g(a,b) \ge 0$ for all $a,b \in \mathbb{R}$.
Thus the Hessian is positive semidefinite, so $\frac{1}{xy}$ is convex.
</s>