Commit a332af28 by Martin Reinecke

### cosmetics

parent afac0ec8
 ... @@ -30,8 +30,9 @@ class InverseGammaOperator(Operator): ... @@ -30,8 +30,9 @@ class InverseGammaOperator(Operator): The pdf of the inverse gamma distribution is defined as follows: The pdf of the inverse gamma distribution is defined as follows: .. math :: .. math:: \\frac{q^\\alpha}{\\Gamma(\\alpha)}x^{-\\alpha -1}\\exp \\left(-\\frac{q}{x}\\right) \\frac{q^\\alpha}{\\Gamma(\\alpha)}x^{-\\alpha -1} \\exp \\left(-\\frac{q}{x}\\right) That means that for large x the pdf falls off like :math:`x^(-\\alpha -1)`. That means that for large x the pdf falls off like :math:`x^(-\\alpha -1)`. The mean of the pdf is at :math:`q / (\\alpha - 1)` if :math:`\\alpha > 1`. The mean of the pdf is at :math:`q / (\\alpha - 1)` if :math:`\\alpha > 1`. ... @@ -54,7 +55,8 @@ class InverseGammaOperator(Operator): ... @@ -54,7 +55,8 @@ class InverseGammaOperator(Operator): """ """ def __init__(self, domain, alpha, q, delta=0.001): def __init__(self, domain, alpha, q, delta=0.001): self._domain = self._target = DomainTuple.make(domain) self._domain = self._target = DomainTuple.make(domain) self._alpha, self._q, self._delta = float(alpha), float(q), float(delta) self._alpha, self._q, self._delta = \ float(alpha), float(q), float(delta) self._xmin, self._xmax = -8.2, 8.2 self._xmin, self._xmax = -8.2, 8.2 # Precompute # Precompute xs = np.arange(self._xmin, self._xmax+2*delta, delta) xs = np.arange(self._xmin, self._xmax+2*delta, delta) ... ...
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!