SpECTRE
v2021.02.08
Documentation
Introduction
Releases
Installation
User Tutorials
Dev Guide
Code of Conduct
Contributing Guide
Code Reference
Topics
Namespaces
Files
Bibliography
View on GitHub
src
Elliptic
DiscontinuousGalerkin
Penalty.hpp
1
// Distributed under the MIT License.
2
// See LICENSE.txt for details.
3
4
#pragma once
5
6
#include <
cstddef
>
7
8
#include "DataStructures/DataVector.hpp"
9
10
namespace
elliptic::dg
{
11
12
/*!
13
* \brief The penalty factor in internal penalty fluxes
14
*
15
* The penalty factor is computed as
16
*
17
* \f{equation}
18
* \sigma = C \frac{N_\text{points}^2}{h}
19
* \f}
20
*
21
* where \f$N_\text{points} = 1 + N_p\f$ is the number of points (or one plus
22
* the polynomial degree) and \f$h\f$ is a measure of the element size. Both
23
* quantities are taken perpendicular to the face of the DG element that the
24
* penalty is being computed on. \f$C\f$ is the "penalty parameter". For details
25
* see section 7.2 in \cite HesthavenWarburton.
26
*/
27
DataVector
penalty
(
const
DataVector
& element_size,
size_t
num_points,
28
double
penalty_parameter) noexcept;
29
30
}
// namespace elliptic::dg
cstddef
DataVector
Stores a collection of function values.
Definition:
DataVector.hpp:46
elliptic::dg
Functionality related to discontinuous Galerkin discretizations of elliptic equations.
Definition:
DiscontinuousGalerkin.hpp:12
elliptic::dg::penalty
DataVector penalty(const DataVector &element_size, const size_t num_points, const double penalty_parameter) noexcept
The penalty factor in internal penalty fluxes.
Definition:
Penalty.cpp:13
© Copyright 2017 - 2021
SXS Collaboration
,
Distributed under the
MIT License