If a random variable X is given and its distribution admits a probability density function f, then the expected value of X (if the expected value exists) can be calculated as E ⁡ ⁡ [ X ] = ∫ ∫ − − ∞ ∞ ∞ ∞ x f ( x ) d x .