compose(3rheolef)

compose3rheolef

N-ary function application in expressions (rheolef-7.2)

Usage

template <class Function, class... Expressions>
Expression compose (const Function& f, const Expressions&... exprs);

Overview

Compose a n-ary function f with n fields in interpolate(3) and integrate(3) nonlinear expressions.

Examples

The compose operator is used for applying a user-provided function to a field:

    Float f (Float u) { return 1/u + sqrt(u); }
    ...
    field vh = interpolate (Xh, compose(f, uh));

When two arguments are involved:

    Float g (Float u, Float v) { return v/u + sqrt(u*v); }
    ...
    field wh = interpolate (Xh, compose(g, uh, vh));

The compose operator supports general n-ary functions and class-functions.

Characteristic

The compose function supports also the method of characteristic(2) used e.g. for convection-diffusion problems:

    characteristic X (-delta_t*uh);
    test v (Xh);
    field lh = integrate (compose(uh,X)*v);

Implementation

This documentation has been generated from file main/lib/compose.h

Releases

3 releases since Debian 11 (Bullseye); the text changed 2 times.

  1. 11
  2. 12
  3. 13

Author

Pierre Saramito <[email protected]>

From librheolef-dev 7.2-4 in Debian 13 (Trixie). Parsed by carta from the page's man source.