Theory and Practice of FEM -- a parametrized Poisson Solver
main.cc
Go to the documentation of this file.
1
#include <
deal.II/base/utilities.h
>
2
3
#include "
poisson.h
"
4
24
int
25
main
(
int
argc,
char
**argv)
26
{
27
try
28
{
29
using namespace
dealii
;
30
31
Utilities::MPI::MPI_InitFinalize
mpi_initialization(argc, argv, 1);
32
std::string par_name =
""
;
33
if
(argc > 1)
34
par_name = argv[1];
35
36
if
(
Utilities::MPI::this_mpi_process
(MPI_COMM_WORLD) == 0)
37
deallog
.
depth_console
(2);
38
else
39
deallog
.
depth_console
(0);
40
41
Poisson<2>
laplace_problem;
42
laplace_problem.
initialize
(par_name);
43
laplace_problem.
run
();
44
}
45
catch
(std::exception &exc)
46
{
47
std::cerr << std::endl
48
<< std::endl
49
<<
"----------------------------------------------------"
50
<< std::endl;
51
std::cerr <<
"Exception on processing: "
<< std::endl
52
<< exc.what() << std::endl
53
<<
"Aborting!"
<< std::endl
54
<<
"----------------------------------------------------"
55
<< std::endl;
56
57
return
1;
58
}
59
catch
(...)
60
{
61
std::cerr << std::endl
62
<< std::endl
63
<<
"----------------------------------------------------"
64
<< std::endl;
65
std::cerr <<
"Unknown exception!"
<< std::endl
66
<<
"Aborting!"
<< std::endl
67
<<
"----------------------------------------------------"
68
<< std::endl;
69
return
1;
70
}
71
72
return
0;
73
}
LogStream::depth_console
unsigned int depth_console(const unsigned int n)
Utilities::MPI::MPI_InitFinalize
Poisson
Definition:
poisson.h:73
Poisson::initialize
void initialize(const std::string &filename)
Definition:
poisson.cc:94
Poisson::run
void run()
Definition:
poisson.cc:525
utilities.h
deallog
LogStream deallog
main
int main(int argc, char **argv)
Definition:
main.cc:25
Utilities::MPI::this_mpi_process
unsigned int this_mpi_process(const MPI_Comm &mpi_communicator)
dealii
poisson.h
github
workspace
source
main.cc
Generated on Tue May 11 2021 07:24:45 for Theory and Practice of FEM -- a parametrized Poisson Solver by
1.9.1