Logbook  (07-04-2025)
Static problems
solver.hpp
1 /******************************************************************************
2  * Copyright (C) Siarhei Uzunbajakau, 2023.
3  *
4  * This program is free software. You can use, modify, and redistribute it under
5  * the terms of the GNU Lesser General Public License as published by the Free
6  * Software Foundation, either version 3 or (at your option) any later version.
7  * This program is distributed without any warranty.
8  *
9  * Refer to COPYING.LESSER for more details.
10  ******************************************************************************/
11 
12 #ifndef SolverSSOLI_H__
13 #define SolverSSOLI_H__
14 
15 #include <deal.II/base/tensor_function.h>
16 #include <deal.II/base/vectorization.h>
17 
18 #include <deal.II/lac/precondition.h>
19 #include <deal.II/lac/solver_cg.h>
20 #include <deal.II/lac/solver_control.h>
21 #include <deal.II/lac/sparse_direct.h>
22 
23 #include <deal.II/grid/grid_generator.h>
24 #include <deal.II/grid/grid_in.h>
25 #include <deal.II/grid/grid_tools.h>
26 #include <deal.II/grid/manifold_lib.h>
27 
28 #include <string>
29 
30 #include "exact_solution.hpp"
31 #include "settings.hpp"
32 #include "static_vector_solver_i.hpp"
33 
34 using namespace StaticVectorSolver;
35 
42  : public SettingsSSOLI
43  , public Solver1<3>
44 {
45 public:
46  SolverSSOLI() = delete;
47 
61  SolverSSOLI(unsigned int p,
62  unsigned int mapping_degree,
63  unsigned int r,
64  std::string fname)
65  : Solver1<3>(p,
66  mapping_degree,
67  0,
68  0.0000001 / mu_0,
69  fname,
70  nullptr,
71  SettingsSSOLI::print_time_tables,
72  false,
73  true)
74  , r(r)
75  , fname(fname)
76  {
78  }
79 
80  ~SolverSSOLI() = default;
81 
82 private:
83  const unsigned int r;
84  const std::string fname;
85 
86  virtual void make_mesh() override final;
87  virtual void fill_dirichlet_stack() override final;
88  virtual void solve() override final;
89 
90  void mark_materials();
91 
92  const SphericalManifold<3> sphere;
93 };
94 
95 #endif
Global settings for the Thin spherical coil (ssol-i/) numerical experiment.
Definition: settings.hpp:26
Solves for the magnetic vector potential, , in the Thin spherical coil (ssol-i/) numerical experiment...
Definition: solver.hpp:44
SolverSSOLI(unsigned int p, unsigned int mapping_degree, unsigned int r, std::string fname)
Definition: solver.hpp:61
Solves static vector boundary value problem.
void run()
Runs the simulation.