mesh_from_inline_triangle_internal_boundaries_extra.cc File Reference
#include "generic.h"
#include "poisson.h"
#include "meshes/triangle_mesh.h"

Classes

class  PoissonProblem< ELEMENT >
 Micky mouse Poisson problem. More...
 

Namespaces

 TanhSolnForPoisson
 Namespace for exact solution for Poisson equation with "sharp step".
 

Functions

void TanhSolnForPoisson::get_exact_u (const Vector< double > &x, Vector< double > &u)
 Exact solution as a Vector. More...
 
void TanhSolnForPoisson::get_exact_u (const Vector< double > &x, double &u)
 Exact solution as a scalar. More...
 
void TanhSolnForPoisson::get_source (const Vector< double > &x, double &source)
 Source function to make it an exact solution. More...
 
int main (int argc, char *argv[])
 Demonstrate how to solve Poisson problem. More...
 

Function Documentation

◆ main()

int main ( int argc  ,
char argv[] 
)

Demonstrate how to solve Poisson problem.

656 {
657 
658  // Store command line arguments
659  CommandLineArgs::setup(argc,argv);
660 
661  // Label for output
662  DocInfo doc_info;
663 
664  // Output directory
665  doc_info.set_directory("RESLT");
666 
667 
668  // Do the problem with cubic elements
669  //-----------------------------------
670  {
671  cout << std::endl << "Cubic elements" << std::endl;
672  cout << "==============" << std::endl << std::endl;
673 
674  //Set up the problem
677 
678  // Solve the problem
679  problem.newton_solve();
680 
681  //Output solution
682  problem.doc_solution(doc_info);
683 
684  //Increment counter for solutions
685  doc_info.number()++;
686  }
687 
688 
689  // Do the problem with quadratic elements
690  //---------------------------------------
691  {
692  cout << std::endl << "Quadratic elements" << std::endl;
693  cout << "===================" << std::endl << std::endl;
694 
695  //Set up the problem
698 
699  // Solve the problem
700  problem.newton_solve();
701 
702  //Output solution
703  problem.doc_solution(doc_info);
704 
705  //Increment counter for solutions
706  doc_info.number()++;
707  }
708 
709 
710 
711  // Do the problem with linear elements
712  //------------------------------------
713  {
714  cout << std::endl << "Linear elements" << std::endl;
715  cout << "===============" << std::endl << std::endl;
716 
717  //Set up the problem
720 
721  // Solve the problem
722  problem.newton_solve();
723 
724  //Output solution
725  problem.doc_solution(doc_info);
726 
727  //Increment counter for solutions
728  doc_info.number()++;
729  }
730 
731 }
Micky mouse Poisson problem.
Definition: HypreSolver_test.cc:81
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
void get_source(const Vector< double > &x, double &source)
Source function to make it an exact solution.
Definition: extrude_with_macro_element_representation.cc:224
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213

References TanhSolnForPoisson::get_source(), oomph::DocInfo::number(), problem, oomph::DocInfo::set_directory(), and Flag_definition::setup().