uniform module¶
Class to create a uniform distribution from the SciPy library.
This class inherits from SPDistribution
.
- class gemseo.uncertainty.distributions.scipy.uniform.SPUniformDistribution(variable='x', minimum=0.0, maximum=1.0, dimension=1)[source]
Bases:
SPDistribution
Create a uniform distribution.
Examples
>>> from gemseo.uncertainty.distributions.scipy.uniform import ( ... SPUniformDistribution ... ) >>> distribution = SPUniformDistribution('x', -1, 1) >>> print(distribution) uniform(lower=-1, upper=1)
- Parameters:
variable (str) –
The name of the random variable.
By default it is set to “x”.
minimum (float) –
The minimum of the uniform random variable.
By default it is set to 0.0.
maximum (float) –
The maximum of the uniform random variable.
By default it is set to 1.0.
dimension (int) –
The dimension of the random variable. If greater than 1, the probability distribution is applied to all components of the random variable under the hypothesis that these components are stochastically independent. To be removed in a future version; use a
ComposedDistribution
instead.By default it is set to 1.
- dimension: int
The number of dimensions of the random variable.
- distribution: type
The probability distribution of the random variable.
- distribution_name: str
The name of the probability distribution.
- math_lower_bound: ndarray
The mathematical lower bound of the random variable.
- math_upper_bound: ndarray
The mathematical upper bound of the random variable.
- num_lower_bound: ndarray
The numerical lower bound of the random variable.
- num_upper_bound: ndarray
The numerical upper bound of the random variable.
- standard_parameters: dict[str, str] | None
The standard representation of the parameters of the distribution, used for its string representation.
- transformation: str
The transformation applied to the random variable, e.g. ‘sin(x)’.
- variable_name: str
The name of the random variable.