Loading...
Searching...
No Matches
field_expr_quadrature.h
Go to the documentation of this file.
#ifndef _RHEOLEF_FIELD_EXPR_QUADRATURE_H
#define _RHEOLEF_FIELD_EXPR_QUADRATURE_H
//
// variational expressions are integrated by using a quadrature formulae
//
// author: Pierre.Saramito@imag.fr
//
// date: 16 december 2018
//
// SUMMARY:
// 1. concept
// 2. terminals
// 2.1. integration on one element K
// 2.2. integration on element boundary partial K
// 3. unary function
// 2.1. unary node
// 2.2. unary calls
// 4. binary operators +- between two integrated fields
// 3.1. binary node
// 3.2. binary calls
// 5. binary operators */ between a integrated field and a constant
//
#include "rheolef/field_expr_variational.h"
#include "rheolef/field_expr_variational_terminal.h"
#include "rheolef/init_expr_quadrature.h"
namespace rheolef {
// -------------------------------------------------------------------
// 1. concept
// -------------------------------------------------------------------
namespace details {
// Define a trait type for detecting field expression valid arguments
template<class T> struct is_field_expr_quadrature_arg: std::false_type {};
} // namespace details
// ---------------------------------------------------------------------------
// 2. terminals
// ---------------------------------------------------------------------------
// 2.1. integration on one element K
// ---------------------------------------------------------------------------
namespace details {
template<class Expr>
class field_expr_quadrature_on_element {
public:
// typedefs:
typedef geo_element::size_type size_type;
typedef typename Expr::memory_type memory_type;
typedef typename Expr::value_type result_hint;
typedef typename Expr::value_type value_type;
typedef typename scalar_traits<value_type>::type scalar_type;
typedef typename float_traits<value_type>::type float_type;
typedef space_basic<float_type,memory_type> space_type;
typedef geo_basic <float_type,memory_type> geo_type;
typedef typename Expr::vf_tag_type vf_tag_type;
typedef typename details::dual_vf_tag<vf_tag_type>::type
vf_dual_tag_type;
typedef field_expr_quadrature_on_element<Expr> self_type;
typedef field_expr_quadrature_on_element<typename Expr::dual_self_type>
dual_self_type;
static const space_constant::valued_type valued_hint = space_constant::valued_tag_traits<value_type>::value;
// allocators:
template<class Sfinae = typename std::enable_if<is_field_expr_v2_variational_arg<Expr>::value, Expr>::type>
field_expr_quadrature_on_element (const Expr& expr);
// mutable modifiers:
void initialize (const geo_basic<float_type,memory_type>& omega_K, const integrate_option& iopt);
void initialize (const band_basic<float_type,memory_type>& gh, const integrate_option& iopt);
// accessors:
const space_type& get_vf_space() const { return _expr.get_vf_space(); }
size_type n_derivative() const { return _expr.n_derivative(); }
template<class Value>
void evaluate (
const geo_basic<float_type,memory_type>& omega_K,
const geo_element& K,
Eigen::Matrix<Value,Eigen::Dynamic,1>& lk) const;
template<class Value>
void valued_check() const {
if (! is_undeterminated<Value>::value) { _expr.template valued_check<Value>(); }
}
protected:
// data:
Expr _expr;
mutable piola_on_pointset<float_type> _pops;
};
template<class Expr> struct is_field_expr_quadrature_arg <field_expr_quadrature_on_element<Expr> > : std::true_type {};
// ---------------------------------------------------------------------------
// inlined
// ---------------------------------------------------------------------------
template<class Expr>
template<class Sfinae>
inline
field_expr_quadrature_on_element<Expr>::field_expr_quadrature_on_element (const Expr& expr)
: _expr(expr),
_pops()
{
}
template<class Expr>
void
field_expr_quadrature_on_element<Expr>::initialize (
const geo_basic<float_type,memory_type>& omega_K,
const integrate_option& iopt)
{
integrate_option new_iopt = expr_quadrature_init_iopt (omega_K, get_vf_space(), n_derivative(), iopt);
quadrature<float_type> quad = expr_quadrature_init_quad<float_type> (new_iopt);
_pops.initialize (omega_K.get_piola_basis(), quad, new_iopt);
_expr.initialize (_pops, new_iopt);
}
template<class Expr>
void
field_expr_quadrature_on_element<Expr>::initialize (
const band_basic<float_type,memory_type>& gh,
const integrate_option& iopt)
{
integrate_option new_iopt = expr_quadrature_init_iopt (gh.band(), get_vf_space(), n_derivative(), iopt);
quadrature<float_type> quad = expr_quadrature_init_quad<float_type> (new_iopt);
_pops.initialize (gh.band().get_piola_basis(), quad, new_iopt);
_expr.initialize (gh, _pops, new_iopt);
}
template<class Expr>
template<class Value>
void
field_expr_quadrature_on_element<Expr>::evaluate (
const geo_basic<float_type,memory_type>& omega_K,
const geo_element& K,
Eigen::Matrix<Value,Eigen::Dynamic,1>& lk) const
{
Eigen::Matrix<float_type,Eigen::Dynamic,Eigen::Dynamic> phij_xi;
const Eigen::Matrix<float_type,Eigen::Dynamic,1>& w = _pops.get_weight (omega_K, K);
_expr.evaluate (omega_K, K, phij_xi);
// blas2: lk(j) = sum_i phi_j(xi)*w(xi) = trans(phi)*w ; TODO: DVT_EIGEN_BLAS2
size_t ni = phij_xi.rows();
size_t nj = phij_xi.cols();
lk.resize (nj);
for (size_t j = 0; j < nj; ++j) {
Value sum = 0;
for (size_t i = 0; i < ni; ++i) {
sum += w[i] * phij_xi(i,j);
}
lk[j] = sum;
}
}
} // namespace details
// ---------------------------------------------------------------------------
// 2.2. integration on element boundary partial K
// ---------------------------------------------------------------------------
namespace details {
template<class Expr>
class field_expr_quadrature_on_sides {
public:
// typedefs:
typedef geo_element::size_type size_type;
typedef typename Expr::memory_type memory_type;
typedef typename Expr::value_type result_hint;
typedef typename Expr::value_type value_type;
typedef typename scalar_traits<value_type>::type scalar_type;
typedef typename float_traits<value_type>::type float_type;
typedef space_basic<float_type,memory_type> space_type;
typedef geo_basic <float_type,memory_type> geo_type;
typedef typename Expr::vf_tag_type vf_tag_type;
typedef typename details::dual_vf_tag<vf_tag_type>::type
vf_dual_tag_type;
typedef field_expr_quadrature_on_sides<Expr> self_type;
typedef field_expr_quadrature_on_sides<typename Expr::dual_self_type>
dual_self_type;
static const space_constant::valued_type valued_hint = space_constant::valued_tag_traits<value_type>::value;
// alocators:
template<class Sfinae = typename std::enable_if<is_field_expr_v2_variational_arg<Expr>::value, Expr>::type>
field_expr_quadrature_on_sides (const Expr& expr);
// accessors:
const space_type& get_vf_space() const { return _expr.get_vf_space(); }
size_type n_derivative() const { return _expr.n_derivative(); }
// mutable modifiers:
void initialize (const geo_basic<float_type,memory_type>& omega_K, const integrate_option& iopt);
void initialize (const band_basic<float_type,memory_type>& gh, const integrate_option& iopt);
template<class Value>
void evaluate (
const geo_basic<float_type,memory_type>& omega_K,
const geo_element& K,
Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const;
template<class Value>
void valued_check() const {
typedef Value A1;
if (! is_undeterminated<A1>::value) { _expr.template valued_check<A1>(); }
}
protected:
// data:
mutable Expr _expr;
mutable piola_on_pointset<float_type> _pops;
mutable bool _ignore_sys_coord;
// working variables:
mutable Eigen::Matrix<float_type,Eigen::Dynamic,Eigen::Dynamic> _value_i;
mutable std::vector<size_type> _dis_inod_S;
mutable tensor_basic<float_type> _DF;
};
template<class Expr> struct is_field_expr_quadrature_arg <field_expr_quadrature_on_sides<Expr> > : std::true_type {};
// ---------------------------------------------------------------------------
// inlined
// ---------------------------------------------------------------------------
template<class Expr>
template<class Sfinae>
inline
field_expr_quadrature_on_sides<Expr>::field_expr_quadrature_on_sides (const Expr& expr)
: _expr(expr),
_pops(),
_ignore_sys_coord(false),
_value_i(),
_dis_inod_S(),
_DF()
{
}
template<class Expr>
void
field_expr_quadrature_on_sides<Expr>::initialize (const geo_basic<float_type,memory_type>& omega_K, const integrate_option& iopt)
{
_ignore_sys_coord = iopt.ignore_sys_coord;
integrate_option new_iopt = expr_quadrature_init_iopt (omega_K, get_vf_space(), n_derivative(), iopt);
quadrature<float_type> quad = expr_quadrature_init_quad<float_type> (new_iopt);
new_iopt._is_inside_on_local_sides = true; // propagated recursively in expression
_pops.initialize (omega_K.get_piola_basis(), quad, new_iopt);
_expr.initialize (_pops, new_iopt);
}
template<class Expr>
void
field_expr_quadrature_on_sides<Expr>::initialize (const band_basic<float_type,memory_type>& gh, const integrate_option& iopt)
{
_ignore_sys_coord = iopt.ignore_sys_coord;
integrate_option new_iopt = expr_quadrature_init_iopt (gh.band(), get_vf_space(), n_derivative(), iopt);
quadrature<float_type> quad = expr_quadrature_init_quad<float_type> (new_iopt);
new_iopt._is_inside_on_local_sides = true; // propagated recursively in expression
_pops.initialize (gh.band().get_piola_basis(), quad, new_iopt);
_expr.initialize (gh, _pops, new_iopt);
fatal_macro("on_local_sides: banded level set not yet supported, sorry");
}
template<class Expr>
template<class Value>
void
field_expr_quadrature_on_sides<Expr>::evaluate (
const geo_basic<float_type,memory_type>& omega_K,
const geo_element& K,
Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const
{
bool do_local_component_assembly = true;
size_type sid_dim = K.dimension()-1;
for (size_type isid = 0, nsid = K.n_subgeo(sid_dim); isid < nsid; ++isid) {
size_type dis_isid = (K.dimension() == 1) ? K[isid] : (K.dimension() == 2) ? K.edge(isid) : K.face(isid);
const geo_element& S = omega_K.dis_get_geo_element (sid_dim, dis_isid);
side_information_type sid;
K.get_side_informations (S, sid);
_expr.evaluate_on_side (omega_K, K, sid, _value_i, do_local_component_assembly);
const Eigen::Matrix<float_type,Eigen::Dynamic,1>& w = _pops.get_weight (omega_K, S);
// blas2: lk(j) = sum_S sum_i phi_j(xi)*w(xi) = sum_S trans(phi)*w ; TODO: DVT_EIGEN_BLAS2
size_t ni = _value_i.rows();
size_t nj = _value_i.cols();
if (isid == 0) {
value = Eigen::Matrix<Value,Eigen::Dynamic,1>::Zero(nj, 1);
}
for (size_t j = 0; j < nj; ++j) {
Value sum = 0;
for (size_t i = 0; i < ni; ++i) {
sum += w[i] * _value_i(i,j);
}
value[j] += sum;
}
}
}
} // namespace details
template<class Expr>
inline
typename
std::enable_if<
details::is_field_expr_v2_variational_arg<Expr>::value
,details::field_expr_quadrature_on_sides<Expr>
>::type
on_local_sides (const Expr& expr)
{
return details::field_expr_quadrature_on_sides<Expr>(expr);
}
#ifdef TODO
// ---------------------------------------------------------------------------
// 3. unary function
// ---------------------------------------------------------------------------
// 3.1. unary node
// ---------------------------------------------------------------------------
namespace details {
template<class UnaryFunction, class Expr>
class field_expr_quadrature_unary {
public:
// typedefs:
typedef geo_element::size_type size_type;
typedef typename Expr::memory_type memory_type;
typedef typename details::generic_unary_traits<UnaryFunction>::template result_hint<
typename Expr::value_type>::type result_hint;
typedef typename details::generic_unary_traits<UnaryFunction>::template hint<
typename Expr::value_type
,result_hint>::result_type value_type;
typedef typename scalar_traits<value_type>::type scalar_type;
typedef typename float_traits<value_type>::type float_type;
typedef space_basic<float_type,memory_type> space_type;
typedef geo_basic <float_type,memory_type> geo_type;
typedef typename Expr::vf_tag_type vf_tag_type;
typedef typename details::dual_vf_tag<vf_tag_type>::type
vf_dual_tag_type;
typedef field_expr_quadrature_unary<UnaryFunction,Expr> self_type;
typedef field_expr_quadrature_unary<UnaryFunction, typename Expr::dual_self_type>
dual_self_type;
static const space_constant::valued_type valued_hint = space_constant::valued_tag_traits<value_type>::value;
// alocators:
template<class Sfinae = typename std::enable_if<is_field_expr_quadrature_arg<Expr>::value, Expr>::type>
field_expr_quadrature_unary (const UnaryFunction& f, const Expr& expr)
: _f(f), _expr(expr) {}
// accessors:
const space_type& get_vf_space() const { return _expr.get_vf_space(); }
size_type n_derivative() const { return _expr.n_derivative(); }
// mutable modifiers:
void initialize (const geo_basic<float_type,memory_type>& omega_K, const integrate_option& iopt) {
return _expr.initialize (omega_K, iopt); }
void initialize (const band_basic<float_type,memory_type>& gh, const integrate_option& iopt) {
return _expr.initialize (gh, iopt); }
template<class Value>
void evaluate (const geo_element& K, Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const {
typedef Value A1; // Value is float_type in general: elementary matrix
_expr.evaluate (K, value);
for (size_type i = 0, ni = value.rows(); i < ni; ++i) {
for (size_type j = 0, nj = value.cols(); j < nj; ++j) {
value(i,j) = _f (value(i,j));
}}
}
template<class Value>
void valued_check() const {
typedef Value A1;
if (! is_undeterminated<A1>::value) { _expr.template valued_check<A1>(); }
}
protected:
// data:
UnaryFunction _f;
Expr _expr;
};
template<class F, class Expr> struct is_field_expr_quadrature_arg <field_expr_quadrature_unary<F,Expr> > : std::true_type {};
} // namespace details
// ---------------------------------------------------------------------------
// 3.2. unary calls
// ---------------------------------------------------------------------------
#define _RHEOLEF_make_field_expr_quadrature_unary(FUNCTION,FUNCTOR) \
template<class Expr> \
inline \
typename \
std::enable_if< \
details::is_field_expr_quadrature_arg<Expr>::value \
,details::field_expr_quadrature_unary< \
FUNCTOR \
,Expr \
> \
>::type \
FUNCTION (const Expr& expr) \
{ \
return details::field_expr_quadrature_unary <FUNCTOR,Expr> (FUNCTOR(), expr); \
}
_RHEOLEF_make_field_expr_quadrature_unary (operator+, details::unary_plus)
_RHEOLEF_make_field_expr_quadrature_unary (operator-, details::negate)
#undef _RHEOLEF_make_field_expr_quadrature_unary
#endif // TODO
// ---------------------------------------------------------------------------
// 4. binary operators +- between two integrated fields
// ---------------------------------------------------------------------------
// 4.1. binary node
// ---------------------------------------------------------------------------
// example: operator+ between two fields as in
// (u*v) + on_local_sides(u*v)
namespace details {
template<class BinaryFunction, class Expr1, class Expr2>
class field_expr_quadrature_binary {
public:
// typedefs:
typedef geo_element::size_type size_type;
typedef typename promote_memory<typename Expr1::memory_type,typename Expr2::memory_type>::type
memory_type;
typedef typename details::generic_binary_traits<BinaryFunction>::template result_hint<
typename Expr1::value_type
,typename Expr2::value_type>::type result_hint;
typedef typename details::generic_binary_traits<BinaryFunction>::template hint<
typename Expr1::value_type
,typename Expr2::value_type
,result_hint>::result_type value_type;
typedef typename scalar_traits<value_type>::type scalar_type;
typedef typename float_traits<value_type>::type float_type;
typedef space_basic<float_type,memory_type> space_type;
typedef geo_basic <float_type,memory_type> geo_type;
typedef typename details::bf_vf_tag<BinaryFunction,
typename Expr1::vf_tag_type,
typename Expr2::vf_tag_type>::type vf_tag_type;
typedef typename details::dual_vf_tag<vf_tag_type>::type
vf_dual_tag_type;
typedef field_expr_quadrature_binary<BinaryFunction,Expr1,Expr2> self_type;
typedef field_expr_quadrature_binary<BinaryFunction,typename Expr1::dual_self_type,
typename Expr2::dual_self_type>
dual_self_type;
static const space_constant::valued_type valued_hint = space_constant::valued_tag_traits<value_type>::value;
// alocators:
#ifdef TODO
template<class Sfinae
= typename std::enable_if<
is_field_expr_quadrature_arg<Expr1>::value && is_field_expr_quadrature_arg<Expr2>::value
,Expr1
>::type
>
#endif // TODO
field_expr_quadrature_binary (const BinaryFunction& f,
const Expr1& expr1,
const Expr2& expr2)
: _f(f), _expr1(expr1), _expr2(expr2) {}
// accessors:
const space_type& get_vf_space() const { return _expr1.get_vf_space(); }
size_type n_derivative() const { return std::min(_expr1.n_derivative(), _expr2.n_derivative()); }
// mutable modifiers:
void initialize (const geo_basic<float_type,memory_type>& omega_K, const integrate_option& iopt) {
_expr1.initialize (omega_K, iopt);
_expr2.initialize (omega_K, iopt);
}
void initialize (const band_basic<float_type,memory_type>& gh, const integrate_option& iopt) {
_expr1.initialize (gh, iopt);
_expr2.initialize (gh, iopt);
}
template<class Value>
void evaluate (
const geo_basic<float_type,memory_type>& omega_K,
const geo_element& K,
Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const
{
// Value is float_type in general: elementary matrix
// for f=operator+ => sum of two elementary matrix of the same type
// TODO: otherwise Value and 2 could be obtained from the hint<> helper
typedef Value A1;
typedef Value A2;
Eigen::Matrix<A2,Eigen::Dynamic,1> value2 (value.size());
_expr1.evaluate (omega_K, K, value);
_expr2.evaluate (omega_K, K, value2);
for (size_type i = 0, ni = value.size(); i < ni; ++i) {
value[i] = _f (value[i], value2[i]);
}
}
template<class Value>
void valued_check() const {
typedef Value A1;
typedef Value A2;
if (! is_undeterminated<A1>::value) { _expr1.template valued_check<A1>(); }
if (! is_undeterminated<A2>::value) { _expr2.template valued_check<A2>(); }
}
protected:
// data:
BinaryFunction _f;
Expr1 _expr1;
Expr2 _expr2;
};
template<class F, class Expr1, class Expr2> struct is_field_expr_quadrature_arg <field_expr_quadrature_binary<F,Expr1,Expr2> > : std::true_type {};
} // namespace details
// ---------------------------------------------------------------------------
// 4.2. binary calls
// ---------------------------------------------------------------------------
// expr_quad := expr_quad +- expr_quad
// expr_quad := expr_var +- expr_quad
// expr_quad := expr_quad +- expr_var
#define _RHEOLEF_field_expr_quadrature_binary(FUNCTION,FUNCTOR) \
template <class Expr1, class Expr2> \
inline \
typename \
std::enable_if< \
details::is_field_expr_quadrature_arg <Expr1>::value \
&& details::is_field_expr_quadrature_arg <Expr2>::value \
,details::field_expr_quadrature_binary< \
FUNCTOR \
,Expr1 \
,Expr2 \
> \
>::type \
FUNCTION (const Expr1& expr1, const Expr2& expr2) \
{ \
return details::field_expr_quadrature_binary \
<FUNCTOR, Expr1, Expr2> \
(FUNCTOR(), expr1, expr2); \
} \
template <class Expr1, class ExprVar2> \
inline \
typename \
std::enable_if< \
details::is_field_expr_quadrature_arg <Expr1>::value \
&& details::is_field_expr_v2_variational_arg <ExprVar2>::value \
,details::field_expr_quadrature_binary< \
FUNCTOR \
,Expr1 \
,details::field_expr_quadrature_on_element<ExprVar2> \
> \
>::type \
FUNCTION (const Expr1& expr1, const ExprVar2& expr_var2) \
{ \
using Expr2 = details::field_expr_quadrature_on_element<ExprVar2>; \
return details::field_expr_quadrature_binary \
<FUNCTOR, Expr1, Expr2> \
(FUNCTOR(), expr1, Expr2(expr_var2)); \
} \
template <class ExprVar1, class Expr2> \
inline \
typename \
std::enable_if< \
details::is_field_expr_v2_variational_arg <ExprVar1>::value \
&& details::is_field_expr_quadrature_arg <Expr2>::value \
,details::field_expr_quadrature_binary< \
FUNCTOR \
,details::field_expr_quadrature_on_element<ExprVar1> \
,Expr2 \
> \
>::type \
FUNCTION (const ExprVar1& expr_var1, const Expr2& expr2) \
{ \
using Expr1 = details::field_expr_quadrature_on_element<ExprVar1>; \
return details::field_expr_quadrature_binary \
<FUNCTOR, Expr1, Expr2> \
(FUNCTOR(), Expr1(expr_var1), expr2); \
} \
_RHEOLEF_field_expr_quadrature_binary (operator+, details::plus)
_RHEOLEF_field_expr_quadrature_binary (operator-, details::minus)
#undef _RHEOLEF_field_expr_quadrature_binary
// ---------------------------------------------------------------------------
// 5. binary operators */ between a integrated field and a constant
// ---------------------------------------------------------------------------
// expr_quad := k*expr_quad
// expr_quad := expr_quad*k
// expr_quad := expr_quad/k
#ifdef TODO
namespace details {
template<class Expr1, class Expr2, class Sfinae = void>
struct is_field_expr_quadrature_binary_multiplies_divides_constant_left : std::false_type {};
template<class Expr1, class Expr2>
struct is_field_expr_quadrature_binary_multiplies_divides_constant_left <
Expr1
,Expr2
,typename
std::enable_if<
is_rheolef_arithmetic <Expr1>::value
&& is_field_expr_quadrature_arg<Expr2>::value
>::type
>
: std::true_type
{};
template<class Expr1, class Expr2>
struct is_field_expr_quadrature_binary_multiplies_divides_constant_right
: is_field_expr_quadrature_binary_multiplies_divides_constant_left <Expr2,Expr1> {};
} // namespace details
#define _RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_left(FUNCTION,FUNCTOR) \
template<class Expr1, class Expr2> \
inline \
typename \
std::enable_if< \
details::is_field_expr_quadrature_binary_multiplies_divides_constant_left <Expr1,Expr2>::value \
,details::field_expr_quadrature_unary< \
details::binder_first <FUNCTOR, Expr1> \
,Expr2 /* vf */ \
> \
>::type \
FUNCTION (const Expr1& expr1, const Expr2& expr2) \
{ \
return details::field_expr_quadrature_unary \
<details::binder_first <FUNCTOR,Expr1>, Expr2> \
(details::binder_first <FUNCTOR,Expr1> (FUNCTOR(), expr1), expr2); \
}
#define _RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_right(FUNCTION,FUNCTOR) \
template<class Expr1, class Expr2> \
inline \
typename \
std::enable_if< \
details::is_field_expr_quadrature_binary_multiplies_divides_constant_right <Expr1,Expr2>::value \
,details::field_expr_quadrature_unary< \
details::binder_second <FUNCTOR, Expr2> \
,Expr1 /* vf */ \
> \
>::type \
FUNCTION (const Expr1& expr1, const Expr2& expr2) \
{ \
return details::field_expr_quadrature_unary \
<details::binder_second <FUNCTOR,Expr2>, Expr1> \
(details::binder_second <FUNCTOR,Expr2> (FUNCTOR(), expr2), expr1); \
}
#define _RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant(FUNCTION,FUNCTOR) \
_RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_left (FUNCTION,FUNCTOR) \
_RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_right (FUNCTION,FUNCTOR)
_RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant (operator*, details::multiplies)
_RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_right (operator/, details::divides)
#undef _RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_right
#undef _RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant_left
#undef _RHEOLEF_make_field_expr_quadrature_binary_operator_multiplies_divides_constant
#endif // TODO
} // namespace rheolef
#endif // _RHEOLEF_FIELD_EXPR_QUADRATURE_H
size_type
field::size_type size_type
Definition branch.cc:430
gh
field gh(Float epsilon, Float t, const field &uh, const test &v)
Definition burgers_diffusion_operators.icc:37
rheolef::band_basic
Definition band.h:95
rheolef::details::field_expr_quadrature_binary
Definition field_expr_quadrature.h:437
rheolef::details::field_expr_quadrature_binary::initialize
void initialize(const band_basic< float_type, memory_type > &gh, const integrate_option &iopt)
Definition field_expr_quadrature.h:490
rheolef::details::field_expr_quadrature_binary::geo_type
geo_basic< float_type, memory_type > geo_type
Definition field_expr_quadrature.h:454
rheolef::details::field_expr_quadrature_binary::_expr1
Expr1 _expr1
Definition field_expr_quadrature.h:522
rheolef::details::field_expr_quadrature_binary::dual_self_type
field_expr_quadrature_binary< BinaryFunction, typename Expr1::dual_self_type, typename Expr2::dual_self_type > dual_self_type
Definition field_expr_quadrature.h:463
rheolef::details::field_expr_quadrature_binary::_expr2
Expr2 _expr2
Definition field_expr_quadrature.h:523
rheolef::details::field_expr_quadrature_binary::space_type
space_basic< float_type, memory_type > space_type
Definition field_expr_quadrature.h:453
rheolef::details::field_expr_quadrature_binary::result_hint
details::generic_binary_traits< BinaryFunction >::template result_hint< typenameExpr1::value_type, typenameExpr2::value_type >::type result_hint
Definition field_expr_quadrature.h:446
rheolef::details::field_expr_quadrature_binary::initialize
void initialize(const geo_basic< float_type, memory_type > &omega_K, const integrate_option &iopt)
Definition field_expr_quadrature.h:486
rheolef::details::field_expr_quadrature_binary::evaluate
void evaluate(const geo_basic< float_type, memory_type > &omega_K, const geo_element &K, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value) const
Definition field_expr_quadrature.h:495
rheolef::details::field_expr_quadrature_binary::valued_check
void valued_check() const
Definition field_expr_quadrature.h:513
rheolef::details::field_expr_quadrature_binary::self_type
field_expr_quadrature_binary< BinaryFunction, Expr1, Expr2 > self_type
Definition field_expr_quadrature.h:460
rheolef::details::field_expr_quadrature_binary::vf_tag_type
details::bf_vf_tag< BinaryFunction, typenameExpr1::vf_tag_type, typenameExpr2::vf_tag_type >::type vf_tag_type
Definition field_expr_quadrature.h:457
rheolef::details::field_expr_quadrature_binary::valued_hint
static const space_constant::valued_type valued_hint
Definition field_expr_quadrature.h:464
rheolef::details::field_expr_quadrature_binary::n_derivative
size_type n_derivative() const
Definition field_expr_quadrature.h:483
rheolef::details::field_expr_quadrature_binary::vf_dual_tag_type
details::dual_vf_tag< vf_tag_type >::type vf_dual_tag_type
Definition field_expr_quadrature.h:459
rheolef::details::field_expr_quadrature_binary::field_expr_quadrature_binary
field_expr_quadrature_binary(const BinaryFunction &f, const Expr1 &expr1, const Expr2 &expr2)
Definition field_expr_quadrature.h:475
rheolef::details::field_expr_quadrature_binary::_f
BinaryFunction _f
Definition field_expr_quadrature.h:521
rheolef::details::field_expr_quadrature_binary::scalar_type
scalar_traits< value_type >::type scalar_type
Definition field_expr_quadrature.h:451
rheolef::details::field_expr_quadrature_binary::value_type
details::generic_binary_traits< BinaryFunction >::template hint< typenameExpr1::value_type, typenameExpr2::value_type, result_hint >::result_type value_type
Definition field_expr_quadrature.h:450
rheolef::details::field_expr_quadrature_binary::memory_type
promote_memory< typenameExpr1::memory_type, typenameExpr2::memory_type >::type memory_type
Definition field_expr_quadrature.h:443
rheolef::details::field_expr_quadrature_binary::float_type
float_traits< value_type >::type float_type
Definition field_expr_quadrature.h:452
rheolef::details::field_expr_quadrature_binary::size_type
geo_element::size_type size_type
Definition field_expr_quadrature.h:441
rheolef::details::field_expr_quadrature_binary::get_vf_space
const space_type & get_vf_space() const
Definition field_expr_quadrature.h:482
rheolef::details::field_expr_quadrature_on_element
Definition field_expr_quadrature.h:67
rheolef::details::field_expr_quadrature_on_element::geo_type
geo_basic< float_type, memory_type > geo_type
Definition field_expr_quadrature.h:78
rheolef::details::field_expr_quadrature_on_element::space_type
space_basic< float_type, memory_type > space_type
Definition field_expr_quadrature.h:77
rheolef::details::field_expr_quadrature_on_element::initialize
void initialize(const geo_basic< float_type, memory_type > &omega_K, const integrate_option &iopt)
Definition field_expr_quadrature.h:132
rheolef::details::field_expr_quadrature_on_element::valued_check
void valued_check() const
Definition field_expr_quadrature.h:109
rheolef::details::field_expr_quadrature_on_element::dual_self_type
field_expr_quadrature_on_element< typename Expr::dual_self_type > dual_self_type
Definition field_expr_quadrature.h:84
rheolef::details::field_expr_quadrature_on_element::valued_hint
static const space_constant::valued_type valued_hint
Definition field_expr_quadrature.h:85
rheolef::details::field_expr_quadrature_on_element::n_derivative
size_type n_derivative() const
Definition field_expr_quadrature.h:100
rheolef::details::field_expr_quadrature_on_element::vf_dual_tag_type
details::dual_vf_tag< vf_tag_type >::type vf_dual_tag_type
Definition field_expr_quadrature.h:81
rheolef::details::field_expr_quadrature_on_element::_expr
Expr _expr
Definition field_expr_quadrature.h:114
rheolef::details::field_expr_quadrature_on_element::scalar_type
scalar_traits< value_type >::type scalar_type
Definition field_expr_quadrature.h:75
rheolef::details::field_expr_quadrature_on_element::self_type
field_expr_quadrature_on_element< Expr > self_type
Definition field_expr_quadrature.h:82
rheolef::details::field_expr_quadrature_on_element::value_type
Expr::value_type value_type
Definition field_expr_quadrature.h:74
rheolef::details::field_expr_quadrature_on_element::memory_type
Expr::memory_type memory_type
Definition field_expr_quadrature.h:72
rheolef::details::field_expr_quadrature_on_element::evaluate
void evaluate(const geo_basic< float_type, memory_type > &omega_K, const geo_element &K, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &lk) const
Definition field_expr_quadrature.h:155
rheolef::details::field_expr_quadrature_on_element::result_hint
Expr::value_type result_hint
Definition field_expr_quadrature.h:73
rheolef::details::field_expr_quadrature_on_element::_pops
piola_on_pointset< float_type > _pops
Definition field_expr_quadrature.h:115
rheolef::details::field_expr_quadrature_on_element::field_expr_quadrature_on_element
field_expr_quadrature_on_element(const Expr &expr)
Definition field_expr_quadrature.h:125
rheolef::details::field_expr_quadrature_on_element::vf_tag_type
Expr::vf_tag_type vf_tag_type
Definition field_expr_quadrature.h:79
rheolef::details::field_expr_quadrature_on_element::float_type
float_traits< value_type >::type float_type
Definition field_expr_quadrature.h:76
rheolef::details::field_expr_quadrature_on_element::size_type
geo_element::size_type size_type
Definition field_expr_quadrature.h:71
rheolef::details::field_expr_quadrature_on_element::get_vf_space
const space_type & get_vf_space() const
Definition field_expr_quadrature.h:99
rheolef::details::field_expr_quadrature_on_sides
Definition field_expr_quadrature.h:184
rheolef::details::field_expr_quadrature_on_sides::geo_type
geo_basic< float_type, memory_type > geo_type
Definition field_expr_quadrature.h:195
rheolef::details::field_expr_quadrature_on_sides::_ignore_sys_coord
bool _ignore_sys_coord
Definition field_expr_quadrature.h:234
rheolef::details::field_expr_quadrature_on_sides::field_expr_quadrature_on_sides
field_expr_quadrature_on_sides(const Expr &expr)
Definition field_expr_quadrature.h:248
rheolef::details::field_expr_quadrature_on_sides::space_type
space_basic< float_type, memory_type > space_type
Definition field_expr_quadrature.h:194
rheolef::details::field_expr_quadrature_on_sides::initialize
void initialize(const geo_basic< float_type, memory_type > &omega_K, const integrate_option &iopt)
Definition field_expr_quadrature.h:259
rheolef::details::field_expr_quadrature_on_sides::evaluate
void evaluate(const geo_basic< float_type, memory_type > &omega_K, const geo_element &K, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value) const
Definition field_expr_quadrature.h:283
rheolef::details::field_expr_quadrature_on_sides::_dis_inod_S
std::vector< size_type > _dis_inod_S
Definition field_expr_quadrature.h:237
rheolef::details::field_expr_quadrature_on_sides::valued_check
void valued_check() const
Definition field_expr_quadrature.h:226
rheolef::details::field_expr_quadrature_on_sides::valued_hint
static const space_constant::valued_type valued_hint
Definition field_expr_quadrature.h:202
rheolef::details::field_expr_quadrature_on_sides::n_derivative
size_type n_derivative() const
Definition field_expr_quadrature.h:212
rheolef::details::field_expr_quadrature_on_sides::vf_dual_tag_type
details::dual_vf_tag< vf_tag_type >::type vf_dual_tag_type
Definition field_expr_quadrature.h:198
rheolef::details::field_expr_quadrature_on_sides::self_type
field_expr_quadrature_on_sides< Expr > self_type
Definition field_expr_quadrature.h:199
rheolef::details::field_expr_quadrature_on_sides::_expr
Expr _expr
Definition field_expr_quadrature.h:232
rheolef::details::field_expr_quadrature_on_sides::_DF
tensor_basic< float_type > _DF
Definition field_expr_quadrature.h:238
rheolef::details::field_expr_quadrature_on_sides::scalar_type
scalar_traits< value_type >::type scalar_type
Definition field_expr_quadrature.h:192
rheolef::details::field_expr_quadrature_on_sides::value_type
Expr::value_type value_type
Definition field_expr_quadrature.h:191
rheolef::details::field_expr_quadrature_on_sides::memory_type
Expr::memory_type memory_type
Definition field_expr_quadrature.h:189
rheolef::details::field_expr_quadrature_on_sides::result_hint
Expr::value_type result_hint
Definition field_expr_quadrature.h:190
rheolef::details::field_expr_quadrature_on_sides::_pops
piola_on_pointset< float_type > _pops
Definition field_expr_quadrature.h:233
rheolef::details::field_expr_quadrature_on_sides::vf_tag_type
Expr::vf_tag_type vf_tag_type
Definition field_expr_quadrature.h:196
rheolef::details::field_expr_quadrature_on_sides::_value_i
Eigen::Matrix< float_type, Eigen::Dynamic, Eigen::Dynamic > _value_i
Definition field_expr_quadrature.h:236
rheolef::details::field_expr_quadrature_on_sides::dual_self_type
field_expr_quadrature_on_sides< typename Expr::dual_self_type > dual_self_type
Definition field_expr_quadrature.h:201
rheolef::details::field_expr_quadrature_on_sides::float_type
float_traits< value_type >::type float_type
Definition field_expr_quadrature.h:193
rheolef::details::field_expr_quadrature_on_sides::size_type
geo_element::size_type size_type
Definition field_expr_quadrature.h:188
rheolef::details::field_expr_quadrature_on_sides::get_vf_space
const space_type & get_vf_space() const
Definition field_expr_quadrature.h:211
rheolef::geo_basic
generic mesh with rerefence counting
Definition geo.h:1089
rheolef::geo_element
see the geo_element page for the full documentation
Definition geo_element.h:102
rheolef::geo_element::edge
size_type edge(size_type i) const
Definition geo_element.h:209
rheolef::geo_element::face
size_type face(size_type i) const
Definition geo_element.h:210
rheolef::geo_element::size_type
reference_element::size_type size_type
Definition geo_element.h:125
rheolef::geo_element::dimension
size_type dimension() const
Definition geo_element.h:167
rheolef::geo_element::get_side_informations
orientation_type get_side_informations(const geo_element &S, size_type &loc_isid, size_type &shift) const
Definition geo_element.cc:185
rheolef::geo_element::n_subgeo
size_type n_subgeo(size_type subgeo_dim) const
Definition geo_element.h:212
rheolef::integrate_option
see the integrate_option page for the full documentation
Definition integrate_option.h:125
rheolef::integrate_option::_is_inside_on_local_sides
bool _is_inside_on_local_sides
Definition integrate_option.h:180
rheolef::integrate_option::ignore_sys_coord
bool ignore_sys_coord
Definition integrate_option.h:168
rheolef::piola_on_pointset
Definition piola_on_pointset.h:142
rheolef::quadrature
Definition quadrature.h:186
rheolef::space_basic
the finite element space
Definition space.h:382
rheolef::tensor_basic
Definition tensor.h:90
fatal_macro
#define fatal_macro(message)
Definition dis_macros.h:33
_RHEOLEF_field_expr_quadrature_binary
#define _RHEOLEF_field_expr_quadrature_binary(FUNCTION, FUNCTOR)
Definition field_expr_quadrature.h:536
rheolef::details::expr_quadrature_init_iopt
integrate_option expr_quadrature_init_iopt(const geo_basic< T, M > &omega_K, const space_basic< T, M > &X, size_t n_derivative, const integrate_option &iopt)
Definition init_expr_quadrature.h:36
rheolef::space_constant::valued_type
valued_type
Definition space_constant.h:133
rheolef
This file is part of Rheolef.
Definition compiler_eigen.h:39
rheolef::valued_check
bool valued_check() const
Definition field_expr_recursive.h:957
rheolef::initialize
void initialize(const piola_on_pointset< float_type > &pops, const integrate_option &iopt)
Definition field_expr_recursive.h:627
rheolef::evaluate
void evaluate(const geo_basic< float_type, M > &omega_K, const geo_element &K, Eigen::Matrix< Result, Eigen::Dynamic, 1 > &value) const
Definition field_expr_recursive.h:915
rheolef::on_local_sides
std::enable_if< details::is_field_expr_v2_variational_arg< Expr >::value, details::field_expr_quadrature_on_sides< Expr > >::type on_local_sides(const Expr &expr)
on_local_sides(expr): see the expression page for the full documentation
Definition field_expr_quadrature.h:323
std
STL namespace.
f
Definition cavity_dg.h:29
rheolef::details::bf_vf_tag
Definition field_expr_variational_tag.h:74
rheolef::details::generic_binary_traits
Definition expression.h:407
rheolef::details::is_field_expr_quadrature_arg
Definition field_expr_quadrature.h:55
rheolef::details::is_field_expr_v2_variational_arg
Definition field_expr_variational_terminal.h:52
rheolef::details::minus
Definition expression.h:544
rheolef::details::plus
Definition expression.h:457
rheolef::details::vf_tag_nonlinear
Definition field_expr_variational_tag.h:49
rheolef::float_traits::type
T type
Definition Float.h:94
rheolef::is_undeterminated
Definition undeterminated.h:39
rheolef::scalar_traits::type
T type
Definition point.h:323
rheolef::side_information_type
Definition reference_element_face_transformation.h:37
rheolef::space_constant::valued_tag_traits
Definition space_constant.h:159
rheolef::undefined_memory_model
Definition communicator.h:61