1#ifndef __DUNE_ACFEM_MODEL_BOUNDARYINDICATORS_HH__
2#define __DUNE_ACFEM_MODEL_BOUNDARYINDICATORS_HH__
4#include "indicators/boundaryindicator.hh"
5#include "expressions.hh"
29 "Model better would be a proper PDE-model ...");
31 using ModelType = Model;
32 using ModelTraits = EffectiveModelTraits<Model>;
38 template<
class Intersection>
39 bool applies(
const Intersection& intersection)
const
41 if (!ModelTraits::template Exists<PDEModel::dirichlet>::value) {
44 auto bdCond = model_.classifyBoundary(intersection);
47 assert(bdCond.second.all() || bdCond.second.none());
48 return bdCond.second.all();
66 "Model better would be a proper PDE-model ...");
68 using ModelType = Model;
69 using ModelTraits = EffectiveModelTraits<Model>;
75 template<
class Intersection>
76 bool applies(
const Intersection& intersection)
const
78 if (!ModelTraits::template Exists<PDEModel::robinFlux>::value) {
81 typename ModelType::BoundaryClassComponentsType components;
82 if (model_.classifyBoundary(intersection, components)) {
84 assert(components.all() || components.none());
85 return components.none();
107 template<
class Model>
A wrapper which constructs from the given model a Dirichlet boundary indicator, using Model::classify...
Definition: modelboundaryindicators.hh:27
A wrapper which constructs from the given model a Robin boundary indicator, using Model::classifyBoun...
Definition: modelboundaryindicators.hh:64
auto modelDirichletIndicator(Model &&model)
Generate a boundary indicator evaluating to 1 on the Dirichlet segment of the model.
Definition: modelboundaryindicators.hh:99
auto modelRobinIndicator(Model &model)
Generate a boundary indicator evaluating to 1 on the Robin segment of the model.
Definition: modelboundaryindicators.hh:108
ModelIntrospection::template IsModel< Model > IsPDEModel
std::true_type if Model is derived from ModelBase.
Definition: modeltraits.hh:894
Boundary indicators need to inherit this tag-class in order to signal that they are boundary indicato...
Definition: boundaryindicator.hh:39