LifeV
BCFunction.hpp
Go to the documentation of this file.
1 //@HEADER
2 /*
3 *******************************************************************************
4 
5  Copyright (C) 2004, 2005, 2007 EPFL, Politecnico di Milano, INRIA
6  Copyright (C) 2010 EPFL, Politecnico di Milano, Emory University
7 
8  This file is part of LifeV.
9 
10  LifeV is free software; you can redistribute it and/or modify
11  it under the terms of the GNU Lesser General Public License as published by
12  the Free Software Foundation, either version 3 of the License, or
13  (at your option) any later version.
14 
15  LifeV is distributed in the hope that it will be useful,
16  but WITHOUT ANY WARRANTY; without even the implied warranty of
17  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18  Lesser General Public License for more details.
19 
20  You should have received a copy of the GNU Lesser General Public License
21  along with LifeV. If not, see <http://www.gnu.org/licenses/>.
22 
23 *******************************************************************************
24 */
25 //@HEADER
26 
27 /*!
28  @file
29  @brief File contains BCManageNormal class for handling normal essential boundary conditions
30 
31  @author Miguel Fernandez <miguel.fernandez@inria.fr>
32  @contributor Christophe Prud'homme <christophe.prudhomme@epfl.ch>
33  @contributor Mauro Perego <perego.mauro@gmail.com>
34  @maintainer Mauro Perego <perego.mauro@gmail.com>
35 
36  @date 10-12-2004
37  *///@HEADER
38 
39 #ifndef BCFUNCTION_H
40 #define BCFUNCTION_H 1
41 
42 #include <lifev/core/LifeV.hpp>
43 
44 namespace LifeV
45 {
46 //! BCFunctionBase - class that holds the function used for prescribing boundary conditions.
47 /*!
48  @author Miguel Fernandez
49 
50  This class holds the function used for prescribing Essential or Natural boundary conditions.
51  The data functions given by the user must have the following signature.
52 
53  @verbatim
54  Real f(const Real& time, const Real& x, const Real& y, const Real& z, const ID& component).
55  @endverbatim
56 
57  In the case of Essential boundary condition, we want to prescribe
58  @verbatim
59  u = f
60  @endverbatim
61  on part of the boundary,
62  where @c u is the solution and @c f the user defined function.
63  In the case of Natural boundary condition, we want to add the to the right hand side of the equation the following term:
64  @verbatim
65  ( f, phi )_bd
66  @endverbatim
67 
68  Here @c ( . , . )_bd denote the L^2 inner product on the boundary, phi is the test function
69 
70  Functions f and is set using the correct constructor or using @c setFunction(f). <br>
71  To get the function f use @c getFunction(), to evaluate it use the @c operator().
72 
73  This is the base class for other BCFunctionXXX classes.
74  Inheritance is used to hold specific boundary condition data.
75 
76 */
78 {
79 public:
80 
81  //! @name Public Types
82  //@{
83 
84  typedef std::function<Real ( const Real&, const Real&, const Real&, const Real&, const ID& ) > function_Type;
86 
87  //@}
88 
89  //! @name Constructors & Destructor
90  //@{
91 
92  //! Empty Constructor
93  /*!
94  The user must supply a function by calling setFunction(..)
95  */
97 
98  //! Constructor for a user defined function
99  /*!
100  @param userDefinedFunction the user defined function
101  */
102  BCFunctionBase ( function_Type userDefinedFunction );
103 
104  //! Copy Constructor
105  /*!
106  @param bcFunctionBase The BCFunctionBase
107  */
108  BCFunctionBase ( const BCFunctionBase& bcFunctionBase );
109 
110 
111  //! Destructor
112  virtual ~BCFunctionBase() {}
113 
114  //@}
115 
116  //! @name Operators
117  //@{
118 
119  //! Assignment Operator
120  /*!
121  @param bcFunctionBase The BCFunctionBase
122  @return Reference to a new BCFunctionBase object with the same content of bcFunctionBase
123  */
124  virtual BCFunctionBase& operator= ( const BCFunctionBase& bcFunctionBase );
125 
126 
127  //! Overloading function operator by calling M_userDefinedFunction
128  /*!
129  @param t Time
130  @param x Coordinate x
131  @param y Coordinate y
132  @param z Coordinate z
133  @param component The Component of the vector function
134  @return The selected component of the user defined function evaluated in (t,x,y,z)
135  */
136  inline Real operator() ( const Real& t, const Real& x, const Real& y,
137  const Real& z, const ID& component ) const
138  {
139  return M_userDefinedFunction ( t, x, y, z, component );
140  }
141 
142  //@}
143 
144  //! @name Set Methods
145  //@{
146 
147 
148  //! Set the user defined function
149  /*!
150  @param userDefinedFunction the user defined function
151  */
152  inline void setFunction ( function_Type userDefinedFunction )
153  {
154  M_userDefinedFunction = userDefinedFunction;
155  }
156 
157  //@}
158 
159  //! @name Get Methods
160  //@{
161 
162  //! Get the function
163  /*!
164  @return Reference to M_userDefinedFunction
165  */
166  inline const function_Type& Function() const
167  {
168  return M_userDefinedFunction;
169  }
170 
171  //@}
172 
173  //! @name Methods
174  //@{
175 
176  //! Clone the current object
177  /*!
178  @return Pointer to the cloned object
179  */
181  {
182  BCFunctionBasePtr_Type copy ( new BCFunctionBase ( M_userDefinedFunction ) );
183  return copy;
184  }
185 
186  //@}
187 
188 
189 
190 protected:
191  //! user defined function
193 };
194 
195 
196 
197 
198 
199 
200 
201 
202 //! BCFunctionRobin - class that holds the function used for prescribing Robin boundary conditions.
203 /*!
204  @author Miguel Fernandez
205 
206  This class holds the functions used for prescribing Robin boundary conditions.
207  This class is derived by @c BCFunctionBase class
208 
209  The data functions given by the user must have the following signature
210 
211  @verbatim
212  Real f(const Real& t, const Real& x, const Real& y, const Real& z, const ID& component)
213  @endverbatim
214 
215  In order to prescribe Robin boundary condition we want to add to the system matrix the boundary mass term
216  @verbatim
217  (coeff u, phi)_bd
218  @endverbatim
219  and to add to the right hand side the term
220  @verbatim
221  (f, phi)_bd
222  @endverbatim
223  where u is the solution, phi the test function and @c ( , )_bd the L2 inner product on the boundary
224 
225  Functions f and coeff are set using the correct constructor or using setFunctionRobin(f, coeff).<br>
226  To get the function f use @c getFunction(), to evaluate it use the @c operator(). <br>
227  To get the function coeff use @c getFunction_Robin(), to evaluate it use the method @c coef(...).
228 
229 */
230 
232 {
233 public:
234 
235  //! @name Public Types
236  //@{
237 
238  typedef BCFunctionBase::function_Type function_Type;
239 
240  //@}
241 
242 
243  //! @name Constructors & Destructor
244  //@{
245 
246  //! Default constructor
247  /*!
248  The user must supply the functions by calling setFunction_Robin(..)
249  */
251 
252  //! Constructing from user defined functions
253  /*!
254  @param rightHandSideFunction The user defined function for @c f
255  @param massTermFunction The user defined function for @c coeff
256  */
257  BCFunctionRobin ( const function_Type& rightHandSideFunction, const function_Type& massTermFunction );
258 
259 
260  //! Copy Constructor
261  /*!
262  @param bcFunctionUDepRobin The BCFunctionRobin object
263  */
264  BCFunctionRobin ( const BCFunctionRobin& bcFunctionUDepRobin );
265 
266  //! Destructor
267  virtual ~BCFunctionRobin() {}
268 
269 
270  //@}
271 
272  //! @name Operators
273  //@{
274 
275  //! Assignment operator
276  /*!
277  @param bcFunctionUDepRobin The BCFunctionRobin object
278  @return Reference to a new BCFunctionRobin object which is a copy of bcFunctionMixt
279  */
281  operator= ( const BCFunctionRobin& bcFunctionUDepRobin );
282 
283 
284  //@}
285 
286  //! @name Methods
287  //@{
288 
289  //! Clone the current object
290  /*!
291  @return Pointer to the cloned object
292  */
294  {
295  BCFunctionBase::BCFunctionBasePtr_Type copy ( new BCFunctionRobin ( M_userDefinedFunction, M_robinBoundaryMassCoeffFunction ) );
296  return copy;
297  }
298 
299  //! evaluate the user defined function M_robinBoundaryMassCoeffFunction
300  /*!
301  @param t Time
302  @param x Coordinate
303  @param y Coordinate
304  @param z Coordinate
305  @param component component of the vector function
306  @return selected component of the user defined for @ coeff evaluated in (t,x,y,z)
307  */
308  Real coef ( const Real& t, const Real& x, const Real& y,
309  const Real& z, const ID& component ) const
310  {
311  return M_robinBoundaryMassCoeffFunction (t, x, y, z, component);
312  }
313 
314  //@}
315 
316 
317  //! @name Set Methods
318  //@{
319 
320 
321  //! Set the functions
322  /*!
323  @param rightHandSideFunction The user defined function for @c f
324  @param massTermFunction The user defined function for @c coeff
325  */
326  void setFunctions_Robin ( const function_Type& rightHandSideFunction, const function_Type& massCoeffFunction );
327 
328  //@}
329 
330 
331  //! @name Get Methods
332  //@{
333 
334 
335  //! Get the user defined function M_robinBoundaryMassCoeffFunction
336  /*!
337  @return user defined function for @c coeff
338  */
339  inline const function_Type& Functions_Robin() const
340  {
342  }
343 
344  //@}
345 
346 private:
347 
348  //! user defined function for the boundary mass coefficient in Robin conditions
350 };
351 
352 
353 //! BCFunctionUDepBase - class that holds the function used for prescribing boundary conditions.
354 /*!
355  @author Miguel Fernandez
356 
357  This class holds the function used for prescribing Essential or Natural boundary conditions in the case in which the function depend on a FE vector
358  (usually the solution at the previous iteration).
359 
360  The data functions given by the user must have the following signature
361 
362  @verbatim
363  Real f(const Real& t, const Real& x, const Real& y, const Real& z, const ID& component, const Real& feVectorEvaluatedInThisPoint)
364  @endverbatim
365 
366  In the case of Essential boundary condition, we want to prescribe
367  @verbatim
368  u = f
369  @endverbatim
370  on part of the boundary,
371  where @c u is the solution and @c f the user defined function.
372  In the case of Natural boundary condition, we want to add the to the right hand side of the equation the following term:
373  @verbatim
374  ( f, phi )_bd
375  @endverbatim
376 
377  Functions f is set using the correct constructor or using @c setFunction(f). <br>
378  To get the function f use @c getFunction(), to evaluate it use the @c operator().
379  */
381 {
382 public:
383 
384  //! @name Public Types
385  //@{
386 
387  typedef std::function<Real ( const Real&, const Real&, const Real&, const Real&, const ID&, const Real& ) > function_Type;
389 
390  //@}
391 
392  //! Empty Constructor
393  /*!
394  The user must supply a function by calling setFunction(..)
395  */
397 
398  //! Constructor for a user defined function
399  /*!
400  @param userDefinedFunction the user defined function
401  */
402  BCFunctionUDepBase (const function_Type& userDefinedFunction );
403 
404 
405  //! Copy Constructor
406  /*!
407  @param bcFunctionBase The BCFunctionBase
408  */
409  BCFunctionUDepBase (const BCFunctionUDepBase& bcFunctionUDepBase );
410 
411 
412  //! Destructor
413  virtual ~BCFunctionUDepBase() {}
414 
415  //! @name Operators
416  //@{
417 
418 
419  //! Assignment Operator
420  /*!
421  @param bcFunctionUDepBase The BCFunctionUDepBase
422  @return Reference to a new BCFunctionUDepBase object with the same content of bcFunctionUDepBase
423  */
424  virtual BCFunctionUDepBase& operator= ( const BCFunctionUDepBase& bcFunctionUDepBase);
425 
426 
427  //! Overloading function operator by calling M_userDefinedFunction
428  /*!
429  @param t Time
430  @param x Coordinate x
431  @param y Coordinate y
432  @param z Coordinate z
433  @param component The Component of the vector function
434  @param feVectorEvaluatedInThisPoint The FE vector evaluated in the point (x, y, z) at time t.
435  @return The selected component of the user defined function evaluated in (t,x,y,z)
436  */
437  inline Real operator() (const Real& t, const Real& x, const Real& y,
438  const Real& z, const ID& component, const Real& feVectorEvaluatedInThisPoint ) const
439  {
440  return M_userDefinedFunction ( t, x, y, z, component, feVectorEvaluatedInThisPoint );
441  }
442 
443  //@}
444 
445  //! @name Methods
446  //@{
447 
448  //! Clone the current object
449  /*!
450  @return Pointer to the cloned object
451  */
453  {
454  BCFunctionUDepBasePtr_Type copy ( new BCFunctionUDepBase ( M_userDefinedFunction ) );
455  return copy;
456  }
457 
458  //@}
459 
460  //! @name Set Methods
461  //@{
462 
463 
464  //! Set the user defined function
465  /*!
466  @param userDefinedFunction the user defined function
467  */
468  inline void setFunction (const function_Type& userDefinedFunction )
469  {
470  M_userDefinedFunction = userDefinedFunction;
471  }
472 
473  //@}
474 
475 
476  //! @name Get Methods
477  //@{
478 
479 
480  //! Get the function
481  /*!
482  @return Reference to M_userDefinedFunction
483  */
484  inline const function_Type& Function() const
485  {
486  return M_userDefinedFunction;
487  }
488 
489  //@}
490 
491 protected:
492  //! user defined function
494 };
495 
496 
497 //! BCFunctionUDepRobin - class that holds the function used for prescribing Robin boundary conditions.
498 /*!
499  @author Miguel Fernandez
500 
501  This class holds the functions used for prescribing Robin boundary conditions in the case in which the function depend on a FE vector
502  (usually the solution at the previous iteration).
503  This class is derived by BCFunctionUDepBase class
504 
505  In order to prescribe Robin boundary condition we want to add to the system matrix the boundary mass term
506  @verbatim
507  (coeff u, phi)_bd
508  @endverbatim
509  and to add to the right hand side the term
510  @verbatim
511  (f, phi)_bd
512  @endverbatim
513  where u is the solution, phi the test function and @c ( , )_bd the L2 inner product on the boundary
514 
515  Functions f and coeff are set using the correct constructor or using setFunctionRobin(f, coeff). <br>
516  To get the function f use @c getFunction(), to evaluate it use the @c operator(). <br>
517  To get the function coeff use @c getFunction_Robin(), to evaluate it use the method @c coef(...).
518 
519  Function f and coeff have the following signature:
520  @verbatim
521  Real f(const Real& t, const Real& x, const Real& y, const Real& z, const ID& component, const Real& feVectorEvaluatedInThisPoint)
522  @endverbatim
523 
524 
525 */
527 {
528 public:
529 
530  //! @name Public Types
531  //@{
532 
533  typedef BCFunctionUDepBase::function_Type function_Type;
534 
535  //@}
536 
537 
538  //! @name Constructors & Destructor
539  //@{
540 
541  //! Empty constructor
542  /*!
543  The user must supply the functions by calling setFunction_Robin(..)
544  */
546 
547  //! Constructing from user defined functions
548  /*!
549  @param rightHandSideFunction The user defined function for f
550  @param massTermFunction The user defined function for coeff
551  */
552  BCFunctionUDepRobin ( const function_Type& rightHandSideFunction, const function_Type& massTermFunction );
553 
554 
555  //! Copy Constructor
556  /*!
557  @param bcFunctionUDepRobin The BCFunctionUDepRobin object
558  */
559  BCFunctionUDepRobin ( const BCFunctionUDepRobin& bcFunctionUDepRobin );
560 
561 
562  //! Destructor
563  virtual ~BCFunctionUDepRobin() {}
564 
565 
566  //@}
567 
568 
569  //! @name Operators
570  //@{
571 
572 
573  //! Assignment operator
574  /*!
575  @param bcFunctionUDepRobin The BCFunctionUDepRobin object
576  @return Reference to a new BCFunctionUDepRobin object which is a copy of bcFunctionMixt
577  */
579  operator= ( const BCFunctionUDepRobin& bcFunctionUDepRobin );
580 
581 
582  //@}
583 
584 
585  //! @name Methods
586  //@{
587 
588  //! Clone the current object
589  /*!
590  @return Pointer to the cloned object
591  */
593  {
594  BCFunctionUDepBase::BCFunctionUDepBasePtr_Type copy ( new BCFunctionUDepRobin ( M_userDefinedFunction, M_robinBoundaryMassCoeffFunction ) );
595  return copy;
596  }
597 
598  //! evaluate the user defined function M_robinBoundaryMassCoeffFunction
599  /*!
600  @param t Time
601  @param x Coordinate
602  @param y Coordinate
603  @param z Coordinate
604  @param component component of the vector function
605  @param feVectorEvaluatedInThisPoint The FE vector evaluated in the point (x, y, z) at time t.
606  @return selected component of the user defined for @c coeff evaluated in (t,x,y,z)
607  */
608  Real coef ( const Real& t, const Real& x, const Real& y,
609  const Real& z, const ID& component, const Real& feVectorEvaluatedInThisPoint ) const
610  {
611  return M_robinBoundaryMassCoeffFunction (t, x, y, z, component, feVectorEvaluatedInThisPoint);
612  }
613 
614 
615  ///@}
616 
617  //! @name Set Methods
618  //@{
619 
620 
621 
622  //! Set the functions
623  /*!
624  @param rightHandSideFunction The user defined function for f
625  @param massTermFunction The user defined function for @c coeff
626  */
627  void setFunctions_Robin ( const function_Type& rightHandSideFunction, const function_Type& massCoeffFunction );
628 
629  //@}
630 
631 
632  //! @name Get Methods
633  //@{
634 
635 
636  //! Get the user defined function M_robinBoundaryMassCoeffFunction
637  /*!
638  @return user defined function for @c coeff
639  */
640  inline const function_Type& Functions_Robin() const
641  {
643  }
644 
645  //@}
646 
647 private:
648  //! user defined function for the boundary mass coefficient in Robin conditions
650 };
651 
652 
653 /*!
654 
655  \class BCFunctionDirectional
656 
657  Class (STL functor) that holds the user defined fonctions for a directional Dirichlet bc
658 
659  The data funcitions given by the user must have the following declaration
660  Real g(const Real& time, const Real& x, const Real& y, const Real& z, const ID& icomp)
661 */
662 
663 //! BCFunctionUDepBase - class that holds the function used for prescribing boundary conditions.
664 /*!
665  @author Miguel Fernandez
666 
667  This class holds the function used for prescribing Essential boundary conditions along a direction.
668 
669  The data functions given by the user must have the following signature
670 
671  @verbatim
672  Real f(const Real& t, const Real& x, const Real& y, const Real& z, const ID& component)
673  @endverbatim
674 
675  We want to prescribe < u, d > = f on part of the boundary. Here < u, d > is the projection of the solution u along the versor d, which is a given function
676 
677  Functions f and d are set using the correct constructor or using @c setFunction_Directional(f,d).
678 
679  To get the function d use @c Function_Directional(), to evaluate it use the method @c vectFct(...). <br>
680  To get the function f use @c getFunction(), to evaluate it use the @c operator().
681  */
682 
684  :
685 public BCFunctionBase
686 {
687 public:
688 
689  //! @name Public Types
690  //@{
691 
692  typedef BCFunctionBase::function_Type function_Type;
693 
694  //@}
695 
696 
697  //! @name Constructors & Destructor
698 
699  //! Default constructor
700  /*!
701  The user must supply a function by calling setFunction_Directional(..)
702  */
704 
705 
706  //! Constructing from user defined functions
707  /*!
708  @param userDefinedFunctional The user defined function
709  @param userDefinedVersorsFunction user defined function for returning versors along which the essential boundary condition will be prescribed
710  */
711  BCFunctionDirectional ( const function_Type& userDefinedFunctional, const function_Type& userDefinedVersorsFunction );
712 
713  //! Copy Constructor
714  /*!
715  @param bcFunctionDirectional The BCFunctionDirectional
716  */
717  BCFunctionDirectional ( const BCFunctionDirectional& bcFunctionDirectional );
718 
719  virtual ~BCFunctionDirectional() {}
720 
721  //@}
722 
723 
724  //! @name Operators
725  //@{
726 
727  //! Assignment operator
728  /*!
729  @param bdFunctionDirectional The BCFunctionDirectional object
730  @return Reference to a new BCFunctionDirectional object which is a copy of bcFunctionDirectional
731  */
733  operator= ( const BCFunctionDirectional& bcFunctionDirectional );
734 
735 
736  //@}
737 
738 
739  //! @name Methods
740  //@{
741 
742  //! Evaluate the versors' function
743  /*!
744  \param t Time
745  \param x Coordinate
746  \param y Coordinate
747  \param z Coordinate
748  \param component The component of the vectors function
749  \return The selected component of the versors' function evaluated in (t,x,y,z)
750  */
751  inline Real vectFct ( const Real& t, const Real& x, const Real& y,
752  const Real& z, const ID& component ) const
753  {
754  return M_userDefinedVersorsFunction (t, x, y, z, component);
755  }
756 
757  //@}
758 
759 
760 
761  //! @name Set Methods
762  //@{
763 
764 
765  //! Set the functions
766  /*!
767  @param userDefinedFunctional User defined function
768  @param userDefinedVersorsFunction User defined function for returning versors along which the essential boundary condition will be prescribed
769  */
770  void setFunctions_Directional ( const function_Type& userDefinedFunctional, const function_Type& userDefinedVersorsFunction );
771 
772  //@}
773 
774 
775  //! @name Get Methods
776  //@{
777 
778 
779  //! Get the versors' function
780  /*!
781  @return User defined function for returning versors along which the essential boundary condition will be prescribed
782  */
783  inline const function_Type& Functions_Directional() const
784  {
786  }
787 
788  //@}
789 
790 
791 private:
792  //! user defined function returning versors along which the essential boundary condition will be prescribed
794 };
795 
796 }//End of namespace LifeV
797 
798 #endif
Real coef(const Real &t, const Real &x, const Real &y, const Real &z, const ID &component, const Real &feVectorEvaluatedInThisPoint) const
evaluate the user defined function M_robinBoundaryMassCoeffFunction
Definition: BCFunction.hpp:608
virtual ~BCFunctionUDepRobin()
Destructor.
Definition: BCFunction.hpp:563
BCFunctionRobin(const function_Type &rightHandSideFunction, const function_Type &massTermFunction)
Constructing from user defined functions.
Definition: BCFunction.cpp:109
BCFunctionUDepBase - class that holds the function used for prescribing boundary conditions.
Definition: BCFunction.hpp:380
virtual ~BCFunctionRobin()
Destructor.
Definition: BCFunction.hpp:267
BCFunctionUDepBase(const BCFunctionUDepBase &bcFunctionUDepBase)
Copy Constructor.
Definition: BCFunction.cpp:169
BCFunctionUDepRobin()
Empty constructor.
Definition: BCFunction.hpp:545
std::shared_ptr< BCFunctionBase > BCFunctionBasePtr_Type
Definition: BCFunction.hpp:85
const function_Type & Function() const
Get the function.
Definition: BCFunction.hpp:166
BCFunctionDirectional(const BCFunctionDirectional &bcFunctionDirectional)
Copy Constructor.
Definition: BCFunction.cpp:264
BCFunctionBase(function_Type userDefinedFunction)
Constructor for a user defined function.
Definition: BCFunction.cpp:56
BCFunctionUDepBase::BCFunctionUDepBasePtr_Type clone() const
Clone the current object.
Definition: BCFunction.hpp:592
Real vectFct(const Real &t, const Real &x, const Real &y, const Real &z, const ID &component) const
Evaluate the versors&#39; function.
Definition: BCFunction.hpp:751
virtual ~BCFunctionUDepBase()
Destructor.
Definition: BCFunction.hpp:413
virtual BCFunctionUDepBase & operator=(const BCFunctionUDepBase &bcFunctionUDepBase)
Assignment Operator.
Definition: BCFunction.cpp:180
BCFunctionRobin(const BCFunctionRobin &bcFunctionUDepRobin)
Copy Constructor.
Definition: BCFunction.cpp:102
std::function< Real(const Real &, const Real &, const Real &, const Real &, const ID &, const Real &) > function_Type
Definition: BCFunction.hpp:387
void setFunctions_Robin(const function_Type &rightHandSideFunction, const function_Type &massCoeffFunction)
Set the functions.
Definition: BCFunction.cpp:243
void updateInverseJacobian(const UInt &iQuadPt)
function_Type M_robinBoundaryMassCoeffFunction
user defined function for the boundary mass coefficient in Robin conditions
Definition: BCFunction.hpp:649
BCFunctionRobin()
Default constructor.
Definition: BCFunction.hpp:250
const function_Type & Functions_Directional() const
Get the versors&#39; function.
Definition: BCFunction.hpp:783
BCFunctionRobin - class that holds the function used for prescribing Robin boundary conditions...
Definition: BCFunction.hpp:231
BCFunctionBase()
Empty Constructor.
Definition: BCFunction.hpp:96
BCFunctionBase - class that holds the function used for prescribing boundary conditions.
Definition: BCFunction.hpp:77
const function_Type & Functions_Robin() const
Get the user defined function M_robinBoundaryMassCoeffFunction.
Definition: BCFunction.hpp:640
Real coef(const Real &t, const Real &x, const Real &y, const Real &z, const ID &component) const
evaluate the user defined function M_robinBoundaryMassCoeffFunction
Definition: BCFunction.hpp:308
const function_Type & Function() const
Get the function.
Definition: BCFunction.hpp:484
BCFunctionUDepRobin(const BCFunctionUDepRobin &bcFunctionUDepRobin)
Copy Constructor.
Definition: BCFunction.cpp:206
virtual BCFunctionUDepBasePtr_Type clone() const
Clone the current object.
Definition: BCFunction.hpp:452
BCFunctionRobin & operator=(const BCFunctionRobin &bcFunctionUDepRobin)
Assignment operator.
Definition: BCFunction.cpp:124
uint32_type ID
IDs.
Definition: LifeV.hpp:194
void setFunction(const function_Type &userDefinedFunction)
Set the user defined function.
Definition: BCFunction.hpp:468
void setFunctions_Directional(const function_Type &userDefinedFunctional, const function_Type &userDefinedVersorsFunction)
Set the functions.
Definition: BCFunction.cpp:299
virtual BCFunctionBase & operator=(const BCFunctionBase &bcFunctionBase)
Assignment Operator.
Definition: BCFunction.cpp:75
BCFunctionBase(const BCFunctionBase &bcFunctionBase)
Copy Constructor.
Definition: BCFunction.cpp:62
virtual BCFunctionBasePtr_Type clone() const
Clone the current object.
Definition: BCFunction.hpp:180
void setFunction(function_Type userDefinedFunction)
Set the user defined function.
Definition: BCFunction.hpp:152
BCFunctionBase::BCFunctionBasePtr_Type clone() const
Clone the current object.
Definition: BCFunction.hpp:293
BCFunctionDirectional(const function_Type &userDefinedFunctional, const function_Type &userDefinedVersorsFunction)
Constructing from user defined functions.
Definition: BCFunction.cpp:271
Real operator()(const Real &t, const Real &x, const Real &y, const Real &z, const ID &component) const
Overloading function operator by calling M_userDefinedFunction.
Definition: BCFunction.hpp:136
function_Type M_userDefinedFunction
user defined function
Definition: BCFunction.hpp:192
double Real
Generic real data.
Definition: LifeV.hpp:175
std::shared_ptr< BCFunctionUDepBase > BCFunctionUDepBasePtr_Type
Definition: BCFunction.hpp:388
void setFunctions_Robin(const function_Type &rightHandSideFunction, const function_Type &massCoeffFunction)
Set the functions.
Definition: BCFunction.cpp:140
BCFunctionUDepRobin - class that holds the function used for prescribing Robin boundary conditions...
Definition: BCFunction.hpp:526
BCFunctionUDepBase - class that holds the function used for prescribing boundary conditions.
Definition: BCFunction.hpp:683
function_Type M_robinBoundaryMassCoeffFunction
user defined function for the boundary mass coefficient in Robin conditions
Definition: BCFunction.hpp:349
Real operator()(const Real &t, const Real &x, const Real &y, const Real &z, const ID &component, const Real &feVectorEvaluatedInThisPoint) const
Overloading function operator by calling M_userDefinedFunction.
Definition: BCFunction.hpp:437
std::function< Real(const Real &, const Real &, const Real &, const Real &, const ID &) > function_Type
Definition: BCFunction.hpp:84
const function_Type & Functions_Robin() const
Get the user defined function M_robinBoundaryMassCoeffFunction.
Definition: BCFunction.hpp:339
BCFunctionUDepBase()
Empty Constructor.
Definition: BCFunction.hpp:396
BCFunctionDirectional & operator=(const BCFunctionDirectional &bcFunctionDirectional)
Assignment operator.
Definition: BCFunction.cpp:284
function_Type M_userDefinedFunction
user defined function
Definition: BCFunction.hpp:493
function_Type M_userDefinedVersorsFunction
user defined function returning versors along which the essential boundary condition will be prescrib...
Definition: BCFunction.hpp:793
BCFunctionDirectional()
Default constructor.
Definition: BCFunction.hpp:703
BCFunctionUDepRobin & operator=(const BCFunctionUDepRobin &bcFunctionUDepRobin)
Assignment operator.
Definition: BCFunction.cpp:227
BCFunctionUDepRobin(const function_Type &rightHandSideFunction, const function_Type &massTermFunction)
Constructing from user defined functions.
Definition: BCFunction.cpp:213
BCFunctionUDepBase(const function_Type &userDefinedFunction)
Constructor for a user defined function.
Definition: BCFunction.cpp:164
virtual ~BCFunctionBase()
Destructor.
Definition: BCFunction.hpp:112