Hyperbolic secant probability mean proof

49 Views Asked by At

I have the following problem: Show that the mean of the pdf $$ f(x) = \frac{1}{4s} sech^2 (\frac{x-\mu}{2s}) $$ is equal to $\mu$.

I have tried attacking the problem with simply $$ \bar{x} = \int_{-\infty}^{\infty} xf(x)dx$$ but I always end up with $\bar{x} = 0$ and I can't find what's wrong with my integrals (I end up with $ \frac{x}{2} tanh(\frac{x-\mu}{2s}) - s \ln{cosh{\frac{x-\mu}{2s}}} $ ) . Anybody who knows how to solve it?

1

There are 1 best solutions below

0
On BEST ANSWER

$$ \mathbb{E}(x) = \int_{-\infty}^\infty \frac{1}{4s}\mathrm{sech}^2\left(\frac{x-\mu}{2s}\right) $$ firstly lets change variables $t = \frac{x-\mu}{2s}\to dt = \frac{1}{2s}dx$ so we have $$ \int_{-\infty}^\infty x\frac{1}{4s}\mathrm{sech}^2\left(\frac{x-\mu}{2s}\right) = \frac{1}{2}\int_{-\infty}^\infty \left(2st +\mu\right)\mathrm{sech}^2t \,dt $$ we can use the relation $$ \frac{d}{dx}\tanh x = \mathrm{sech}^2 x $$ this leads to $$ \frac{1}{2}\int_{-\infty}^\infty \left(2st +\mu\right)\mathrm{sech}^2t \,dt = \frac{1}{2}\int_{-\infty}^\infty \left(2st +\mu\right)\frac{d}{dt}\tanh t\,dt $$ so we compute $$ \int_{-\infty}^\infty t\frac{d}{dt}\tanh t = \left[t\tanh (t)\right]_{-\infty}^\infty - \int_{-\infty}^\infty \tanh (t) \,dt $$ Since we have $$ \tanh(-x) = -\tanh(x) $$ i.e odd function with another odd function $$ -t\tanh(-t) = -t\cdot -\tanh(t) = t\tanh(t) $$ we have an even function which for symmetric bounds vanishes the term in the brackets. The integral left is $$ \int_{-\infty}^\infty \tanh (t) dt $$ we can use a similar argument $$ \int_{-\infty}^0 \tanh (t) dt + \int_{0}^\infty\tanh (t) dt $$ change of variables for the first integral $$ \int_{\infty}^0 \tanh(-t) (-dt) = -\int_{\infty}^0 \tanh(-t)dt = \int_0^\infty \tanh(-t)dt = -\int_0^\infty \tanh(t)dt $$ so $$ \int_{-\infty}^\infty \tanh (t) dt = -\int_0^\infty \tanh(t)dt + \int_{0}^\infty\tanh (t) dt = 0 $$ this leaves us with $$ \frac{1}{2}\int_{-\infty}^\infty \left(2st +\mu\right)\frac{d}{dt}\tanh t\,dt = s\int_{-\infty}^\infty t\frac{d}{dt}\tanh t\,dt + \frac{1}{2}\mu \int_{-\infty}^\infty \frac{d}{dt}\tanh t\,dt = \frac{1}{2}\mu \left[\tanh(t)\right]_{-\infty}^\infty $$ using the similar argument again $$ \frac{1}{2}\mu \left[\tanh(\infty) - \tanh(-\infty)\right] = \frac{1}{2}\mu\left[1 -(-1)\right] = \mu. $$