Reference documentation for deal.II version GIT 85919f3e70 2023-05-28 07:10:01+00:00
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
mg_base.cc
Go to the documentation of this file.
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 1999 - 2021 by the deal.II authors
4 //
5 // This file is part of the deal.II library.
6 //
7 // The deal.II library is free software; you can use it, redistribute
8 // it, and/or modify it under the terms of the GNU Lesser General
9 // Public License as published by the Free Software Foundation; either
10 // version 2.1 of the License, or (at your option) any later version.
11 // The full text of the license can be found in the file LICENSE.md at
12 // the top level directory of deal.II.
13 //
14 // ---------------------------------------------------------------------
15 
19 #include <deal.II/lac/la_vector.h>
25 #include <deal.II/lac/vector.h>
26 
28 
29 
31 
32 
33 template <typename VectorType>
34 void
36  VectorType & u,
37  const VectorType & rhs) const
38 {
39  u = typename VectorType::value_type(0.);
40  smooth(level, u, rhs);
41 }
42 
43 
44 
45 template <typename VectorType>
46 void
48  VectorType & dst,
49  const VectorType & src) const
50 {
51  VectorType temp;
52  temp.reinit(dst, true);
53 
54  this->prolongate(to_level, temp, src);
55 
56  dst += temp;
57 }
58 
59 
60 // Explicit instantiations
61 
62 #include "mg_base.inst"
63 
virtual void apply(const unsigned int level, VectorType &u, const VectorType &rhs) const
Definition: mg_base.cc:35
virtual void prolongate_and_add(const unsigned int to_level, VectorType &dst, const VectorType &src) const
Definition: mg_base.cc:47
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:474
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:475
unsigned int level
Definition: grid_out.cc:4618