MAIA bb96820c
Multiphysics at AIA
Loading...
Searching...
No Matches
geometryelement.h
Go to the documentation of this file.
1// Copyright (C) 2024 The m-AIA AUTHORS
2//
3// This file is part of m-AIA (https://git.rwth-aachen.de/aia/m-AIA/m-AIA)
4//
5// SPDX-License-Identifier: LGPL-3.0-only
6
7#ifndef GEOMETRYELEMENT_H
8#define GEOMETRYELEMENT_H
9
16#include "INCLUDE/maiamacro.h"
17#include "INCLUDE/maiatypes.h"
18
19template <MInt nDim>
21 public:
27 // Lower nDim values hold minimum
28 // Upper nDim values hold maximu
30
31 public:
32 void boundingBox();
33 void writeElement() const;
34 void calcNormal(const MFloat* const vertices, MFloat* normal) const;
35 void calcCentroid(const MFloat* const vertices, MFloat* centroid) const;
36 void getVertices(MFloat* vertices) const;
37 void allocateElements(void*, void*, MInt&);
38 static void init(MInt NotUsed(dimensions), MInt /*noDistributions*/, MInt /*maxSize*/){
39 // TRACE();
40 };
41
42 static MInt staticElementSize() { return (nDim + 3) * nDim * sizeof(MFloat) + sizeof(MFloat*) * nDim; }
43};
44
45#endif
void calcNormal(const MFloat *const vertices, MFloat *normal) const
Calculates the normal vector from the geometry element vertices.
void allocateElements(void *, void *, MInt &)
static MInt staticElementSize()
void writeElement() const
void calcCentroid(const MFloat *const vertices, MFloat *centroid) const
Calculate the centroid of the geometry element vertices.
MFloat ** m_vertices
void getVertices(MFloat *vertices) const
Return the vertices of the geometry element.
static void init(MInt NotUsed(dimensions), MInt, MInt)
int32_t MInt
Definition: maiatypes.h:62
double MFloat
Definition: maiatypes.h:52