Lattice Builder
Software Package for Constructing Rank-1 Lattices
|
Accumulator template. More...
#include <Accumulator.h>
Public Member Functions | |
Accumulator (VAL initialValue) | |
void | accumulate (const VAL &value) |
Feeds a new value to the accumulator. | |
void | accumulate (Real weight, const VAL &value, Real power=1.0) |
Feeds value multiplied by weight to the accumulator. More... | |
const VAL & | value () const |
Returns the current value of the accumulator. | |
VAL & | value () |
Static Public Member Functions | |
static std::string | name () |
Returns the name of the operator implemented by the accumulator. | |
Accumulator template.
OP | Scalar binary operator. For example, Functor::Sum or Functor::Max. |
|
inline |
Feeds value
multiplied by weight
to the accumulator.
weight
is assumed to already be raised at the power power
.
References LatBuilder::Accumulator< OP, VAL >::value().