cylinder_with_flag_domain.h
Go to the documentation of this file.
1 // LIC// ====================================================================
2 // LIC// This file forms part of oomph-lib, the object-oriented,
3 // LIC// multi-physics finite-element library, available
4 // LIC// at http://www.oomph-lib.org.
5 // LIC//
6 // LIC// Copyright (C) 2006-2022 Matthias Heil and Andrew Hazel
7 // LIC//
8 // LIC// This library is free software; you can redistribute it and/or
9 // LIC// modify it under the terms of the GNU Lesser General Public
10 // LIC// License as published by the Free Software Foundation; either
11 // LIC// version 2.1 of the License, or (at your option) any later version.
12 // LIC//
13 // LIC// This library is distributed in the hope that it will be useful,
14 // LIC// but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // LIC// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // LIC// Lesser General Public License for more details.
17 // LIC//
18 // LIC// You should have received a copy of the GNU Lesser General Public
19 // LIC// License along with this library; if not, write to the Free Software
20 // LIC// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21 // LIC// 02110-1301 USA.
22 // LIC//
23 // LIC// The authors may be contacted at oomph-lib@maths.man.ac.uk.
24 // LIC//
25 // LIC//====================================================================
26 #ifndef OOMPH_CYLINDER_WITH_FLAG_DOMAIN_HEADER
27 #define OOMPH_CYLINDER_WITH_FLAG_DOMAIN_HEADER
28 
29 
30 // Generic includes
31 #include "../generic/geom_objects.h"
32 #include "../generic/macro_element.h"
33 #include "../generic/domain.h"
34 
35 
36 namespace oomph
37 {
38  //===========================================================
40  //===========================================================
42  {
43  public:
52  const double& length,
53  const double& height,
54  const double& flag_length,
55  const double& flag_height,
56  const double& centre_x,
57  const double& centre_y,
58  const double& a);
59 
60 
64 
65 
70  void macro_element_boundary(const unsigned& time,
71  const unsigned& m,
72  const unsigned& direction,
73  const Vector<double>& s,
74  Vector<double>& f);
75 
79  {
80  return Cylinder_pt;
81  }
82 
85  {
86  return Bottom_flag_pt;
87  }
89  {
90  return Top_flag_pt;
91  }
93  {
94  return Tip_flag_pt;
95  }
96 
97  private:
101  const Vector<double>& right,
102  const double& s,
103  Vector<double>& f)
104  {
105  for (unsigned i = 0; i < 2; i++)
106  {
107  f[i] = left[i] + (right[i] - left[i]) * 0.5 * (s + 1.0);
108  }
109  }
110 
111  // Helper points
162 
163 
166 
169 
172 
175 
176  // Length of the flag
177  double Lx;
178 
179  // Thickness of the flag
180  double Ly;
181 
182  // Centre of the cylinder : x coordinate
183  double Centre_x;
184 
185  // Centre of the cylinder : y coordinate
186  double Centre_y;
187 
188  // Radius of the cylinder
189  double A;
190 
191 
192  }; // end of domain
193 
194 } // namespace oomph
195 
196 #endif
int i
Definition: BiCGSTAB_step_by_step.cpp:9
Definition: geom_objects.h:873
Domain for cylinder with flag as in Turek benchmark.
Definition: cylinder_with_flag_domain.h:42
Vector< double > p18
Definition: cylinder_with_flag_domain.h:129
Vector< double > p4
Definition: cylinder_with_flag_domain.h:115
Vector< double > p19
Definition: cylinder_with_flag_domain.h:130
Vector< double > p50
Definition: cylinder_with_flag_domain.h:161
Vector< double > p39
Definition: cylinder_with_flag_domain.h:150
Vector< double > p24
Definition: cylinder_with_flag_domain.h:135
Vector< double > p8
Definition: cylinder_with_flag_domain.h:119
Vector< double > p1
Definition: cylinder_with_flag_domain.h:112
GeomObject *& top_flag_pt()
Definition: cylinder_with_flag_domain.h:88
GeomObject * Tip_flag_pt
Pointer to geometric object that represents the tip of the flag.
Definition: cylinder_with_flag_domain.h:174
Vector< double > p33
Definition: cylinder_with_flag_domain.h:144
Vector< double > p47
Definition: cylinder_with_flag_domain.h:158
Vector< double > p17
Definition: cylinder_with_flag_domain.h:128
Vector< double > p15
Definition: cylinder_with_flag_domain.h:126
void macro_element_boundary(const unsigned &time, const unsigned &m, const unsigned &direction, const Vector< double > &s, Vector< double > &f)
Definition: cylinder_with_flag_domain.cc:227
Vector< double > p44
Definition: cylinder_with_flag_domain.h:155
Vector< double > p34
Definition: cylinder_with_flag_domain.h:145
Vector< double > p42
Definition: cylinder_with_flag_domain.h:153
Vector< double > p43
Definition: cylinder_with_flag_domain.h:154
GeomObject *& bottom_flag_pt()
Access fct to GeomObjects for top, bottom and tip.
Definition: cylinder_with_flag_domain.h:84
Vector< double > p27
Definition: cylinder_with_flag_domain.h:138
Vector< double > p2
Definition: cylinder_with_flag_domain.h:113
Vector< double > p28
Definition: cylinder_with_flag_domain.h:139
Vector< double > p20
Definition: cylinder_with_flag_domain.h:131
Vector< double > p46
Definition: cylinder_with_flag_domain.h:157
Vector< double > p29
Definition: cylinder_with_flag_domain.h:140
Vector< double > p32
Definition: cylinder_with_flag_domain.h:143
Vector< double > p3
Definition: cylinder_with_flag_domain.h:114
Vector< double > p16
Definition: cylinder_with_flag_domain.h:127
Vector< double > p45
Definition: cylinder_with_flag_domain.h:156
Vector< double > p22
Definition: cylinder_with_flag_domain.h:133
~CylinderWithFlagDomain()
Definition: cylinder_with_flag_domain.h:63
double Ly
Definition: cylinder_with_flag_domain.h:180
Vector< double > p31
Definition: cylinder_with_flag_domain.h:142
Circle * cylinder_pt()
Definition: cylinder_with_flag_domain.h:78
Vector< double > p36
Definition: cylinder_with_flag_domain.h:147
Vector< double > p26
Definition: cylinder_with_flag_domain.h:137
Vector< double > p6
Definition: cylinder_with_flag_domain.h:117
Vector< double > p12
Definition: cylinder_with_flag_domain.h:123
Vector< double > p9
Definition: cylinder_with_flag_domain.h:120
GeomObject * Top_flag_pt
Pointer to geometric object that represents the top of the flag.
Definition: cylinder_with_flag_domain.h:168
double Centre_x
Definition: cylinder_with_flag_domain.h:183
Vector< double > p38
Definition: cylinder_with_flag_domain.h:149
GeomObject *& tip_flag_pt()
Definition: cylinder_with_flag_domain.h:92
Vector< double > p40
Definition: cylinder_with_flag_domain.h:151
void linear_interpolate(const Vector< double > &left, const Vector< double > &right, const double &s, Vector< double > &f)
Definition: cylinder_with_flag_domain.h:100
Vector< double > p37
Definition: cylinder_with_flag_domain.h:148
CylinderWithFlagDomain(Circle *cylinder_pt, GeomObject *top_flag_pt, GeomObject *bottom_flag_pt, GeomObject *tip_flag_pt, const double &length, const double &height, const double &flag_length, const double &flag_height, const double &centre_x, const double &centre_y, const double &a)
Definition: cylinder_with_flag_domain.cc:37
Vector< double > p49
Definition: cylinder_with_flag_domain.h:160
double Lx
Definition: cylinder_with_flag_domain.h:177
Vector< double > p25
Definition: cylinder_with_flag_domain.h:136
Vector< double > p14
Definition: cylinder_with_flag_domain.h:125
Vector< double > p23
Definition: cylinder_with_flag_domain.h:134
Vector< double > p41
Definition: cylinder_with_flag_domain.h:152
Vector< double > p5
Definition: cylinder_with_flag_domain.h:116
Vector< double > p48
Definition: cylinder_with_flag_domain.h:159
Vector< double > p7
Definition: cylinder_with_flag_domain.h:118
GeomObject * Bottom_flag_pt
Pointer to geometric object that represents the bottom of the flag.
Definition: cylinder_with_flag_domain.h:171
double Centre_y
Definition: cylinder_with_flag_domain.h:186
Vector< double > p11
Definition: cylinder_with_flag_domain.h:122
Vector< double > p30
Definition: cylinder_with_flag_domain.h:141
Vector< double > p13
Definition: cylinder_with_flag_domain.h:124
Vector< double > p10
Definition: cylinder_with_flag_domain.h:121
Circle * Cylinder_pt
Pointer to geometric object that represents the central cylinder.
Definition: cylinder_with_flag_domain.h:165
Vector< double > p21
Definition: cylinder_with_flag_domain.h:132
Vector< double > p35
Definition: cylinder_with_flag_domain.h:146
double A
Definition: cylinder_with_flag_domain.h:189
Definition: domain.h:67
Definition: geom_objects.h:101
static int f(const TensorMap< Tensor< int, 3 > > &tensor)
Definition: cxx11_tensor_map.cpp:237
RealScalar s
Definition: level1_cplx_impl.h:130
const Scalar * a
Definition: level2_cplx_impl.h:32
int * m
Definition: level2_cplx_impl.h:294
double height(const double &x)
Height of domain.
Definition: simple_spine_channel.cc:429
DRAIG: Change all instances of (SPATIAL_DIM) to (DIM-1).
Definition: AnisotropicHookean.h:10