LifeV
fsi/examples/example_SmoothAneurysm/resistance.hpp
Go to the documentation of this file.
1 /* -*- mode: c++ -*-
2 
3  This file is part of the LifeV Applications.
4 
5  Author(s): Christophe Prud'homme <christophe.prudhomme@epfl.ch>
6  Date: 2005-04-19
7 
8  Copyright (C) 2005 EPFL
9 
10  This program is free software; you can redistribute it and/or modify
11  it under the terms of the GNU General Public License as published by
12  the Free Software Foundation; either version 2.1 of the License, or
13  (at your option) any later version.
14 
15  This program is distributed in the hope that it will be useful, but
16  WITHOUT ANY WARRANTY; without even the implied warranty of
17  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18  General Public License for more details.
19 
20  You should have received a copy of the GNU General Public License
21  along with this program; if not, write to the Free Software
22  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
23  USA
24 */
25 /**
26  \file cylinder.hpp
27  \author Christophe Prud'homme <christophe.prudhomme@epfl.ch>
28  \date 2005-04-19
29  */
30 
31 #ifndef _RESISTANCEFSI_HPP
32 #define _RESISTANCEFSI_HPP
33 
34 // Tell the compiler to ignore specific kind of warnings:
35 #pragma GCC diagnostic ignored "-Wunused-variable"
36 #pragma GCC diagnostic ignored "-Wunused-parameter"
37 
38 // Tell the compiler to ignore specific kind of warnings:
39 #pragma GCC diagnostic warning "-Wunused-variable"
40 #pragma GCC diagnostic warning "-Wunused-parameter"
41 
42 #include <lifev/core/LifeV.hpp>
43 #include <lifev/navier_stokes/solver/OseenSolverShapeDerivative.hpp>
44 #include <lifev/core/mesh/RegionMesh.hpp>
45 #include <lifev/core/array/VectorEpetra.hpp>
46 #include <lifev/core/fem/FESpace.hpp>
47 #include <lifev/fsi/solver/FSIOperator.hpp>
48 /*!
49  * \class Outflow
50  * \brief 2D/3D Cylinder Simulation class
51  *
52  * @author Christophe Prud'homme
53  * @see
54  */
55 
56 namespace LifeV
57 {
58 
60 {
61 public:
62 
63  ResistanceBCs();
64 
65  void initParameters ( const int outflowFlag, const Real resistance, const Real hydrostatic, const std::string name );
66 
67  void renewParameters ( OseenSolverShapeDerivative<RegionMesh<LinearTetra> >& solver, const VectorEpetra& solution, const Real time );
68 
69  Real computeResistance ( const Real time );
70 
71  Real fZero ( const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/ );
72 
73  static Real outPressure0 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
74  static Real outPressure1 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
75  static Real outPressure2 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
76  static Real outPressure3 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
77  static Real outPressure4 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
78  static Real outPressure5 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
79  static Real outPressure6 (const Real& /*t*/, const Real& /*x*/, const Real& /*y*/, const Real& /*z*/, const ID& /*i*/);
80 
81  inline Real resistance( )
82  {
83  return M_resistance;
84  }
85 
86  inline Real flow( )
87  {
88  return M_outflux;
89  }
90 
91  inline std::string name( )
92  {
93  return M_name;
94  }
95 
96  inline Real hydrostatic( )
97  {
98  return M_hydrostaticP;
99  }
100 
101  inline Real outP( )
102  {
103  return M_outP;
104  }
105 
106 private:
108 
113  int M_flag;
115 
117 
119 };
120 
122 {
123 public:
124 
126 
127  void setQuantities ( FSIOperator& _oper, const Real resistance );
128 
129  BCVector& vector()
130  {
131  return bcVectorResistance;
132  }
133 
134 private:
135 
137 
140 };
141 
142 
143 
144 }
145 #endif /* __RESISTANCE_H */
VectorEpetra - The Epetra Vector format Wrapper.
static Real outPressure6(const Real &, const Real &, const Real &, const Real &, const ID &)
void assignFunction(bcBase_Type &base)
Assign the function to the base of the BCHandler.
static Real outPressure3(const Real &, const Real &, const Real &, const Real &, const ID &)
static Real outPressure1(const Real &, const Real &, const Real &, const Real &, const ID &)
void setQuantities(FSIOperator &_oper, const Real resistance)
static Real outPressure0(const Real &, const Real &, const Real &, const Real &, const ID &)
uint32_type ID
IDs.
Definition: LifeV.hpp:194
static Real outPressure2(const Real &, const Real &, const Real &, const Real &, const ID &)
void initParameters(const int outflowFlag, const Real resistance, const Real hydrostatic, const std::string name)
double Real
Generic real data.
Definition: LifeV.hpp:175
static Real outPressure4(const Real &, const Real &, const Real &, const Real &, const ID &)
static Real outPressure5(const Real &, const Real &, const Real &, const Real &, const ID &)
void renewParameters(OseenSolverShapeDerivative< RegionMesh< LinearTetra > > &solver, const VectorEpetra &solution, const Real time)
Real fZero(const Real &, const Real &, const Real &, const Real &, const ID &)
uint32_type UInt
generic unsigned integer (used mainly for addressing)
Definition: LifeV.hpp:191