helical_pipe.cc File Reference
#include "generic.h"
#include "navier_stokes.h"
#include "meshes/tube_mesh.h"

Classes

class  MyHelicalCylinder
 
class  SteadyHelicalProblem< ELEMENT >
 Entry flow problem in tapered tube domain. More...
 

Namespaces

 Global_Physical_Variables
 Global variables.
 

Functions

int main (int argc, char *argv[])
 

Variables

double Global_Physical_Variables::Pitch = 1.0
 

Function Documentation

◆ main()

int main ( int argc  ,
char argv[] 
)

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

334 {
335 
336  // Store command line arguments
337  CommandLineArgs::setup(argc,argv);
338 
339  // Allow (up to) two rounds of fully automatic adapation in response to
340  //-----------------------------------------------------------------------
341  // error estimate
342  //---------------
343  unsigned max_adapt;
344  double max_error_target,min_error_target;
345 
346  // Set max number of adaptations in black-box Newton solver and
347  // error targets for adaptation
348  if (CommandLineArgs::Argc==1)
349  {
350  // Up to two adaptations
351  max_adapt=2;
352 
353  // Error targets for adaptive refinement
354  max_error_target=0.005;
355  min_error_target=0.0005;
356  }
357  // Validation run: Only one adaptation. Relax error targets
358  // to ensure that not all elements are refined so we're getting
359  // some hanging nodes.
360  else
361  {
362  // Validation run: Just one round of adaptation
363  max_adapt=1;
364 
365  // Error targets for adaptive refinement
366  max_error_target=0.02;
367  min_error_target=0.002;
368  }
369  // end max_adapt setup
370 
371 
372  // Set up doc info
373  DocInfo doc_info;
374 
375  // Do Taylor-Hood elements
376  //------------------------
377  {
378  // Set output directory
379  doc_info.set_directory("RESLT_TH");
380 
381  // Step number
382  doc_info.number()=0;
383 
384  // Build problem
386  problem(doc_info,min_error_target,max_error_target);
387 
388  cout << " Doing Taylor-Hood elements " << std::endl;
389 
390  // Solve the problem
391  problem.newton_solve(max_adapt);
392  // Doc solution after solving
393  problem.doc_solution();
394  }
395 
396  // Do Crouzeix-Raviart elements
397  //------------------------
398  {
399  // Set output directory
400  doc_info.set_directory("RESLT_CR");
401 
402  // Step number
403  doc_info.number()=0;
404 
405  // Build problem
407  problem(doc_info,min_error_target,max_error_target);
408 
409  cout << " Doing Crouzeix-Raviart elements " << std::endl;
410 
411  // Solve the problem
412  problem.newton_solve(max_adapt);
413  // Doc solution after solving
414  problem.doc_solution();
415  }
416 
417 } // end_of_main
Entry flow problem in tapered tube domain.
Definition: helical_pipe.cc:103
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
void setup(Time *time_pt)
Create all GeomObjects needed to define the cylinder and the flag.
Definition: turek_flag_non_fsi.cc:277
int Argc
Number of arguments + 1.
Definition: oomph_utilities.cc:407
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

References oomph::CommandLineArgs::Argc, oomph::DocInfo::number(), problem, oomph::DocInfo::set_directory(), and Flag_definition::setup().