mesh_from_inline_triangle_internal_boundaries.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.

612 {
613 
614  // Store command line arguments
615  CommandLineArgs::setup(argc,argv);
616 
617  // Label for output
618  DocInfo doc_info;
619 
620  // Output directory
621  doc_info.set_directory("RESLT");
622 
623 
624  // Do the problem with cubic elements
625  //-----------------------------------
626  {
627  cout << std::endl << "Cubic elements" << std::endl;
628  cout << "==============" << std::endl << std::endl;
629 
630  //Set up the problem
633 
634  // Solve the problem
635  problem.newton_solve();
636 
637  //Output solution
638  problem.doc_solution(doc_info);
639 
640  //Increment counter for solutions
641  doc_info.number()++;
642  }
643 
644 
645  // Do the problem with quadratic elements
646  //---------------------------------------
647  {
648  cout << std::endl << "Quadratic elements" << std::endl;
649  cout << "===================" << std::endl << std::endl;
650 
651  //Set up the problem
654 
655  // Solve the problem
656  problem.newton_solve();
657 
658  //Output solution
659  problem.doc_solution(doc_info);
660 
661  //Increment counter for solutions
662  doc_info.number()++;
663  }
664 
665 
666 
667  // Do the problem with linear elements
668  //------------------------------------
669  {
670  cout << std::endl << "Linear elements" << std::endl;
671  cout << "===============" << std::endl << std::endl;
672 
673  //Set up the problem
676 
677  // Solve the problem
678  problem.newton_solve();
679 
680  //Output solution
681  problem.doc_solution(doc_info);
682 
683  //Increment counter for solutions
684  doc_info.number()++;
685  }
686 
687 }
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().