pystra.reliability.monte_carlo.CrudeMonteCarlo#
Use it: User guide · Worked example · Theory
- class CrudeMonteCarlo(model, limit_state, *, options=None, point=None, rng=None)[source]#
Bases:
MonteCarloCrude Monte Carlo simulation (CMC).
With the default sampling density, failure probability is the fraction of simulated points classified as failures [Faber2009]. For n points and n_f failures,
\[\tilde{p}_f = \frac{n_f}{n}.\]Finite sampling introduces uncertainty; use the returned sampling coefficient of variation to assess it. A shifted or scaled sampling density uses density-ratio weights instead of unweighted counts.
- Parameters:
model (
StochasticModel) – Named physical variables and their joint probability model.limit_state (
LimitState) – Physical response evaluated at each sample point.options (
SimulationOptions|None) – Sampling, convergence and transformation settings.point (
ArrayLike|None) – Center of the sampling density in standard coordinates; the origin by default.rng (
int|integer|Sequence[int] |ndarray|SeedSequence|BitGenerator|Generator|None) – Random source; NumPy’s global generator is not used. A seed recreates the same stream on every run, a generator advances its own state, and None draws fresh entropy.
Methods
Initialize the model's isoprobabilistic transformation.
Run the simulation and return a
SimulationResult.- init_run()#
Initialize the model’s isoprobabilistic transformation.
Uses the explicit copula or calibrates the legacy Gaussian Nataf correlation. Must be called at the start of every
run()method in subclasses.- Return type:
None