pi-DoMUS: Parallel Deal.II MUltiphysics Solver
conservative.h
Go to the documentation of this file.
1 
12 #ifndef _conservative_interface_h
13 #define _conservative_interface_h
14 
15 #include "interfaces/interface.h"
16 
17 using namespace deal2lkit;
18 
19 template<int dim, int spacedim, int n_components, class Implementation, typename LAC=LATrilinos>
20 class ConservativeInterface : public Interface<dim,spacedim,n_components,LAC>
21 {
22 
23  typedef FEValuesCache<dim,spacedim> Scratch;
24  typedef Assembly::CopyData::piDoMUSPreconditioner<dim,spacedim> CopyPreconditioner;
25  typedef Assembly::CopyData::piDoMUSSystem<dim,spacedim> CopySystem;
26 
27 public:
28 
29  virtual ~ConservativeInterface() {};
31  {
33  }
35  {
37  }
38 
39 
40  ConservativeInterface(const std::string &name="",
41  const std::string &default_fe="FE_Q(1)",
42  const std::string &default_component_names="u",
43  const std::string &default_coupling="",
44  const std::string &default_preconditioner_coupling="",
45  const std::string &default_differential_components="") :
46  Interface<dim,spacedim,n_components,LAC>(name, default_fe, default_component_names,
47  default_coupling, default_preconditioner_coupling,
48  default_differential_components) {};
49 
51  Scratch &s,
52  CopySystem &d,
53  Sdouble &e) const
54  {
55  static_cast<const Implementation *>(this)->system_energy(c,s,d,e);
56  }
57 
58 
60  Scratch &s,
61  CopySystem &d,
62  SSdouble &e) const
63  {
64  static_cast<const Implementation *>(this)->system_energy(c,s,d,e);
65  }
66 
67 
69  Scratch &s,
70  CopySystem &d,
71  Sdouble &e) const
72  {
73  static_cast<const Implementation *>(this)->preconditioner_energy(c,s,d,e);
74  }
75 
76 
78  Scratch &s,
79  CopyPreconditioner &d,
80  SSdouble &e) const
81  {
82  static_cast<const Implementation *>(this)->preconditioner_energy(c,s,d,e);
83  }
84 };
85 
86 #endif
virtual void parse_parameters_call_back()
Definition: conservative.h:34
Definition: conservative.h:20
virtual ~ConservativeInterface()
Definition: conservative.h:29
Definition: lac_type.h:33
ActiveSelector::active_cell_iterator active_cell_iterator
Interface.
Definition: old_interface.h:56
virtual void parse_parameters_call_back()
virtual void get_preconditioner_energy(const typename DoFHandler< dim, spacedim >::active_cell_iterator &c, Scratch &s, CopyPreconditioner &d, SSdouble &e) const
Definition: conservative.h:77
ConservativeInterface(const std::string &name="", const std::string &default_fe="FE_Q(1)", const std::string &default_component_names="u", const std::string &default_coupling="", const std::string &default_preconditioner_coupling="", const std::string &default_differential_components="")
Definition: conservative.h:40
virtual void get_system_energy(const typename DoFHandler< dim, spacedim >::active_cell_iterator &c, Scratch &s, CopySystem &d, Sdouble &e) const
Definition: conservative.h:50
virtual void declare_parameters(ParameterHandler &prm)
Definition: conservative.h:30
virtual void get_preconditioner_energy(const typename DoFHandler< dim, spacedim >::active_cell_iterator &c, Scratch &s, CopySystem &d, Sdouble &e) const
Definition: conservative.h:68
virtual void get_system_energy(const typename DoFHandler< dim, spacedim >::active_cell_iterator &c, Scratch &s, CopySystem &d, SSdouble &e) const
Definition: conservative.h:59
virtual void declare_parameters(ParameterHandler &prm)