Intrepid2
|
Utility methods for Intrepid2 unit tests. More...
#include "Kokkos_Core.hpp"
#include "Kokkos_DynRankView.hpp"
#include "Intrepid2_Basis.hpp"
#include "Intrepid2_DerivedBasisFamily.hpp"
#include "Intrepid2_HierarchicalBasisFamily.hpp"
#include "Intrepid2_Sacado.hpp"
#include "Intrepid2_Utils.hpp"
#include "Teuchos_UnitTestHarness.hpp"
Go to the source code of this file.
Macros | |
#define | INTREPID2_OUTPUTSCALAR_POINTSCALAR_TEST_INSTANT(GROUP_NAME, TEST_NAME) |
Typedefs | |
template<typename ScalarType > | |
using | ViewType = Kokkos::DynRankView< ScalarType, Kokkos::DefaultExecutionSpace > |
Functions | |
template<typename ScalarType > | |
bool | valuesAreSmall (ScalarType a, ScalarType b, double epsilon) |
bool | approximatelyEqual (double a, double b, double epsilon) |
bool | essentiallyEqual (double a, double b, double epsilon) |
KOKKOS_INLINE_FUNCTION double | fromZeroOne (double x_zero_one) |
KOKKOS_INLINE_FUNCTION double | toZeroOne (double x_minus_one_one) |
KOKKOS_INLINE_FUNCTION double | fromZeroOne_dx (double dx_zero_one) |
KOKKOS_INLINE_FUNCTION double | toZeroOne_dx (double dx_minus_one_one) |
template<class DeviceViewType > | |
DeviceViewType::HostMirror | getHostCopy (const DeviceViewType &deviceView) |
template<class BasisFamily > | |
Teuchos::RCP< Intrepid2::Basis < Kokkos::DefaultExecutionSpace, double, double > > | getBasisUsingFamily (shards::CellTopology cellTopo, Intrepid2::EFunctionSpace fs, int polyOrder_x, int polyOrder_y=-1, int polyOrder_z=-1) |
template<bool defineVertexFunctions> | |
Teuchos::RCP< Intrepid2::Basis < Kokkos::DefaultExecutionSpace, double, double > > | getHierarchicalBasis (shards::CellTopology cellTopo, Intrepid2::EFunctionSpace fs, int polyOrder_x, int polyOrder_y=-1, int polyOrder_z=-1) |
template<typename ValueType , class... DimArgs> | |
ViewType< ValueType > | getView (const std::string &label, DimArgs...dims) |
template<typename PointValueType > | |
ViewType< PointValueType > | lineInputPointsView (int numPoints) |
Returns a View containing equispaced points on the line. More... | |
template<typename PointValueType > | |
ViewType< PointValueType > | hexInputPointsView (int numPoints_1D) |
Returns a View containing equispaced points on the hexahedron. More... | |
template<typename PointValueType > | |
ViewType< PointValueType > | quadInputPointsView (int numPoints_1D) |
Returns a View containing equispaced points on the quadrilateral. More... | |
template<typename PointValueType > | |
ViewType< PointValueType > | tetInputPointsView (int numPointsBase) |
Returns a View containing regularly-spaced points on the tetrahedron. More... | |
template<typename PointValueType > | |
ViewType< PointValueType > | triInputPointsView (int numPointsBase) |
Returns a View containing regularly-spaced points on the triangle. More... | |
template<typename PointValueType > | |
ViewType< PointValueType > | getInputPointsView (shards::CellTopology &cellTopo, int numPoints_1D) |
template<typename OutputValueType > | |
ViewType< OutputValueType > | getOutputView (Intrepid2::EFunctionSpace fs, Intrepid2::EOperator op, int basisCardinality, int numPoints, int spaceDim) |
std::vector< std::vector< int > > | getBasisTestCasesUpToDegree (int spaceDim, int minDegree, int polyOrder_x, int polyOrder_y=-1, int polyOrder_z=-1) |
template<class ViewType > | |
void | testViewFloatingEquality (ViewType &view1, ViewType &view2, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View 1", std::string view2Name="View 2") |
Variables | |
static const double | TEST_TOLERANCE_TIGHT = 1.e2 * std::numeric_limits<double>::epsilon() |
Utility methods for Intrepid2 unit tests.
Definition in file Intrepid2_TestUtils.hpp.
#define INTREPID2_OUTPUTSCALAR_POINTSCALAR_TEST_INSTANT | ( | GROUP_NAME, | |
TEST_NAME | |||
) |
Definition at line 550 of file Intrepid2_TestUtils.hpp.
|
inline |
Returns a View containing equispaced points on the hexahedron.
[in] | numPointsBase | - the number of points that will be defined along each edge. |
The total number of points defined will be a cubic number; if n=numPointsBase, then the point count is n^3.
Definition at line 213 of file Intrepid2_TestUtils.hpp.
|
inline |
Returns a View containing equispaced points on the line.
[in] | numPointsBase | - the number of points that will be defined along each edge. |
Definition at line 196 of file Intrepid2_TestUtils.hpp.
|
inline |
Returns a View containing equispaced points on the quadrilateral.
[in] | numPointsBase | - the number of points that will be defined along each edge. |
The total number of points defined will be a square number; if n=numPointsBase, then the point count is n^2.
Definition at line 241 of file Intrepid2_TestUtils.hpp.
|
inline |
Returns a View containing regularly-spaced points on the tetrahedron.
[in] | numPointsBase | - the number of points that will be defined along each edge. |
The total number of points defined will be a tetrahedral number; if n=numPointsBase, then the point count is the nth tetrahedral number, given by n*(n+1)*(n+2)/6.
Definition at line 265 of file Intrepid2_TestUtils.hpp.
|
inline |
Returns a View containing regularly-spaced points on the triangle.
[in] | numPointsBase | - the number of points that will be defined along each edge. |
The total number of points defined will be a triangular number; if n=numPointsBase, then the point count is the nth triangular number, given by n*(n+1)/2.
Definition at line 310 of file Intrepid2_TestUtils.hpp.