31 #ifndef OOMPH_QUARTER_TUBE_DOMAIN_HEADER 32 #define OOMPH_QUARTER_TUBE_DOMAIN_HEADER 35 #include "../generic/quadtree.h" 36 #include "../generic/domain.h" 37 #include "../generic/geom_objects.h" 60 const double& fract_mid,
62 const unsigned& nlayer) :
68 unsigned nmacro=3*nlayer;
74 for (
unsigned i=0;
i<nmacro;
i++)
153 const unsigned& i_macro,
154 const unsigned& i_direct,
321 const unsigned& imacro,
322 const unsigned& idirect,
327 using namespace OcTreeNames;
329 #ifdef WARN_ABOUT_SUBTLY_CHANGED_OOMPH_INTERFACES 332 "Order of function arguments has changed between versions 0.8 and 0.85",
333 "QuarterTubeDomain::macro_element_boundary(...)",
334 OOMPH_EXCEPTION_LOCATION);
338 unsigned ilayer=unsigned(imacro/3);
376 std::ostringstream error_stream;
377 error_stream <<
"idirect is " << idirect
378 <<
" not one of L, R, D, U, B, F" << std::endl;
382 OOMPH_CURRENT_FUNCTION,
383 OOMPH_EXCEPTION_LOCATION);
420 std::ostringstream error_stream;
421 error_stream <<
"idirect is " << idirect
422 <<
" not one of L, R, D, U, B, F" << std::endl;
426 OOMPH_CURRENT_FUNCTION,
427 OOMPH_EXCEPTION_LOCATION);
464 std::ostringstream error_stream;
465 error_stream <<
"idirect is " << idirect
466 <<
" not one of L, R, D, U, B, F" << std::endl;
470 OOMPH_CURRENT_FUNCTION,
471 OOMPH_EXCEPTION_LOCATION);
479 std::ostringstream error_stream;
480 error_stream <<
"Wrong imacro " << imacro << std::endl;
483 OOMPH_CURRENT_FUNCTION,
484 OOMPH_EXCEPTION_LOCATION);
497 const unsigned& i_layer,
513 f[1]=r_top[1]*0.25*(1.0+zeta[0]);
516 f[2]=x[0]+rho*(r_top[2]-x[0]);
531 const unsigned& i_layer,
557 f[0]=0.5*r_bottom[0];
558 f[1]=r_top[1]*0.25*(1.0+zeta[0]);
562 f[2]=x[0]+rho*(r_top[2]-x[0]);
579 const unsigned& i_layer,
594 f[0]=r_bottom[0]*0.25*(1.0+zeta[0]);
599 f[2]=x[0]+rho*(r_bottom[2]-x[0]);
612 const unsigned& i_layer,
635 f[0]=r_bottom[0]*0.25*(1.0+zeta[0]);
640 f[2]=x[0]+rho*(r_bottom[2]-x[0]);
654 const unsigned& i_layer,
678 f[0]=r_bottom[0]*0.25*(1.0+zeta[0]);
679 f[1]=r_top[1]*0.25*(1.0+zeta[1]);
683 f[2]=x[0]+rho*(r_top[2]-x[0]);
698 const unsigned& i_layer,
722 f[0]=r_bottom[0]*0.25*(1.0+zeta[0]);
723 f[1]=r_top[1]*0.25*(1.0+zeta[1]);
727 f[2]=x[0]+rho*(r_top[2]-x[0]);
745 const unsigned& i_layer,
759 const unsigned& i_layer,
783 const unsigned& i_layer,
798 f[0]=0.5*r_bottom[0]*(1.0+
s_squashed(0.5*(1.0+zeta[0])));
803 f[2]=x[0]+rho*(r_bottom[2]-x[0]);
816 const unsigned& i_layer,
835 zeta_central[1]=zeta[1];
836 r_centr_R(t,zeta_central,i_layer,r_central);
841 f[0]=r_central[0]+(r_div[0]-r_central[0])*
s_squashed(0.5*(1.0+zeta[0]));
842 f[1]=r_central[1]+(r_div[1]-r_central[1])*
s_squashed(0.5*(1.0+zeta[0]));
843 f[2]=r_central[2]+(r_div[2]-r_central[2])*
s_squashed(0.5*(1.0+zeta[0]));
855 const unsigned& i_layer,
871 zeta_central[0]=zeta[1];
872 zeta_central[1]=-1.0;
873 r_centr_R(t,zeta_central,i_layer,r_central);
877 f[0]=r_central[0]+(r_wall[0]-r_central[0])*
s_squashed(0.5*(1.0+zeta[0]));
878 f[1]=r_central[1]+(r_wall[1]-r_central[1])*
s_squashed(0.5*(1.0+zeta[0]));
879 f[2]=r_central[2]+(r_wall[2]-r_central[2])*
s_squashed(0.5*(1.0+zeta[0]));
896 const unsigned& i_layer,
913 zeta_central[0]=zeta[1];
915 r_centr_R(t,zeta_central,i_layer,r_central);
919 f[0]=r_central[0]+(r_wall[0]-r_central[0])*
s_squashed(0.5*(1.0+zeta[0]));
920 f[1]=r_central[1]+(r_wall[1]-r_central[1])*
s_squashed(0.5*(1.0+zeta[0]));
921 f[2]=r_central[2]+(r_wall[2]-r_central[2])*
s_squashed(0.5*(1.0+zeta[0]));
938 const unsigned& i_layer,
954 f[1]=0.5*r_top[1]*(1.0+
s_squashed(0.5*(1.0+zeta[0])));
958 f[2]=x[0]+rho*(r_top[2]-x[0]);
971 const unsigned& i_layer,
990 const unsigned& i_layer,
1003 const unsigned& i_layer,
1027 const unsigned& i_layer,
1046 zeta_central[0]=zeta[0];
1047 zeta_central[1]=-1.0;
1048 r_centr_U(t,zeta_central,i_layer,r_central);
1051 f[0]=r_central[0]+(r_wall[0]-r_central[0])*
s_squashed(0.5*(1.0+zeta[1]));
1052 f[1]=r_central[1]+(r_wall[1]-r_central[1])*
s_squashed(0.5*(1.0+zeta[1]));
1053 f[2]=r_central[2]+(r_wall[2]-r_central[2])*
s_squashed(0.5*(1.0+zeta[1]));
1067 const unsigned& i_layer,
1086 zeta_central[0]=zeta[0];
1087 zeta_central[1]=1.0;
1088 r_centr_U(t,zeta_central,i_layer,r_central);
1091 f[0]=r_central[0]+(r_wall[0]-r_central[0])*
s_squashed(0.5*(1.0+zeta[1]));
1092 f[1]=r_central[1]+(r_wall[1]-r_central[1])*
s_squashed(0.5*(1.0+zeta[1]));
1093 f[2]=r_central[2]+(r_wall[2]-r_central[2])*
s_squashed(0.5*(1.0+zeta[1]));
AxialSpacingFctPt & axial_spacing_fct_pt()
Function pointer for function that implements axial spacing of macro elements.
void r_bot_right_L(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of bottom right box macro element in layer i_layer zeta .
double axial_spacing_fct(const double &xi)
Function that implements axial spacing of macro elements.
void broken_copy(const std::string &class_name)
Issue error message and terminate execution.
void r_top_left_R(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of top left box macro element in layer i_layer zeta .
static double default_axial_spacing_fct(const double &xi)
Default for function that implements axial spacing of macro elements.
void r_centr_L(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of central box macro element in layer i_layer zeta .
Vector< MacroElement * > Macro_element_pt
Vector of pointers to macro elements.
void r_top_left_B(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of top left box macro element in layer i_layer zeta .
unsigned Nlayer
Number of layers.
void r_top_left_F(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of top left box macro element in layer i_layer zeta .
BLSquashFctPt BL_squash_fct_pt
Function pointer for function that squashes the outer two macro elements towards the wall by mapping ...
virtual void position(const Vector< double > &zeta, Vector< double > &r) const =0
Parametrised position on object at current time: r(zeta).
static double default_BL_squash_fct(const double &s)
Default for function that squashes the outer two macro elements towards the wall by mapping the input...
double(* AxialSpacingFctPt)(const double &xi)
Typedef for function pointer for function that implements axial spacing of macro elements.
QuarterTubeDomain(GeomObject *boundary_geom_object_pt, const Vector< double > &xi_lo, const double &fract_mid, const Vector< double > &xi_hi, const unsigned &nlayer)
Constructor: Pass boundary object and start and end coordinates and fraction along boundary object wh...
void r_bot_right_B(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of bottom right box macro element in layer i_layer zeta .
void r_centr_R(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of central box macro element in layer i_layer zeta .
GeomObject * Wall_pt
Pointer to geometric object that represents the curved wall.
BLSquashFctPt & bl_squash_fct_pt()
Function pointer for function that squashes the outer two macro elements towards the wall by mapping ...
Vector< double > Xi_lo
Lower limit for the coordinates along the wall.
void r_centr_D(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of central box macro element in layer i_layer zeta .
void r_centr_B(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of central box macro element in layer i_layer zeta .
double(* BLSquashFctPt)(const double &s)
Typedef for function pointer for function that squashes the outer two macro elements towards the wall...
AxialSpacingFctPt Axial_spacing_fct_pt
Function pointer for function that implements axial spacing of macro elements.
void r_top_left_D(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of top left box macro element in layer i_layer zeta .
void r_bot_right_R(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of bottom right box macro element in layer i_layer zeta .
Quarter tube as domain. Domain is bounded by curved boundary which is represented by a GeomObject...
double s_squashed(const double &s)
Function that squashes the outer two macro elements towards the wall by mapping the input value of th...
Vector< double > Xi_hi
Upper limit for the coordinates along the wall.
void broken_assign(const std::string &class_name)
Issue error message and terminate execution.
void r_bot_right_D(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of bottom right box macro element in layer i_layer zeta .
void macro_element_boundary(const unsigned &t, const unsigned &i_macro, const unsigned &i_direct, const Vector< double > &s, Vector< double > &f)
Vector representation of the i_macro-th macro element boundary i_direct (L/R/D/U/B/F) at time level t...
void r_top_left_L(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of top left box macro element in layer i_layer zeta .
QuarterTubeDomain(const QuarterTubeDomain &)
Broken copy constructor.
void r_centr_F(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of central box macro element in layer i_layer zeta .
void operator=(const QuarterTubeDomain &)
Broken assignment operator.
double Fract_mid
Fraction along wall where outer ring is to be divided.
void r_bot_right_U(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of bottom right box macro element in layer i_layer zeta .
Base class for Domains with curvilinear and/or time-dependent boundaries. Domain boundaries are typic...
~QuarterTubeDomain()
Destructor: Kill macro elements.
void r_bot_right_F(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of bottom right box macro element in layer i_layer zeta .
void r_top_left_U(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of top left box macro element in layer i_layer zeta .
void r_centr_U(const unsigned &t, const Vector< double > &zeta, const unsigned &i_layer, Vector< double > &f)
Boundary of central box macro element in layer i_layer zeta .