Did I find the right examples for you? yes no      Crawl my project      Python Jobs

# crv_types.WignerSemicircle

All Samples(1)  |  Call(0)  |  Derive(0)  |  Import(1)
Create a continuous random variable with a Wigner semicircle distribution.

The density of the Wigner semicircle distribution is given by

.. math::
f(x) := \frac2{\pi R^2}\,\sqrt{R^2-x^2}

with :math:x \in [-R,R].

Parameters(more...)


        def WignerSemicircle(name, R):
r"""
Create a continuous random variable with a Wigner semicircle distribution.

The density of the Wigner semicircle distribution is given by

.. math::
f(x) := \frac2{\pi R^2}\,\sqrt{R^2-x^2}

with :math:x \in [-R,R].

Parameters
==========

R : Real number, R > 0, the radius

Returns
=======

A RandomSymbol.

Examples
========

>>> from sympy.stats import WignerSemicircle, density, E
>>> from sympy import Symbol, simplify

>>> R = Symbol("R", positive=True)
>>> z = Symbol("z")

>>> X = WignerSemicircle("x", R)

>>> density(X)(z)
2*sqrt(R**2 - z**2)/(pi*R**2)

>>> E(X)
0

References
==========

..  http://en.wikipedia.org/wiki/Wigner_semicircle_distribution
"""

return rv(name, WignerSemicircleDistribution, (R,))