SpECTRE
v2021.01.11
Documentation
Introduction
Releases
Installation
User Tutorials
Dev Guide
Code of Conduct
Contributing Guide
Code Reference
Topics
Namespaces
Files
Bibliography
View on GitHub
src
Evolution
DiscontinuousGalerkin
NormalVectorTags.hpp
1
// Distributed under the MIT License.
2
// See LICENSE.txt for details.
3
4
#pragma once
5
6
#include <
cstddef
>
7
#include <
optional
>
8
9
#include "DataStructures/DataBox/Tag.hpp"
10
#include "
DataStructures/Tensor/TypeAliases.hpp
"
11
#include "
DataStructures/Variables.hpp
"
12
#include "
Domain/Structure/Direction.hpp
"
13
#include "Domain/Structure/DirectionMap.hpp"
14
#include "
Utilities/TMPL.hpp
"
15
16
/// %Tags used on the interior faces of the elements
17
namespace
evolution::dg::Tags::InternalFace
{
18
/// The magnitude of the unnormalized normal covector to the interface
19
struct
MagnitudeOfNormal
:
db::SimpleTag
{
20
using
type =
Scalar<DataVector>
;
21
};
22
23
/// The normal covector to the interface
24
template
<
size_t
Dim>
25
struct
NormalCovector
:
db::SimpleTag
{
26
using
type = tnsr::i<DataVector, Dim, Frame::Inertial>;
27
};
28
29
/// The normal covector and its magnitude for all internal faces of an element.
30
///
31
/// The combined tag is used to make the allocations be in a Variables
32
///
33
/// We use a `std::optional` to keep track of whether or not these values are
34
/// up-to-date.
35
template
<
size_t
Dim>
36
struct
NormalCovectorAndMagnitude
:
db::SimpleTag
{
37
using
type
=
DirectionMap
<
38
Dim,
std::optional
<
39
Variables<tmpl::list<MagnitudeOfNormal, NormalCovector<Dim>>>>>;
40
};
41
}
// namespace evolution::dg::Tags::InternalFace
evolution::dg::Tags::InternalFace::MagnitudeOfNormal
The magnitude of the unnormalized normal covector to the interface.
Definition:
NormalVectorTags.hpp:19
evolution::dg::Tags::InternalFace::NormalCovector
The normal covector to the interface.
Definition:
NormalVectorTags.hpp:25
db::SimpleTag
Mark a struct as a simple tag by inheriting from this.
Definition:
Tag.hpp:36
cstddef
evolution::dg::Tags::InternalFace
Tags used on the interior faces of the elements
Definition:
NormalVectorTags.hpp:17
evolution::dg::Tags::InternalFace::NormalCovectorAndMagnitude
The normal covector and its magnitude for all internal faces of an element.
Definition:
NormalVectorTags.hpp:36
Variables.hpp
DirectionMap
Definition:
DirectionMap.hpp:15
Scalar
Tensor< T, Symmetry<>, index_list<> > Scalar
Definition:
TypeAliases.hpp:21
TypeAliases.hpp
optional
Direction.hpp
TMPL.hpp
© Copyright 2017 - 2020
SXS Collaboration
,
Distributed under the
MIT License