Class template Dune::XT::Functions::CombinedGridFunction

Inherits from Dune::XT::Functions::GridFunctionInterface.

template<class LeftType, class RightType, class comb>
class Dune::XT::Functions::CombinedGridFunction : public GridFunctionInterface<typename LeftType::E, internal::CombinedHelper<LeftType, RightType, comb>::r, internal::CombinedHelper<LeftType, RightType, comb>::rC, typename internal::CombinedHelper<LeftType, RightType, comb>::R>

Base combined grid function.

using IndicatorType = Functions::IndicatorFunction< …, double>; IndicatorType one( … ); IndicatorType two( … ); // the following code auto difference = one - two; // is equivalent to Difference< IndicatorType, IndicatorType > difference(one, two); // and internal::Combined< IndicatorType, IndicatorType, CombinationType::difference > difference(one, tow);

using IndicatorType = Functions::IndicatorFunction< …, double >; Difference< IndicatorType, IndicatorType > stupid_difference() { IndicatorType one( … ); IndicatorType two( … ); return one - two; }

using IndicatorType = Functions::IndicatorFunction< …, double >; Difference<IndicatorType, IndicatorType> stupid_difference() { auto one = std::make_shared(1); auto two = std::make_shared(2); return Difference<IndicatorType, IndicatorType>(one, two) }

In this situation you are responsible to ensure that the arguments given are valid throughout the lifetime of this class. The following will lead to a segfault:

  • You can pass shared_ptr of the left and right operands to this class. In this case the following is valid:

Note

Most likely you do not want to use this class diretly, but one of Difference, Fraction, Sum or Product.

int Dune::XT::Functions::CombinedGridFunction::local_function() const final

No documentation provided.

ThisType *Dune::XT::Functions::CombinedGridFunction::copy_as_grid_function_impl() const override

No documentation provided.

int Dune::XT::Functions::CombinedGridFunction::copy_as_grid_function() const

No documentation provided.

std::string Dune::XT::Functions::CombinedGridFunction::name() const final

No documentation provided.

template<>
Dune::XT::Functions::CombinedGridFunction::CombinedGridFunction<LeftType, RightType, comb>(const LeftType &left, const RightType &right, const std::string nm = <recovery-expr>(""), const std::string &logging_prefix = <recovery-expr>(""), const std::array<bool, 3> &logging_state = <recovery-expr>())

No documentation provided.

template<>
Dune::XT::Functions::CombinedGridFunction::CombinedGridFunction<LeftType, RightType, comb>(LeftType *&&left, RightType *&&right, const std::string nm = <recovery-expr>(""), const std::string &logging_prefix = <recovery-expr>(""), const std::array<bool, 3> &logging_state = <recovery-expr>())

No documentation provided.

template<>
Dune::XT::Functions::CombinedGridFunction::CombinedGridFunction<LeftType, RightType, comb>(int &&left, int &&right, const std::string nm = <recovery-expr>(""), const std::string &logging_prefix = <recovery-expr>(""), const std::array<bool, 3> &logging_state = <recovery-expr>())

No documentation provided.

template<>
Dune::XT::Functions::CombinedGridFunction::CombinedGridFunction<LeftType, RightType, comb>(const ThisType &other)

No documentation provided.

template<>
Dune::XT::Functions::CombinedGridFunction::CombinedGridFunction<LeftType, RightType, comb>(ThisType &&source) noexcept = default

No documentation provided.

int Dune::XT::Functions::CombinedGridFunction::left_

No documentation provided.

int Dune::XT::Functions::CombinedGridFunction::right_

No documentation provided.

const std::string Dune::XT::Functions::CombinedGridFunction::name_

No documentation provided.

type Dune::XT::Functions::CombinedGridFunction::ThisType

No documentation provided.

type Dune::XT::Functions::CombinedGridFunction::BaseType

No documentation provided.

type Dune::XT::Functions::CombinedGridFunction::ElementType

No documentation provided.

type Dune::XT::Functions::CombinedGridFunction::LocalFunctionType

No documentation provided.