Doxygen API reference documentation for ideal.II
All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator
slab_tria.hh
1// ---------------------------------------------------------------------
2//
3// Copyright (C) 2022 - 2023 by the ideal.II authors
4//
5// This file is part of the ideal.II library.
6//
7// The ideal.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 3.0 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 ideal.II.
13//
14// ---------------------------------------------------------------------
15
16#ifndef INCLUDE_IDEAL_II_GRID_SLAB_TRIA_HH_
17#define INCLUDE_IDEAL_II_GRID_SLAB_TRIA_HH_
18
19#include <deal.II/grid/tria.h>
20
21#include <list>
22#include <memory>
23
24namespace idealii::slab
25{
33 template <int dim>
35 {
36 public:
45 Triangulation(std::shared_ptr<dealii::Triangulation<dim>> space_tria,
46 double startpoint,
47 double endpoint);
48
58 Triangulation(std::shared_ptr<dealii::Triangulation<dim>> space_tria,
59 std::vector<double> step_sizes,
60 double startpoint,
61 double endpoint);
62
79 std::shared_ptr<dealii::Triangulation<dim>>
81
85 std::shared_ptr<dealii::Triangulation<1>>
87
91 double
93
97 double
99
109 void
110 update_temporal_triangulation(std::vector<double> step_sizes,
111 double startpoint,
112 double endpoint);
113
114 private:
115 std::shared_ptr<dealii::Triangulation<dim>> _spatial_tria;
116 std::shared_ptr<dealii::Triangulation<1>> _temporal_tria;
117 double _startpoint;
118 double _endpoint;
119 };
120
124 template <int dim>
125 using TriaIterator = typename std::list<Triangulation<dim>>::iterator;
126} // namespace idealii::slab
127
128#endif /* INCLUDE_IDEAL_II_GRID_SLAB_TRIA_HH_ */
Actual Triangulation for a specific slab.
Definition slab_tria.hh:35
Triangulation(std::shared_ptr< dealii::Triangulation< dim > > space_tria, std::vector< double > step_sizes, double startpoint, double endpoint)
Construct an object with a given spatial triangulation and a given division of elements in time.
std::shared_ptr< dealii::Triangulation< 1 > > temporal()
The underlying temporal triangulation.
Triangulation(std::shared_ptr< dealii::Triangulation< dim > > space_tria, double startpoint, double endpoint)
Construct an object with a given spatial triangulation and a single element in time.
void update_temporal_triangulation(std::vector< double > step_sizes, double startpoint, double endpoint)
Change the temporal triangulation to the given division.
std::shared_ptr< dealii::Triangulation< dim > > spatial()
The underlying spatial triangulation.
double endpoint()
The endpoint of the temporal triangulation.
Triangulation(const Triangulation &other)
(shallow) copy constructor. Only the values for the start- and endpoint are actually copied....
double startpoint()
The startpoint of the temporal triangulation.
Namespace for slab objects.
Definition idealii.hh:33
typename std::list< Triangulation< dim > >::iterator TriaIterator
A shortened type for Iterators over a list of shared pointers to Triangulation<dim> objects.
Definition slab_tria.hh:125