dRdt: Compute time-derivative for resources

View source: R/fluxes.R

dRdtR Documentation

Compute time-derivative for resources

Description

Compute time-derivative for resources

Usage

dRdt(t, R, params, components = FALSE)

Arguments

t

Time variable

R

A resource state matrix; stored as a vector in column major order

params

Named list; additional parameters, see 'details'

Details

The required params for the resource derivative are as follows:

  • S: a site by species matrix

  • Q: a site by discharge vector

  • A: a site by cross-sectional area vector

  • l: a site by length vector

  • lQ: site by lateral input discharge

  • lR: site by lateral resource concentration

  • i_static: indices of static resources

  • adj: the network adjacency matrix

  • comm: a metacommunity()

  • components: logical, optional, default FALSE

If params$components = TRUE, instead of computing the derivative the function returns the individual components, including the use by species, downstream transport, and input from upstream. The units in this case will be mass/time

Value

Normally, a site by resource matrix of resource fluxes, in units of mass * volume^-1 * time^-1


flee-group/flume documentation built on Jan. 29, 2024, 6:44 p.m.