File: e-lagrange.h

package info (click to toggle)
fenics-basix 0.10.0.post0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,156 kB
  • sloc: cpp: 23,435; python: 10,829; makefile: 43; sh: 26
file content (35 lines) | stat: -rw-r--r-- 1,388 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
// Copyright (c) 2020-2022 Chris Richardson, Matthew Scroggs and Garth N. Wells
// FEniCS Project
// SPDX-License-Identifier:    MIT

#pragma once

#include "cell.h"
#include "element-families.h"
#include "finite-element.h"
#include <concepts>

namespace basix::element
{
/// @brief Create a Lagrange(-like) element on cell with given degree
/// @param[in] celltype The element cell type
/// @param[in] degree The degree of the element
/// @param[in] variant The variant of the element to be created
/// @param[in] discontinuous True if the is discontinuous
/// @param[in] dof_ordering DOF reordering
/// @return A finite element
template <std::floating_point T>
FiniteElement<T> create_lagrange(cell::type celltype, int degree,
                                 lagrange_variant variant, bool discontinuous,
                                 std::vector<int> dof_ordering = {});

/// @brief Create an iso macro element on cell with given degree
/// @param[in] celltype The element cell type
/// @param[in] degree The degree of the element
/// @param[in] variant The variant of the element to be created
/// @param[in] discontinuous True if the is discontinuous
/// @return A finite element
template <std::floating_point T>
FiniteElement<T> create_iso(cell::type celltype, int degree,
                            lagrange_variant variant, bool discontinuous);
} // namespace basix::element