OISEAU
A modern DGTD framework
Loading...
Searching...
No Matches
ref_hexahedron.hpp
1// Copyright (C) 2025 Tiago V. L. Amorim (@tiagovla)
2//
3// This file is part of oiseau (https://github.com/tiagovla/oiseau)
4//
5// SPDX-License-Identifier: GPL-3.0-or-later
6
7#pragma once
8
9#include <xtensor/core/xtensor_forward.hpp>
10
11#include "oiseau/dg/nodal/ref_element.hpp"
12
13namespace oiseau::dg::nodal {
14
15class RefHexahedron : public RefElement {
16 public:
17 explicit RefHexahedron(unsigned order);
18 xt::xarray<double> basis_function(const xt::xarray<double>& rst, int i, int j, int k) const;
19 xt::xarray<double> grad_basis_function(const xt::xarray<double>& rst, int i, int j, int k) const;
20
21 private:
22 xt::xarray<double> vandermonde(const xt::xarray<double>& rst) const;
23 xt::xarray<double> grad_vandermonde(const xt::xarray<double>& rst) const;
24 xt::xarray<double> grad_operator(const xt::xarray<double>& v, const xt::xarray<double>& gv) const;
25};
26
27namespace detail {
28
29xt::xarray<double> generate_hexahedron_nodes(unsigned order);
30
31}
32} // namespace oiseau::dg::nodal