2.3.3. sdepy.poisson_source¶
-
class
sdepy.poisson_source(*, paths=1, vshape=(), dtype=<class 'int'>, lam=1.0)[source]¶ dn, a source of Poisson process increments.
Parameters: - paths : int
Number of paths (last dimension) of the source realizations.
- vshape : tuple of int
Shape of source values.
- dtype : data-type
Data type of source values. Defaults to
int.- lam : array-like, or callable
Intensity of the Poisson process, possibly time-dependent. Should be an array of non-negative values, broadcastable to shape
vshape + (paths,), or a callable withlam(t)evaluating to such array.
Returns: - array
Once instantiated as
dn,dn(t, dt)returns a random realization of Poisson process increments from timetto timet + dt, with shape(t + dt).shape + vshape + (paths,). The increments are independent Poisson variates with meanlam*dt, orlam(t + dt/2)*dt(the latter approximates the integral oflam(t)fromttot + dt).
See also
Attributes: Methods
__call__(t, dt)See poisson_source class documentation.