Skip to contents

Compute surface and flow for a matrix of openings

Usage

compute_exchange(exchange)

Arguments

exchange

matrix, containing informations for openings. See details.

Value

matrix of surface and flow for each openings.

Details

compute_exchange() computes wet surfaces and flows for a matrix of openings.

The matrix must be organized as follows:

  • columns give informations for openings (pssibly named, butnot mandatory)

  • rows give informations for each of those entities (names are mandatory):

    • width: width of the opening in meter

    • z_bottom: absolute altitude of the bottom of the opening in meter

    • z_top: absolute altitude of the top of the opening in meter

    • Cd: coefficient giving the loss of charge (no dimension)

    • z_up: absolute level of water in the 'upward' side of the opening in meter

    • z_down: absolute level of water in the 'downward' side of the opening in meter

compute_exchange() is the R counterpart of rcpp_compute_exchange(). Both functions should give exactly the same numeric results. compute_exchange() is used mainly for testing purposes.