free_surface_rotation.cc File Reference
#include "generic.h"
#include "navier_stokes.h"
#include "fluid_interface.h"
#include "meshes/quarter_tube_mesh.h"

Classes

class  AxialSpineQuarterTubeMesh< ELEMENT, INTERFACE_ELEMENT >
 
class  FreeSurfaceRotationProblem< ELEMENT >
 Entry flow problem in quarter tube domain. More...
 

Namespaces

 Global_Physical_Variables
 Global variables.
 
 WallFunction
 

Functions

void WallFunction::normal (const Vector< double > &x, Vector< double > &normal)
 
int main (int argc, char *argv[])
 

Variables

double Global_Physical_Variables::Omega = 0.0
 Rotation rate. More...
 
Vector< doubleGlobal_Physical_Variables::G (3) = 1.0
 Direction of gravity. More...
 

Function Documentation

◆ main()

int main ( int argc  ,
char argv[] 
)

///////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////// Driver for 3D entry flow into a quarter tube. If there are any command line arguments, we regard this as a validation run and perform only a single adaptation

666 {
667 
668  // Store command line arguments
669  CommandLineArgs::setup(argc,argv);
670 
671  // Allow (up to) five rounds of fully automatic adapation in response to
672  //-----------------------------------------------------------------------
673  // error estimate
674  //---------------
675  //unsigned max_adapt;
676  double max_error_target,min_error_target;
677 
678  using namespace Global_Physical_Variables;
679 
680  G[0] = 0.0; G[1] = 0.0; G[2] = -1.0;
681 
682 
683  // Set max number of adaptations in black-box Newton solver and
684  // error targets for adaptation
685  if (CommandLineArgs::Argc==1)
686  {
687  // Up to five adaptations
688  //max_adapt=5;
689 
690  // Error targets for adaptive refinement
691  max_error_target=0.005;
692  min_error_target=0.0005;
693  }
694  // Validation run: Only one adaptation. Relax error targets
695  // to ensure that not all elements are refined so we're getting
696  // some hanging nodes.
697  else
698  {
699  // Validation run: Just one round of adaptation
700  //max_adapt=1;
701 
702  // Error targets for adaptive refinement
703  max_error_target=0.02;
704  min_error_target=0.002;
705  }
706  // end max_adapt setup
707 
708 
709  // Set up doc info
710  DocInfo doc_info;
711 
712  const double pi = MathematicalConstants::Pi;
713  // Do Taylor-Hood elements
714  //------------------------
715  {
716  // Set output directory
717  doc_info.set_directory("RESLT_TH");
718 
719  // Step number
720  doc_info.number()=0;
721 
722  // Build problem
724  problem(doc_info,min_error_target,max_error_target);
725 
726  cout << " Doing Taylor-Hood elements " << std::endl;
727 
728 
729  // Doc solution after solving
730  problem.doc_solution();
731 
732  // Solve the problem (DO NOT ADAPT)
733  problem.newton_solve();
734 
735 
736  for(unsigned i=0;i<5;i++)
737  {
738  Angle -= 0.05*pi;
739  problem.newton_solve();
740  }
741  }
742 
743 
744  // Do Crouzeix-Raviart elements
745  //-----------------------------
746  {
747  // Set output directory
748  doc_info.set_directory("RESLT_CR");
749 
750  // Step number
751  doc_info.number()=0;
752 
753  // Build problem
756  problem(doc_info,min_error_target,max_error_target);
757 
758  cout << " Doing Crouzeix-Raviart elements " << std::endl;
759 
760  // Solve the problem DO NOT ADAPT
761  problem.newton_solve();
762  }
763 
764 } // end_of_main
int i
Definition: BiCGSTAB_step_by_step.cpp:9
Entry flow problem in quarter tube domain.
Definition: free_surface_rotation.cc:389
Definition: oomph_utilities.h:499
void set_directory(const std::string &directory)
Definition: oomph_utilities.cc:298
unsigned & number()
Number used (e.g.) for labeling output files.
Definition: oomph_utilities.h:554
Definition: spines.h:477
double Pi
Definition: two_d_biharmonic.cc:235
void setup(Time *time_pt)
Create all GeomObjects needed to define the cylinder and the flag.
Definition: turek_flag_non_fsi.cc:277
Global variables.
Definition: TwenteMeshGluing.cpp:60
double Angle
The contact angle.
Definition: marangoni_convection_box.cc:564
Vector< double > G(3)
Direction of gravity.
Definition: spherical_shell_convection.cc:62
const Mdouble pi
Definition: ExtendedMath.h:23
int Argc
Number of arguments + 1.
Definition: oomph_utilities.cc:407
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

References Global_Physical_Variables::Angle, oomph::CommandLineArgs::Argc, G, i, oomph::DocInfo::number(), constants::pi, BiharmonicTestFunctions2::Pi, problem, oomph::DocInfo::set_directory(), and Flag_definition::setup().