So I have a function $g$ that maps from some subspace, $S$, of $\mathbb{R}^n$ to $\mathbb{R}$. $g$ is concave such that $g(x) > 0$ for all $x$ in this subspace, $S$, of $\mathbb{R}^n$.
$f(x)$ is defined as $f(x) = \frac1{g(x)}$ and the question is to show that $f(x)$ is convex.
How would I do this by the definition of convexity?
My try:
As g is concave we have $g(ax + (1-a)y) \Rightarrow ag(x) + (1-a)g(x)$ which means that $f(ax + (1-a)y) = 1 / g(ax + (1-a)y) \Leftarrow 1/ag(x) + (1-a)g(x)$.
Thanks!