dune-fem 2.8.0
Loading...
Searching...
No Matches
dirichletconstraints.hh
Go to the documentation of this file.
1/**************************************************************************
2
3 The dune-fem module is a module of DUNE (see www.dune-project.org).
4 It is based on the dune-grid interface library
5 extending the grid interface by a number of discretization algorithms
6 for solving non-linear systems of partial differential equations.
7
8 Copyright (C) 2003 - 2015 Robert Kloefkorn
9 Copyright (C) 2003 - 2010 Mario Ohlberger
10 Copyright (C) 2004 - 2015 Andreas Dedner
11 Copyright (C) 2005 Adrian Burri
12 Copyright (C) 2005 - 2015 Mirko Kraenkel
13 Copyright (C) 2006 - 2015 Christoph Gersbacher
14 Copyright (C) 2006 - 2015 Martin Nolte
15 Copyright (C) 2011 - 2015 Tobias Malkmus
16 Copyright (C) 2012 - 2015 Stefan Girke
17 Copyright (C) 2013 - 2015 Claus-Justus Heine
18 Copyright (C) 2013 - 2014 Janick Gerstenberger
19 Copyright (C) 2013 Sven Kaulman
20 Copyright (C) 2013 Tom Ranner
21 Copyright (C) 2015 Marco Agnese
22 Copyright (C) 2015 Martin Alkaemper
23
24
25 The dune-fem module is free software; you can redistribute it and/or
26 modify it under the terms of the GNU General Public License as
27 published by the Free Software Foundation; either version 2 of
28 the License, or (at your option) any later version.
29
30 The dune-fem module is distributed in the hope that it will be useful,
31 but WITHOUT ANY WARRANTY; without even the implied warranty of
32 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
33 GNU General Public License for more details.
34
35 You should have received a copy of the GNU General Public License along
36 with this program; if not, write to the Free Software Foundation, Inc.,
37 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
38
39**************************************************************************/
40#ifndef DUNE_DIRICHLETCONSTRAINTS_HH
41#define DUNE_DIRICHLETCONSTRAINTS_HH
42
50
51namespace Dune {
52
53namespace Fem {
54class HasLocalFunction;
55}
56
57template < class Model, class DiscreteFunctionSpace >
59{
60public:
61 enum Operation { set = 0, sub = 1 };
62 typedef Model ModelType;
64 typedef typename DiscreteFunctionSpaceType::DomainType DomainType;
65 typedef typename DiscreteFunctionSpaceType::RangeType RangeType;
66 typedef typename DiscreteFunctionSpaceType::JacobianRangeType JacobianRangeType;
67 typedef typename DiscreteFunctionSpaceType::HessianRangeType HessianRangeType;
68
70 typedef typename DiscreteFunctionSpaceType :: GridPartType GridPartType;
72 typedef typename DiscreteFunctionSpaceType :: GridType GridType;
73
74 // types for boundary treatment
75 // ----------------------------
76 static const int localBlockSize = DiscreteFunctionSpaceType :: localBlockSize ;
77 static_assert( localBlockSize == DiscreteFunctionSpaceType::FunctionSpaceType::dimRange,
78 "local block size of the space must be identical to the dimension of the range of the function space.");
79 typedef std::array<int,localBlockSize> DirichletBlock;
80 typedef std::vector< DirichletBlock > DirichletBlockVector;
81 // static_assert( dimD >= localBlockSize,
82 // "local block size of the space must be less or equahl to the dimension of the range of the model.");
83
85 {
86 public:
87 typedef typename DiscreteFunctionSpaceType::EntityType EntityType;
88 typedef typename DiscreteFunctionSpaceType::FunctionSpaceType FunctionSpaceType;
89 typedef typename DiscreteFunctionSpaceType::DomainType DomainType;
90 typedef typename DiscreteFunctionSpace::RangeType RangeType;
91 typedef typename DiscreteFunctionSpace::JacobianRangeType JacobianRangeType;
92 typedef typename DiscreteFunctionSpace::HessianRangeType HessianRangeType;
93
94 private:
95 const ModelType& impl_;
96 const EntityType& entity_;
97 const int order_;
98 int bndId_;
99
100 public:
101 static const int dimRange = RangeType::dimension;
102 BoundaryWrapper( const ModelType& impl, const EntityType& entity, const int order, int bndId )
103 : impl_( impl ), entity_(entity), order_(order), bndId_(bndId) {}
104 const EntityType& entity() const { return entity_; }
105 const int order () const { return order_; }
106 template <class Point>
107 void evaluate( const Point& x, RangeType& ret ) const
108 { impl_.dirichlet(bndId_,Dune::Fem::coordinate(x),ret); }
109 template <class Point>
110 void jacobian( const Point& x, JacobianRangeType& ret ) const
111 { DUNE_THROW(Dune::NotImplemented,"rhs jacobian not implemented"); }
112 };
113
115 : model_(model),
116 space_( space ),
118 // mark DoFs on the Dirichlet boundary
119 hasDirichletDofs_( false ),
120 sequence_( -1 )
121 {}
122
130 template < class DiscreteFunctionType >
131 void operator ()( const DiscreteFunctionType& u, DiscreteFunctionType& w ) const
132 {
134
135 // if Dirichlet Dofs have been found, treat them
137 {
138 typedef typename DiscreteFunctionType :: DofIteratorType DofIteratorType ;
139 typedef typename DiscreteFunctionType :: ConstDofIteratorType ConstDofIteratorType ;
140
141 ConstDofIteratorType uIt = u.dbegin();
142 DofIteratorType wIt = w.dbegin();
143
144 // loop over all blocks
145 const unsigned int blocks = space_.blockMapper().size();
146 for( unsigned int blockDof = 0; blockDof < blocks ; ++ blockDof )
147 {
148 for( int l = 0; l < localBlockSize ; ++ l, ++ wIt, ++ uIt )
149 {
150 if( dirichletBlocks_[ blockDof ][l] )
151 {
152 // copy dofs of the block
153 assert( uIt != u.dend() );
154 assert( wIt != w.dend() );
155 (*wIt) = (*uIt);
156 }
157 }
158 }
159 }
160 }
168 template < class DiscreteFunctionType >
169 void operator ()( const typename DiscreteFunctionType::RangeType& value, DiscreteFunctionType& w ) const
170 {
172
173 // if Dirichlet Dofs have been found, treat them
175 {
176 typedef typename DiscreteFunctionType :: DofIteratorType DofIteratorType ;
177
178 DofIteratorType wIt = w.dbegin();
179
180 // loop over all blocks
181 const unsigned int blocks = space_.blockMapper().size();
182 for( unsigned int blockDof = 0; blockDof < blocks ; ++ blockDof )
183 {
184 for( int l = 0; l < localBlockSize ; ++ l, ++ wIt )
185 {
186 if( dirichletBlocks_[ blockDof ][l] )
187 {
188 // copy dofs of the block
189 assert( wIt != w.dend() );
190 (*wIt) = value[l];
191 }
192 }
193 }
194 }
195 }
196
204 template < class DiscreteFunctionType >
205 void operator ()( DiscreteFunctionType& w ) const
206 {
208
210 {
211 typedef typename DiscreteFunctionSpaceType :: IteratorType IteratorType;
212 typedef typename IteratorType :: Entity EntityType;
213
216 for( const EntityType &entity : space_ )
217 {
218 model_.init(entity);
219
220 // bind local contribution to entity
221 auto wGuard = Dune::Fem::bindGuard( wLocal, entity );
222 // bind interpolation to entity
223 auto iGuard = bindGuard( interpolation, entity );
224
225 // interpolate dirichlet dofs
226 dirichletDofTreatment( interpolation, wLocal );
227 }
228 }
229 }
230 template < class GridFunctionType, class DiscreteFunctionType,
231 typename = std::enable_if_t< std::is_base_of<Dune::Fem::HasLocalFunction, GridFunctionType>::value > >
232 void operator ()( const GridFunctionType &u,
233 DiscreteFunctionType& w, Operation op=Operation::setDF ) const
234 {
236
238 {
242
243 for( const auto &entity : space_ )
244 {
245 auto guard = Dune::Fem::bindGuard( std::tie(uLocal,wLocal), entity );
246 // bind interpolation to entity
247 auto iGuard = bindGuard( interpolation, entity );
248
249 // interpolate dirichlet dofs
250 if (op == Operation::sub)
251 model_.init(entity);
252 dirichletDofTreatment( interpolation, uLocal, wLocal, op );
253 }
254 }
255 }
256
265 template <class LinearOperator>
266 void applyToOperator( LinearOperator& linearOperator ) const
267 {
269
270 typedef typename DiscreteFunctionSpaceType :: IteratorType IteratorType;
271 typedef typename IteratorType :: Entity EntityType;
272
273 // if Dirichlet Dofs have been found, treat them
275 {
276 typedef typename LinearOperator::DomainSpaceType DomainSpaceType;
277 typedef typename LinearOperator::RangeSpaceType RangeSpaceType;
279 TemporaryLocalMatrixType localMatrix( linearOperator.domainSpace(), linearOperator.rangeSpace() );
280
281 const IteratorType end = space_.end();
282 for( IteratorType it = space_.begin(); it != end; ++it )
283 {
284 const EntityType &entity = *it;
285 // init localMatrix to entity
286 localMatrix.init( entity, entity );
287 // obtain local matrix values
288 linearOperator.getLocalMatrix( entity, entity, localMatrix );
289 // adjust local matrix
290 dirichletDofsCorrectOnEntity( entity, localMatrix );
291 // write back changed local matrix to linear operator
292 linearOperator.setLocalMatrix( entity, entity, localMatrix );
293 }
294 }
295 }
296
298 {
300 return dirichletBlocks_;
301 }
302
303protected:
304
313 template< class EntityType, class LocalMatrix >
314 void dirichletDofsCorrectOnEntity ( const EntityType &entity,
315 LocalMatrix& localMatrix ) const
316 {
317 // get auxiliary dof structure (for parallel runs) /*@LST0S@*/
318 const auto &auxiliaryDofs = localMatrix.rangeSpace().auxiliaryDofs();
319
320 // get number of basis functions
321 const int localBlocks = space_.blockMapper().numDofs( entity );
322
323 // map local to global dofs
324 std::vector<std::size_t> globalBlockDofs(localBlocks);
325 // obtain all DofBlocks for this element
326 space_.blockMapper().map( entity, globalBlockDofs );
327
328 // counter for all local dofs (i.e. localBlockDof * localBlockSize + ... )
329 int localDof = 0;
330 // iterate over face dofs and set unit row
331 for( int localBlockDof = 0 ; localBlockDof < localBlocks; ++ localBlockDof )
332 {
333 int global = globalBlockDofs[localBlockDof];
334 for( int l = 0; l < localBlockSize; ++ l, ++ localDof )
335 {
336 if( dirichletBlocks_[global][l] )
337 {
338 // clear all other columns
339 localMatrix.clearRow( localDof );
340
341 // set diagonal to 1
342 double value = auxiliaryDofs.contains( global )? 0.0 : 1.0;
343 localMatrix.set( localDof, localDof, value );
344 }
345 }
346 }
347 }
348
350 template< class LocalInterpolationType, class LocalFunctionType >
351 void dirichletDofTreatment( const LocalInterpolationType& interpolation, LocalFunctionType &wLocal ) const
352 {
353 // get entity
354 const typename LocalFunctionType::EntityType &entity = wLocal.entity();
355
356 // get number of Lagrange Points
357 const int localBlocks = space_.blockMapper().numDofs( entity );
358
359 // map local to global BlockDofs
360 std::vector<std::size_t> globalBlockDofs(localBlocks);
361 space_.blockMapper().map( entity, globalBlockDofs );
362 std::vector<typename LocalFunctionType::RangeFieldType> values( localBlocks*localBlockSize );
363
364 int localDof = 0;
365
366 // iterate over face dofs and set unit row
367 for( int localBlock = 0 ; localBlock < localBlocks; ++ localBlock )
368 {
369 // store result to dof vector
370 int global = globalBlockDofs[localBlock];
371 for( int l = 0; l < localBlockSize ; ++ l, ++localDof )
372 {
373 if( dirichletBlocks_[ global ][l] )
374 {
375 interpolation( BoundaryWrapper(model_, entity, wLocal.order(), dirichletBlocks_[global][l]), values );
376 // store result
377 assert( (unsigned int)localDof < wLocal.size() );
378 wLocal[ localDof ] = values[ localDof ];
379 }
380 }
381 }
382 }
383
384 template< class LocalInterpolationType, class GridLocalFunctionType, class LocalFunctionType >
385 void dirichletDofTreatment( const LocalInterpolationType& interpolation,
386 const GridLocalFunctionType &uLocal,
387 LocalFunctionType &wLocal, Operation op ) const
388 {
389 // get entity
390 const typename LocalFunctionType::EntityType &entity = wLocal.entity();
391
392 // get number of Lagrange Points
393 const int localBlocks = space_.blockMapper().numDofs( entity );
394
395 typedef typename DiscreteFunctionSpaceType::BlockMapperType::GlobalKeyType GlobalKeyType;
396
397 // map local to global BlockDofs
398 std::vector< GlobalKeyType > globalBlockDofs(localBlocks);
399 space_.blockMapper().map(entity,globalBlockDofs);
400 std::vector<double> values( localBlocks*localBlockSize );
401 std::vector<double> valuesModel( localBlocks*localBlockSize );
402
403 interpolation( uLocal, values );
404
405 int localDof = 0;
406
407 // iterate over face dofs and set unit row
408 for( int localBlock = 0 ; localBlock < localBlocks; ++ localBlock )
409 {
410 // store result to dof vector
411 int global = globalBlockDofs[localBlock];
412 for( int l = 0; l < localBlockSize ; ++ l, ++localDof )
413 {
414 if( dirichletBlocks_[ global ][l] )
415 {
416 if (op == Operation::sub)
417 {
418 interpolation(BoundaryWrapper(model_, entity, wLocal.order(), dirichletBlocks_[global][l]), valuesModel);
419 values[ localDof ] -= valuesModel[ localDof ];
420 }
421 // store result
422 assert( (unsigned int)localDof < wLocal.size() );
423 wLocal[ localDof ] = values[ localDof ];
424 }
425 }
426 }
427 }
428
429protected:
430 // detect all DoFs on the Dirichlet boundary
432 {
433 if( sequence_ != space_.sequence() )
434 {
435 // only start search if Dirichlet boundary is present
436 if( ! model_.hasDirichletBoundary() )
437 {
438 hasDirichletDofs_ = false ;
439 return ;
440 }
441
442 // resize flag vector with number of blocks and reset flags
443 const int blocks = space_.blockMapper().size() ;
444 dirichletBlocks_.resize( blocks );
445 for( int i=0; i<blocks; ++i )
446 dirichletBlocks_[ i ].fill(0);
447
448 typedef typename DiscreteFunctionSpaceType :: IteratorType IteratorType;
449 typedef typename IteratorType :: Entity EntityType;
450
451 bool hasDirichletBoundary = false;
452 const IteratorType end = space_.end();
453 for( IteratorType it = space_.begin(); it != end; ++it )
454 {
455 const EntityType &entity = *it;
456 // if entity has boundary intersections
457 if( entity.hasBoundaryIntersections() )
458 {
459 hasDirichletBoundary |= searchEntityDirichletDofs( entity, model_ );
460 }
461 }
462
463 // update sequence number
464 sequence_ = space_.sequence();
465 if( space_.gridPart().comm().size() > 1 )
466 {
467 try
468 {
469 DirichletBuilder handle( *this, space_ , space_.blockMapper() );
470 space_.gridPart().communicate
471 ( handle, GridPartType::indexSetInterfaceType, ForwardCommunication );
472 }
473 // catch possible exceptions here to have a clue where it happend
474 catch( const Exception &e )
475 {
476 std::cerr << e << std::endl;
477 std::cerr << "Exception thrown in: " << __FILE__ << " line:" << __LINE__ << std::endl;
478 abort();
479 }
480 hasDirichletDofs_ = space_.gridPart().grid().comm().max( hasDirichletBoundary );
481 }
482 else
483 {
484 hasDirichletDofs_ = hasDirichletBoundary;
485 }
486 }
487 }
488
489 // detect all DoFs on the Dirichlet boundary of the given entity
490 template< class EntityType >
491 bool searchEntityDirichletDofs( const EntityType &entity, ModelType& model ) const
492 {
493 typedef typename DiscreteFunctionSpaceType :: GridPartType GridPartType;
494
495 typedef typename GridPartType :: IntersectionIteratorType
496 IntersectionIteratorType;
497
498 const GridPartType &gridPart = space_.gridPart();
499
500 // default is false
501 bool hasDirichletBoundary = false;
502
503 //map local to global BlockDofs
504 std::vector< size_t> globalBlockDofs(space_.blockMapper().numDofs(entity));
505 space_.blockMapper().map(entity,globalBlockDofs);
506
507 std::vector< bool> globalBlockDofsFilter(space_.blockMapper().numDofs(entity));
508
509 IntersectionIteratorType it = gridPart.ibegin( entity );
510 const IntersectionIteratorType endit = gridPart.iend( entity );
511 for( ; it != endit; ++it )
512 {
513 typedef typename IntersectionIteratorType :: Intersection IntersectionType;
514 const IntersectionType& intersection = *it;
515
516 // if intersection is with boundary, adjust data
517 if( intersection.boundary() )
518 {
519 // get dirichlet information from model
520 DirichletBlock block;
521 block.fill(0);
522 const bool isDirichletIntersection = model.isDirichletIntersection( intersection, block );
523 if (isDirichletIntersection)
524 {
525 // get face number of boundary intersection
526 const int face = intersection.indexInInside();
527 space_.blockMapper().onSubEntity(entity,face,1,globalBlockDofsFilter);
528 for( unsigned int i=0;i<globalBlockDofs.size();++i)
529 {
530 if ( !globalBlockDofsFilter[i] ) continue;
531 // mark global DoF number
532 for(int k = 0; k < localBlockSize; ++k)
533 dirichletBlocks_[globalBlockDofs[ i ] ][k] = block [k];
534
535 // we have Dirichlet values
536 hasDirichletBoundary = true ;
537 }
538 }
539 }
540 }
541
542 return hasDirichletBoundary;
543 }
544
548 mutable bool hasDirichletDofs_ ;
549 mutable int sequence_ ;
550
551 class DirichletBuilder;
552};
553
554template < class Model, class Space >
556 : public CommDataHandleIF< DirichletBuilder, int >
557{
558public:
559 typedef Space SpaceType;
560 typedef typename SpaceType::BlockMapperType MapperType;
561
562 enum { nCodim = SpaceType :: GridType :: dimension + 1 };
563
564public:
565 typedef int DataType;
566
567 const int myRank_;
568 const int mySize_;
569
572
575
576 static const int blockSize = SpaceType::localBlockSize;
577
578public:
580 const SpaceType &space,
581 const MapperType &mapper )
582 : myRank_( space.gridPart().comm().rank() ),
583 mySize_( space.gridPart().comm().size() ),
584 dirichlet_( dirichlet ),
585 space_( space ),
586 mapper_( mapper )
587 {
588 }
589 bool contains ( int dim, int codim ) const
590 {
591 return mapper_.contains( codim );
592 }
593
594 bool fixedSize ( int dim, int codim ) const
595 {
596 return false;
597 }
598
600 template< class MessageBuffer, class Entity >
601 inline void gather ( MessageBuffer &buffer,
602 const Entity &entity ) const
603 {
604 unsigned int localBlocks = mapper_.numEntityDofs( entity );
605 std::vector<std::size_t> globalBlockDofs(localBlocks);
606 mapper_.mapEntityDofs( entity, globalBlockDofs );
607 assert( size(entity) == globalBlockDofs.size()*blockSize );
608 for( unsigned int localBlock = 0 ; localBlock < globalBlockDofs.size(); ++ localBlock )
609 {
610 int global = globalBlockDofs[localBlock];
611 for (int r=0;r<blockSize;++r)
612 if (dirichlet_.dirichletBlocks_[ global ][r] )
613 buffer.write( 1 );
614 else
615 buffer.write( 0 );
616 }
617 }
618
623 template< class MessageBuffer, class EntityType >
624 inline void scatter ( MessageBuffer &buffer,
625 const EntityType &entity,
626 size_t n )
627 {
628 unsigned int localBlocks = mapper_.numEntityDofs( entity );
629 std::vector<std::size_t> globalBlockDofs(localBlocks);
630 mapper_.mapEntityDofs( entity, globalBlockDofs );
631 assert( n == globalBlockDofs.size()*blockSize );
632 assert( n == size(entity) );
633 for( unsigned int localBlock = 0 ; localBlock < globalBlockDofs.size(); ++ localBlock )
634 {
635 int global = globalBlockDofs[localBlock];
636 for (int r=0;r<blockSize;++r)
637 {
638 int val;
639 buffer.read(val);
640 if ( !dirichlet_.dirichletBlocks_[ global ][r] && val == 1)
641 dirichlet_.dirichletBlocks_[ global ][r] = true;
642 }
643 }
644 }
646 template< class Entity >
647 size_t size ( const Entity &entity ) const
648 {
649 return blockSize * mapper_.numEntityDofs( entity );
650 }
651};
652
653} // end namespace Dune
654#endif
Definition: bindguard.hh:11
typename Impl::ConstLocalFunction< GridFunction >::Type ConstLocalFunction
Definition: const.hh:604
static const Point & coordinate(const Point &x)
Definition: coordinate.hh:14
static auto bindGuard(Object &object, Args &&... args) -> std::enable_if_t< isBindable< Object, Args... >::value, BindGuard< Object > >
Definition: bindguard.hh:67
Definition: common/localcontribution.hh:14
A local matrix with a small array as storage.
Definition: temporarylocalmatrix.hh:100
Definition: dirichletconstraints.hh:59
std::array< int, localBlockSize > DirichletBlock
Definition: dirichletconstraints.hh:79
DiscreteFunctionSpaceType::JacobianRangeType JacobianRangeType
Definition: dirichletconstraints.hh:66
Operation
Definition: dirichletconstraints.hh:61
@ set
Definition: dirichletconstraints.hh:61
@ sub
Definition: dirichletconstraints.hh:61
DirichletBlockVector dirichletBlocks_
Definition: dirichletconstraints.hh:547
DiscreteFunctionSpaceType::DomainType DomainType
Definition: dirichletconstraints.hh:64
DiscreteFunctionSpaceType::RangeType RangeType
Definition: dirichletconstraints.hh:65
void dirichletDofTreatment(const LocalInterpolationType &interpolation, const GridLocalFunctionType &uLocal, LocalFunctionType &wLocal, Operation op) const
Definition: dirichletconstraints.hh:385
static const int localBlockSize
Definition: dirichletconstraints.hh:76
DiscreteFunctionSpaceType::GridPartType GridPartType
type of grid partition
Definition: dirichletconstraints.hh:70
void updateDirichletDofs() const
Definition: dirichletconstraints.hh:431
Model ModelType
Definition: dirichletconstraints.hh:62
void applyToOperator(LinearOperator &linearOperator) const
Definition: dirichletconstraints.hh:266
const DirichletBlockVector & dirichletBlocks() const
Definition: dirichletconstraints.hh:297
bool hasDirichletDofs_
Definition: dirichletconstraints.hh:548
const DiscreteFunctionSpaceType & space_
Definition: dirichletconstraints.hh:546
std::vector< DirichletBlock > DirichletBlockVector
Definition: dirichletconstraints.hh:80
ModelType & model_
Definition: dirichletconstraints.hh:545
void operator()(const DiscreteFunctionType &u, DiscreteFunctionType &w) const
Definition: dirichletconstraints.hh:131
int sequence_
Definition: dirichletconstraints.hh:549
void dirichletDofsCorrectOnEntity(const EntityType &entity, LocalMatrix &localMatrix) const
Definition: dirichletconstraints.hh:314
DiscreteFunctionSpaceType::GridType GridType
type of grid
Definition: dirichletconstraints.hh:72
DiscreteFunctionSpace DiscreteFunctionSpaceType
Definition: dirichletconstraints.hh:63
DirichletConstraints(ModelType &model, const DiscreteFunctionSpaceType &space)
Definition: dirichletconstraints.hh:114
bool searchEntityDirichletDofs(const EntityType &entity, ModelType &model) const
Definition: dirichletconstraints.hh:491
DiscreteFunctionSpaceType::HessianRangeType HessianRangeType
Definition: dirichletconstraints.hh:67
void dirichletDofTreatment(const LocalInterpolationType &interpolation, LocalFunctionType &wLocal) const
set the Dirichlet points to exact values
Definition: dirichletconstraints.hh:351
Definition: dirichletconstraints.hh:85
DiscreteFunctionSpaceType::DomainType DomainType
Definition: dirichletconstraints.hh:89
BoundaryWrapper(const ModelType &impl, const EntityType &entity, const int order, int bndId)
Definition: dirichletconstraints.hh:102
DiscreteFunctionSpace::HessianRangeType HessianRangeType
Definition: dirichletconstraints.hh:92
DiscreteFunctionSpace::JacobianRangeType JacobianRangeType
Definition: dirichletconstraints.hh:91
static const int dimRange
Definition: dirichletconstraints.hh:101
const EntityType & entity() const
Definition: dirichletconstraints.hh:104
const int order() const
Definition: dirichletconstraints.hh:105
DiscreteFunctionSpaceType::FunctionSpaceType FunctionSpaceType
Definition: dirichletconstraints.hh:88
void jacobian(const Point &x, JacobianRangeType &ret) const
Definition: dirichletconstraints.hh:110
void evaluate(const Point &x, RangeType &ret) const
Definition: dirichletconstraints.hh:107
DiscreteFunctionSpace::RangeType RangeType
Definition: dirichletconstraints.hh:90
DiscreteFunctionSpaceType::EntityType EntityType
Definition: dirichletconstraints.hh:87
Definition: dirichletconstraints.hh:557
DirichletConstraints< Model, Space > DirichletType
Definition: dirichletconstraints.hh:570
void gather(MessageBuffer &buffer, const Entity &entity) const
read buffer and apply operation
Definition: dirichletconstraints.hh:601
const SpaceType & space_
Definition: dirichletconstraints.hh:573
int DataType
Definition: dirichletconstraints.hh:565
DirichletBuilder(const DirichletType &dirichlet, const SpaceType &space, const MapperType &mapper)
Definition: dirichletconstraints.hh:579
bool contains(int dim, int codim) const
Definition: dirichletconstraints.hh:589
bool fixedSize(int dim, int codim) const
Definition: dirichletconstraints.hh:594
const int mySize_
Definition: dirichletconstraints.hh:568
const int myRank_
Definition: dirichletconstraints.hh:567
void scatter(MessageBuffer &buffer, const EntityType &entity, size_t n)
Definition: dirichletconstraints.hh:624
size_t size(const Entity &entity) const
return local dof size to be communicated
Definition: dirichletconstraints.hh:647
Space SpaceType
Definition: dirichletconstraints.hh:559
const MapperType & mapper_
Definition: dirichletconstraints.hh:574
const DirichletType & dirichlet_
Definition: dirichletconstraints.hh:571
SpaceType::BlockMapperType MapperType
Definition: dirichletconstraints.hh:560
Definition: common/localinterpolation.hh:22
discrete function space