MFEM
v4.9.0
Finite element discretization library
Loading...
Searching...
No Matches
fem
moonolith
transferutils.hpp
Go to the documentation of this file.
1
// Copyright (c) 2010-2025, Lawrence Livermore National Security, LLC. Produced
2
// at the Lawrence Livermore National Laboratory. All Rights reserved. See files
3
// LICENSE and NOTICE for details. LLNL-CODE-806117.
4
//
5
// This file is part of the MFEM library. For more information and source code
6
// availability visit https://mfem.org.
7
//
8
// MFEM is free software; you can redistribute it and/or modify it under the
9
// terms of the BSD-3 license. We welcome feedback and contributions, see file
10
// CONTRIBUTING.md for details.
11
12
#ifndef MFEM_L2P_MESH_UTILS_HPP
13
#define MFEM_L2P_MESH_UTILS_HPP
14
15
#include "
../../config/config.hpp
"
16
17
#ifdef MFEM_USE_MOONOLITH
18
19
#include "
../../mesh/hexahedron.hpp
"
20
#include "
../../mesh/quadrilateral.hpp
"
21
#include "
../fem.hpp
"
22
23
namespace
mfem
24
{
25
26
// These methods are to be used exclusively inside the routines inside the
27
// transfer functionalities
28
namespace
internal
29
{
30
31
/*!
32
* @brief Creates a new element based on the type and cell data.
33
* @param type The element type (Geometry::TRIANGLE, Geometry::TETRAHEDRON,
34
* Geometry::SQUARE, Geometry::CUBE).
35
* @param cells_data The element connectivity.
36
* @param attr The element attribute.
37
*/
38
Element *NewElem(
const
int
type,
const
int
*cells_data,
const
int
attr);
39
40
/*!
41
* @brief Finalizes the mesh based on the element type
42
* @param mesh The mesh.
43
* @param generate_edges True if the generation of edges is requested, false if
44
* not.
45
*/
46
void
Finalize(Mesh &mesh,
const
bool
generate_edges);
47
48
/*!
49
* @brief Computes a column vector containing the maximum element for each row
50
* @param mat The matrix
51
* @param vec[out] The vector where we store the result
52
* @param include_vec_elements True if we consider vec as an additional column
53
* of the matrix, False otherwise.
54
*/
55
void
MaxCol(
const
DenseMatrix &mat,
double
*vec,
bool
include_vec_elements);
56
57
/*!
58
* @brief Computes a column vector containing the minimum element for each row
59
* @param mat The matrix
60
* @param vec[out] The vector where we store the result
61
* @param include_vec_elements True if we consider vec as an additional column
62
* of the matrix, False otherwise.
63
*/
64
void
MinCol(
const
DenseMatrix &mat,
double
*vec,
bool
include_vec_elements);
65
66
/*!
67
* @brief Returns the maximum number of vertices in a face.
68
* @param type The element type of the face.
69
* @return The number of vertices.
70
*/
71
int
MaxVertsXFace(
const
int
type);
72
73
/*!
74
* @brief Computes the sum of the matrix entries.
75
* @param mat The matrix.
76
* @return The sum of the elements of the matrix.
77
*/
78
double
Sum(
const
DenseMatrix &mat);
79
}
// namespace internal
80
81
}
// namespace mfem
82
83
#endif
// MFEM_USE_MOONOLITH
84
#endif
// MFEM_L2P_MESH_UTILS_HPP
config.hpp
fem.hpp
hexahedron.hpp
mfem
Definition
CodeDocumentation.dox:1
quadrilateral.hpp
Generated on Thu Dec 11 2025 11:52:54 for MFEM by
1.11.0