two_d_variable_diff_adapt.cc File Reference

Classes

class  RefineableAdvectionDiffusionProblem< ELEMENT >
 

Namespaces

 RachelsAdvectionDiffusion
 

Functions

void RachelsAdvectionDiffusion::get_exact_u (const Vector< double > &x, Vector< double > &u)
 The asymptotic solution. More...
 
void RachelsAdvectionDiffusion::wind_function (const Vector< double > &x, Vector< double > &wind)
 Wind (the underlying velocity field) More...
 
void RachelsAdvectionDiffusion::swimming (const Vector< double > &x, Vector< double > &swim)
 Conserved bit (the swiming velocity) More...
 
void RachelsAdvectionDiffusion::diff_function (const Vector< double > &x, DenseMatrix< double > &D)
 Diffusivity tensor. More...
 
int main ()
 Driver code for 2D AdvectionDiffusion problem. More...
 

Variables

double RachelsAdvectionDiffusion::Peclet =0.01
 Peclet number. More...
 
double RachelsAdvectionDiffusion::U = 0.7
 Swimming speed. More...
 
double RachelsAdvectionDiffusion::D11 = 0.1
 
double RachelsAdvectionDiffusion::D22 = 0.2
 
const double RachelsAdvectionDiffusion::pi = MathematicalConstants::Pi
 The value of pi. More...
 

Function Documentation

◆ main()

int main ( )

Driver code for 2D AdvectionDiffusion problem.

354 {
355 
356  //Set up the problem
357  //------------------
358 
359  // Create the problem with 2D nine-node refineable elements from the
360  // RefineableQuadAdvectionDiffusionElement family. Pass pointer to
361  // source and wind function.
367 
368  // Check if we're ready to go:
369  //----------------------------
370  cout << "\n\n\nProblem self-test ";
371  if (problem.self_test()==0)
372  {
373  cout << "passed: Problem can be solved." << std::endl;
374  }
375  else
376  {
377  throw OomphLibError("Self test failed",
380  }
381 
382  // Solve the problem, performing up to 4 adptive refinements
383  problem.newton_solve(4);
384 
385  //Output the solution
386  problem.doc_solution();
387 
388 } // end of main
Definition: two_d_adv_diff_adapt.cc:103
Definition: oomph_definitions.h:222
Definition: refineable_gen_advection_diffusion_elements.h:202
void diff_function(const Vector< double > &x, DenseMatrix< double > &D)
Diffusivity tensor.
Definition: two_d_variable_diff_adapt.cc:125
void wind_function(const Vector< double > &x, Vector< double > &wind)
Wind (the underlying velocity field)
Definition: two_d_variable_diff_adapt.cc:111
void swimming(const Vector< double > &x, Vector< double > &swim)
Conserved bit (the swiming velocity)
Definition: two_d_variable_diff_adapt.cc:118
#define OOMPH_EXCEPTION_LOCATION
Definition: oomph_definitions.h:61
#define OOMPH_CURRENT_FUNCTION
Definition: oomph_definitions.h:86
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

References RachelsAdvectionDiffusion::diff_function(), OOMPH_CURRENT_FUNCTION, OOMPH_EXCEPTION_LOCATION, problem, RachelsAdvectionDiffusion::swimming(), and RachelsAdvectionDiffusion::wind_function().