[Math] Covariance between a random variable and a decreasing function of it is negative

covarianceprobability

I have a continuous random variable $x$ and a function $f(x)$ such that $f(x)>0$ and $f'(x)<0$ for every $x$.

Under what conditions can we say that the covariance between $x$ and $f(x)$ is negative? Is it always true? Or is there a counterexample where the covariance is positive or zero? Do I need to assume other properties of $f(.)$, such that, it is convex?

I know for instance that if $X$ is normally distributed with zero mean, then, $Cov(X,X^2)=0$. Is there a counterexample such that $Cov(x,f(x))=0$ or $Cov(x,f(x))>0$, with the properties assumed for $f(x)$?

Best Answer

This is true for any random variable $X$ (not almost surely constant) and strictly decreasing function $f$ such that the covariance of $X$ and $f(X)$ exists. Let $\mu = \mathbb E[X]$.

$$ \text{Cov}(X, f(X)) = \mathbb E[X f(X)] - \mu \mathbb E[f(X)] = \mathbb E[(X - \mu) f(X)] = \mathbb E[(X - \mu) (f(X)-f(\mu)) $$

But $(x - \mu)(f(x) - f(\mu)) \le 0$, with equality only when $x = \mu$, so $\mathbb E[(X-\mu)(f(X)-f(\mu))] < 0$.

Related Question