ExpectationProblem
SciMLExpectations.ExpectationProblem — Type
ExpectationProblem(S, g, h, d, params)
ExpectationProblem(g, d, params; nout = nothing)
ExpectationProblem(sm::SystemMap, g, h, d; nout = nothing)
ExpectationProblem(sm::ProcessNoiseSystemMap, g, h; nout = nothing)Represent an expectation of an observable over an uncertainty distribution.
An ExpectationProblem defines the data needed to compute an integral of the form integral g(S(u, p), p) * pdf(d, x) dx, where h(x, u0, p) maps uncertain inputs into initial conditions and parameters for the system map S. The function-only constructor uses identity maps for S and h.
Arguments
S: System map called asS(u, p).g: Observable called asg(u, p)for function problems org(sol, p)for system maps.h: Covariate map called ash(x, u0, p).d: Distribution of uncertain inputs. It must support the operations needed by the chosen expectation algorithm, such aspdf,rand, andextrema.params: Parameters passed to the observable and integration problem.sm: ASystemMaporProcessNoiseSystemMap.nout: Deprecated and unused.
Fields
S: Stored system map.g: Stored observable.h: Stored covariate map.d: Stored uncertainty distribution.params: Stored parameters.
Returns
An ExpectationProblem that can be solved with solve(prob, Koopman()) or solve(prob, MonteCarlo(trajectories)).
SciMLExpectations.SystemMap — Type
SystemMap(prob; kwargs...)
SystemMap(prob, alg; kwargs...)
SystemMap(prob, alg, ensemblealg; kwargs...)Represent the deterministic solution map S(u0, p) for a SciML problem.
Calling a SystemMap remakes prob with the supplied initial condition and parameters, then solves the remade problem.
Arguments
prob: SciML problem used as the template for repeated solves.alg: Solver algorithm. If omitted,solveis called without an explicit algorithm.ensemblealg: Ensemble algorithm used by ensemble-based expectation solves. Defaults toEnsembleThreads().kwargs...: Keyword arguments forwarded tosolve.
Fields
prob: Stored SciML problem.alg: Stored solver algorithm ornothing.ensemblealg: Stored ensemble algorithm.kwargs: Stored solver keyword arguments.
Returns
A callable SystemMap.
SciMLExpectations.ProcessNoiseSystemMap — Type
ProcessNoiseSystemMap(prob, n, args...; kwargs...)Represent a solution map for an SDE whose process noise is parameterized by uncertain expansion coefficients.
Calling a ProcessNoiseSystemMap remakes prob with a Kosambi-Karhunen-Loeve process-noise representation determined by the sampled coefficients and then solves the remade problem.
Arguments
prob: SciML problem used as the template for repeated solves.n: Number of expansion terms in the process-noise representation.args...: Positional arguments forwarded tosolve.kwargs...: Keyword arguments forwarded tosolve.
Fields
prob: Stored SciML problem.n: Stored number of expansion terms.args: Stored solver positional arguments.kwargs: Stored solver keyword arguments.
Returns
A callable ProcessNoiseSystemMap.
SciMLExpectations.GenericDistribution — Type
GenericDistribution(pdf_func, rand_func, lb, ub)
GenericDistribution(d::Distributions.Sampleable, ds...)Represent a distribution by its density, sampler, and integration bounds.
GenericDistribution can be used for arbitrary joint densities and for products of sampleable distributions. The Distributions.Sampleable constructor builds a joint density from independent one-dimensional distributions without relying on Distributions.Product.
Arguments
pdf_func: Function called aspdf_func(x)to evaluate the density.rand_func: Zero-argument function that returns one sample.lb: Lower integration bound.ub: Upper integration bound.d, ds...: Independent sampleable distributions used to build a joint distribution.
Fields
pdf_func: Stored density function.rand_func: Stored sampler.lb: Stored lower bound.ub: Stored upper bound.
Returns
A distribution-like object supporting pdf, rand, minimum, maximum, and extrema.