Construct a finite-state, continuous-time birth-death approximation to a Gaussian length diffusion whose drift is supplied by the generalized Schnute growth curve. The returned generator uses the decamod convention: columns are source bins, rows are destination bins, off-diagonal entries are non-negative rates, and every column sums to zero.
Usage
get_growth_generator(
midpoint,
linf,
k,
gshape,
gcv,
gmin = 1e-04,
growth_variance = 1L,
gsigma = NULL,
length_power = -1,
variance_reference_length = 60,
generator_scheme = 1L
)Arguments
- midpoint
Equally spaced length-bin representative values (mm).
- linf
Generalized asymptotic length
Linf(mm), which must exceed every value inmidpointfor the current positive-drift implementation.- k
Generalized growth rate
K(per year).- gshape
Generalized growth shape
gamma.- gcv
Process coefficient controlling the instantaneous diffusion SD.
- gmin
Minimum instantaneous process SD (mm per square-root year).
- growth_variance
Process-SD parameterization; see
get_growth_increment_linf().- gsigma
Process diffusion SD at
variance_reference_length.- length_power
Length-scaling power for the diffusion SD.
- variance_reference_length
Reference length for
gsigma(mm).- generator_scheme
Generator discretisation:
1uses the original upwind drift plus diffusion rates;2uses non-negative moment-matched rates. The latter reproduces the requested infinitesimal variance whenvariance_rate >= drift * bin_width, and otherwise uses the smallest variance possible on the supplied grid.
