detritus_dynamics: Detritus dynamics

Description Usage Arguments Details Value See Also

View source: R/UR_dynamics.R

Description

Calculates the detritus biomass at the next timestep from the current detritus biomass.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
detritus_dynamics(
  params,
  n,
  n_pp,
  n_other,
  rates,
  t,
  dt,
  detritus_external = params@other_params$UR$detritus_external,
  detritus_proportion = params@other_params$UR$detritus_proportion,
  ...
)

Arguments

detritus_external

Rate of change from external sources

detritus_proportion

Proportion of consumption by fish that flows into the detritus component.

...

Arguments passed on to UR_dynamics

params

A MizerParams object

n

A matrix of current species abundances (species x size)

n_pp

A vector of current plankton abundance by size

n_other

List of abundances of other dynamic components

rates

A list of rates as returned by getRates()

t

Current time

dt

Time step size

Details

The equation for the time evolution of the detritus biomass B is assumed to be of the form

dB/dt = inflow - consumption * B + external

where

This equation is solved analytically to

B(t+dt) = B(t) exp(-consumption * dt) +(inflow + external)/(consumption) * (1 - exp(-consumption * dt)).

This avoids the stability problems that would arise if we used the Euler method to solve the equation numerically.

Value

A single number giving the biomass of detritus at next time step

See Also

Other resource dynamics functions: carrion_dynamics()


gustavdelius/mizerUR documentation built on June 24, 2020, 6:28 p.m.