Driver for RefineableDrivenCavity test problem.
267 MPI_Helpers::init(argc,argv);
279 unsigned max_adapt=3;
294 const unsigned n_element=
problem.mesh_pt()->nelement();
298 bool report_stats=
true;
299 out_element_partition=
problem.distribute(report_stats);
302 std::ofstream output_file;
304 sprintf(
filename,
"out_adaptive_cavity_1_partition.dat");
306 for (
unsigned e=0;
e<n_element;
e++)
308 output_file << out_element_partition[
e] << std::endl;
312 problem.check_halo_schemes(doc_info);
317 problem.newton_solve(max_adapt);
320 problem.doc_solution(doc_info);
335 const unsigned n_element=
problem.mesh_pt()->nelement();
339 std::ifstream input_file;
341 sprintf(
filename,
"adaptive_cavity_1_partition.dat");
344 for (
unsigned e=0;
e<n_element;
e++)
346 getline(input_file,input_string,
'\n');
347 element_partition[
e]=atoi(input_string.c_str());
351 bool report_stats=
true;
352 problem.distribute(element_partition,mesh_doc_info,report_stats);
357 problem.newton_solve(max_adapt);
360 problem.doc_solution(doc_info);
365 problem.mesh_pt()->doc_mesh_distribution(mesh_doc_info);
386 problem.check_halo_schemes(doc_info);
390 problem.newton_solve(max_adapt);
396 problem.doc_solution(doc_info);
406 std::ifstream input_file;
410 const unsigned n_element=
problem.mesh_pt()->nelement();
412 sprintf(
filename,
"adaptive_cavity_2_partition.dat");
415 for (
unsigned e=0;
e<n_element;
e++)
417 getline(input_file,input_string,
'\n');
418 element_partition[
e]=atoi(input_string.c_str());
422 bool report_stats=
true;
423 problem.distribute(element_partition,mesh_doc_info,report_stats);
428 problem.newton_solve(max_adapt);
434 problem.doc_solution(doc_info);
438 problem.mesh_pt()->doc_mesh_distribution(mesh_doc_info);
448 MPI_Helpers::finalize();
Array< double, 1, 3 > e(1./3., 0.5, 2.)
Definition: demo_drivers/mpi/distribution/adaptive_driven_cavity/adaptive_driven_cavity.cc:59
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
string filename
Definition: MergeRestartFiles.py:39
int Argc
Number of arguments + 1.
Definition: oomph_utilities.cc:407
std::string string(const unsigned &i)
Definition: oomph_definitions.cc:286
Constructor for SteadyAxisymAdvectionDiffusion problem
Definition: steady_axisym_advection_diffusion.cc:213