Intrepid2
Macros | Typedefs | Functions | Variables
Intrepid2_TestUtils.hpp File Reference

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_FunctorIterator.hpp"
#include "Intrepid2_HierarchicalBasisFamily.hpp"
#include "Intrepid2_PointTools.hpp"
#include "Intrepid2_Sacado.hpp"
#include "Intrepid2_Utils.hpp"
#include "Teuchos_UnitTestHarness.hpp"

Go to the source code of this file.

Macros

#define INTREPID2_POINTSCALAR_TEST_INSTANT(GROUP_NAME, TEST_NAME)
 
#define INTREPID2_OUTPUTSCALAR_POINTSCALAR_TEST_INSTANT(GROUP_NAME, TEST_NAME)
 

Typedefs

using Intrepid2::DefaultTestDeviceType = typename Kokkos::DefaultExecutionSpace::device_type
 Default Kokkos::Device to use for tests; depends on platform.
 
template<typename ScalarType , typename DeviceType >
using Intrepid2::ViewType = Kokkos::DynRankView< ScalarType, DeviceType >
 
template<typename ScalarType , typename DeviceType >
using Intrepid2::FixedRankViewType = Kokkos::View< ScalarType, DeviceType >
 

Functions

template<class Scalar >
const Teuchos::ScalarTraits< Scalar >::magnitudeType Intrepid2::smallNumber ()
 Use Teuchos small number determination on host; pass this to Intrepid2::relErr() on device.
 
template<class Scalar1 , class Scalar2 >
KOKKOS_INLINE_FUNCTION bool Intrepid2::relErrMeetsTol (const Scalar1 &s1, const Scalar2 &s2, const typename Teuchos::ScalarTraits< typename std::common_type< Scalar1, Scalar2 >::type >::magnitudeType &smallNumber, const double &tol)
 Adapted from Teuchos::relErr(); for use in code that may be executed on device.
 
template<class Scalar1 , class Scalar2 >
KOKKOS_INLINE_FUNCTION bool Intrepid2::errMeetsAbsAndRelTol (const Scalar1 &s1, const Scalar2 &s2, const double &relTol, const double &absTol)
 
template<typename ScalarType >
KOKKOS_INLINE_FUNCTION bool Intrepid2::valuesAreSmall (const ScalarType &a, const ScalarType &b, const double &epsilon)
 
bool Intrepid2::approximatelyEqual (double a, double b, double epsilon)
 
bool Intrepid2::essentiallyEqual (double a, double b, double epsilon)
 
KOKKOS_INLINE_FUNCTION double Intrepid2::fromZeroOne (double x_zero_one)
 
KOKKOS_INLINE_FUNCTION double Intrepid2::toZeroOne (double x_minus_one_one)
 
KOKKOS_INLINE_FUNCTION double Intrepid2::fromZeroOne_dx (double dx_zero_one)
 
KOKKOS_INLINE_FUNCTION double Intrepid2::toZeroOne_dx (double dx_minus_one_one)
 
template<class DeviceViewType >
DeviceViewType::HostMirror Intrepid2::getHostCopy (const DeviceViewType &deviceView)
 
template<class BasisFamily >
Teuchos::RCP< Intrepid2::Basis< DefaultTestDeviceType, double, double > > Intrepid2::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< DefaultTestDeviceType, double, double > > Intrepid2::getHierarchicalBasis (shards::CellTopology cellTopo, Intrepid2::EFunctionSpace fs, int polyOrder_x, int polyOrder_y=-1, int polyOrder_z=-1)
 
template<typename ValueType , typename DeviceType , class ... DimArgs>
ViewType< ValueType, DeviceType > Intrepid2::getView (const std::string &label, DimArgs... dims)
 
template<typename ValueType , class ... DimArgs>
FixedRankViewType< typename RankExpander< ValueType, sizeof...(DimArgs) >::value_type, DefaultTestDeviceType > Intrepid2::getFixedRankView (const std::string &label, DimArgs... dims)
 
template<typename PointValueType , typename DeviceType >
ViewType< PointValueType, DeviceType > Intrepid2::getInputPointsView (shards::CellTopology &cellTopo, int numPoints_1D)
 Returns a DynRankView containing regularly-spaced points on the specified cell topology.
 
template<typename OutputValueType , typename DeviceType >
ViewType< OutputValueType, DeviceType > Intrepid2::getOutputView (Intrepid2::EFunctionSpace fs, Intrepid2::EOperator op, int basisCardinality, int numPoints, int spaceDim)
 
std::vector< std::vector< int > > Intrepid2::getBasisTestCasesUpToDegree (int spaceDim, int minDegree, int polyOrder_x, int polyOrder_y=-1, int polyOrder_z=-1)
 
template<class Functor , class Scalar , int rank>
ViewType< Scalar, DefaultTestDeviceType >::HostMirror Intrepid2::copyFunctorToHostView (const Functor &deviceFunctor)
 Copy the values for the specified functor.
 
template<class FunctorType , typename Scalar , int rank>
void Intrepid2::printFunctor (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor1 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor2 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor3 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor4 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor5 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor6 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class FunctorType >
void Intrepid2::printFunctor7 (const FunctorType &functor, std::ostream &out, const std::string &functorName="")
 
template<class View >
void Intrepid2::printView (const View &view, std::ostream &out, const std::string &viewName="")
 
template<class FunctorType1 , class FunctorType2 , int rank, typename Scalar = typename FunctorType1::value_type, class ExecutionSpace = typename FunctorType1::execution_space>
std::enable_if<!(supports_rank< FunctorType1, rank >::value &&supports_rank< FunctorType2, rank >::value), void >::type Intrepid2::testFloatingEquality (const FunctorType1 &functor1, const FunctorType2 &functor2, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string functor1Name="Functor 1", std::string functor2Name="Functor 2")
 
template<class FunctorType1 , class FunctorType2 , int rank, typename Scalar = typename FunctorType1::value_type, class ExecutionSpace = typename FunctorType1::execution_space>
std::enable_if<(supports_rank< FunctorType1, rank >::value &&supports_rank< FunctorType2, rank >::value), void >::type Intrepid2::testFloatingEquality (const FunctorType1 &functor1, const FunctorType2 &functor2, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string functor1Name="Functor 1", std::string functor2Name="Functor 2")
 this method assumes both functors are accesible on device.
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality1 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality2 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality3 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality4 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality5 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality6 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality7 (const ViewType &view, const FunctorType &functor, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View", std::string view2Name="Functor")
 
template<class ViewType1 , class ViewType2 >
void Intrepid2::testViewFloatingEquality (const ViewType1 &view1, const ViewType2 &view2, double relTol, double absTol, Teuchos::FancyOStream &out, bool &success, std::string view1Name="View 1", std::string view2Name="View 2")
 

Variables

constexpr int Intrepid2::MAX_FAD_DERIVATIVES_FOR_TESTS = 3
 Maximum number of derivatives to track for Fad types in tests.
 
static const double Intrepid2::TEST_TOLERANCE_TIGHT = 1.e2 * std::numeric_limits<double>::epsilon()
 

Detailed Description

Utility methods for Intrepid2 unit tests.

Author
Created by N.V. Roberts.

Definition in file Intrepid2_TestUtils.hpp.

Macro Definition Documentation

◆ INTREPID2_OUTPUTSCALAR_POINTSCALAR_TEST_INSTANT

#define INTREPID2_OUTPUTSCALAR_POINTSCALAR_TEST_INSTANT (   GROUP_NAME,
  TEST_NAME 
)
Value:
\
TEUCHOS_UNIT_TEST_TEMPLATE_2_INSTANT( GROUP_NAME, TEST_NAME, double, double ) \

Definition at line 822 of file Intrepid2_TestUtils.hpp.

◆ INTREPID2_POINTSCALAR_TEST_INSTANT

#define INTREPID2_POINTSCALAR_TEST_INSTANT (   GROUP_NAME,
  TEST_NAME 
)
Value:
\
TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT( GROUP_NAME, TEST_NAME, double ) \

Definition at line 818 of file Intrepid2_TestUtils.hpp.

Typedef Documentation

◆ DefaultTestDeviceType

using Intrepid2::DefaultTestDeviceType = typedef typename Kokkos::DefaultExecutionSpace::device_type

Default Kokkos::Device to use for tests; depends on platform.

Definition at line 76 of file Intrepid2_TestUtils.hpp.

◆ FixedRankViewType

template<typename ScalarType , typename DeviceType >
using Intrepid2::FixedRankViewType = typedef Kokkos::View<ScalarType,DeviceType>

Definition at line 117 of file Intrepid2_TestUtils.hpp.

◆ ViewType

template<typename ScalarType , typename DeviceType >
using Intrepid2::ViewType = typedef Kokkos::DynRankView<ScalarType,DeviceType>

Definition at line 114 of file Intrepid2_TestUtils.hpp.

Function Documentation

◆ approximatelyEqual()

bool Intrepid2::approximatelyEqual ( double  a,
double  b,
double  epsilon 
)
inline

Definition at line 126 of file Intrepid2_TestUtils.hpp.

◆ copyFunctorToHostView()

template<class Functor , class Scalar , int rank>
ViewType< Scalar, DefaultTestDeviceType >::HostMirror Intrepid2::copyFunctorToHostView ( const Functor &  deviceFunctor)

Copy the values for the specified functor.

Definition at line 429 of file Intrepid2_TestUtils.hpp.

References Intrepid2::copyFunctorToHostView(), and Intrepid2::getFunctorRank().

Referenced by Intrepid2::copyFunctorToHostView().

◆ errMeetsAbsAndRelTol()

template<class Scalar1 , class Scalar2 >
KOKKOS_INLINE_FUNCTION bool Intrepid2::errMeetsAbsAndRelTol ( const Scalar1 &  s1,
const Scalar2 &  s2,
const double &  relTol,
const double &  absTol 
)

Definition at line 105 of file Intrepid2_TestUtils.hpp.

◆ essentiallyEqual()

bool Intrepid2::essentiallyEqual ( double  a,
double  b,
double  epsilon 
)
inline

Definition at line 132 of file Intrepid2_TestUtils.hpp.

◆ fromZeroOne()

KOKKOS_INLINE_FUNCTION double Intrepid2::fromZeroOne ( double  x_zero_one)

Definition at line 139 of file Intrepid2_TestUtils.hpp.

◆ fromZeroOne_dx()

KOKKOS_INLINE_FUNCTION double Intrepid2::fromZeroOne_dx ( double  dx_zero_one)

Definition at line 151 of file Intrepid2_TestUtils.hpp.

◆ getBasisTestCasesUpToDegree()

std::vector< std::vector< int > > Intrepid2::getBasisTestCasesUpToDegree ( int  spaceDim,
int  minDegree,
int  polyOrder_x,
int  polyOrder_y = -1,
int  polyOrder_z = -1 
)
inline

Definition at line 398 of file Intrepid2_TestUtils.hpp.

◆ getBasisUsingFamily()

template<class BasisFamily >
Teuchos::RCP< Intrepid2::Basis< DefaultTestDeviceType, double, double > > Intrepid2::getBasisUsingFamily ( shards::CellTopology  cellTopo,
Intrepid2::EFunctionSpace  fs,
int  polyOrder_x,
int  polyOrder_y = -1,
int  polyOrder_z = -1 
)
inline

Definition at line 171 of file Intrepid2_TestUtils.hpp.

◆ getFixedRankView()

template<typename ValueType , class ... DimArgs>
FixedRankViewType< typename RankExpander< ValueType, sizeof...(DimArgs) >::value_type, DefaultTestDeviceType > Intrepid2::getFixedRankView ( const std::string &  label,
DimArgs...  dims 
)
inline

Definition at line 248 of file Intrepid2_TestUtils.hpp.

◆ getHierarchicalBasis()

template<bool defineVertexFunctions>
Teuchos::RCP< Intrepid2::Basis< DefaultTestDeviceType, double, double > > Intrepid2::getHierarchicalBasis ( shards::CellTopology  cellTopo,
Intrepid2::EFunctionSpace  fs,
int  polyOrder_x,
int  polyOrder_y = -1,
int  polyOrder_z = -1 
)
inline

Definition at line 215 of file Intrepid2_TestUtils.hpp.

◆ getHostCopy()

template<class DeviceViewType >
DeviceViewType::HostMirror Intrepid2::getHostCopy ( const DeviceViewType &  deviceView)

Definition at line 163 of file Intrepid2_TestUtils.hpp.

◆ getInputPointsView()

template<typename PointValueType , typename DeviceType >
ViewType< PointValueType, DeviceType > Intrepid2::getInputPointsView ( shards::CellTopology &  cellTopo,
int  numPoints_1D 
)
inline

Returns a DynRankView containing regularly-spaced points on the specified cell topology.

Parameters
[in]cellTopo- the cell topology on which the points will be defined.
[in]numPoints_1D- 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 269 of file Intrepid2_TestUtils.hpp.

References Intrepid2::getInputPointsView(), Intrepid2::PointTools::getLattice(), and Intrepid2::PointTools::getLatticeSize().

Referenced by Intrepid2::getInputPointsView().

◆ getOutputView()

template<typename OutputValueType , typename DeviceType >
ViewType< OutputValueType, DeviceType > Intrepid2::getOutputView ( Intrepid2::EFunctionSpace  fs,
Intrepid2::EOperator  op,
int  basisCardinality,
int  numPoints,
int  spaceDim 
)
inline

Definition at line 322 of file Intrepid2_TestUtils.hpp.

◆ getView()

template<typename ValueType , typename DeviceType , class ... DimArgs>
ViewType< ValueType, DeviceType > Intrepid2::getView ( const std::string &  label,
DimArgs...  dims 
)
inline

Definition at line 233 of file Intrepid2_TestUtils.hpp.

◆ printFunctor()

template<class FunctorType , typename Scalar , int rank>
void Intrepid2::printFunctor ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 494 of file Intrepid2_TestUtils.hpp.

◆ printFunctor1()

template<class FunctorType >
void Intrepid2::printFunctor1 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 534 of file Intrepid2_TestUtils.hpp.

◆ printFunctor2()

template<class FunctorType >
void Intrepid2::printFunctor2 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 541 of file Intrepid2_TestUtils.hpp.

◆ printFunctor3()

template<class FunctorType >
void Intrepid2::printFunctor3 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 548 of file Intrepid2_TestUtils.hpp.

◆ printFunctor4()

template<class FunctorType >
void Intrepid2::printFunctor4 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 555 of file Intrepid2_TestUtils.hpp.

◆ printFunctor5()

template<class FunctorType >
void Intrepid2::printFunctor5 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 562 of file Intrepid2_TestUtils.hpp.

◆ printFunctor6()

template<class FunctorType >
void Intrepid2::printFunctor6 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 569 of file Intrepid2_TestUtils.hpp.

◆ printFunctor7()

template<class FunctorType >
void Intrepid2::printFunctor7 ( const FunctorType &  functor,
std::ostream &  out,
const std::string &  functorName = "" 
)

Definition at line 576 of file Intrepid2_TestUtils.hpp.

◆ printView()

template<class View >
void Intrepid2::printView ( const View &  view,
std::ostream &  out,
const std::string &  viewName = "" 
)

Definition at line 583 of file Intrepid2_TestUtils.hpp.

◆ relErrMeetsTol()

template<class Scalar1 , class Scalar2 >
KOKKOS_INLINE_FUNCTION bool Intrepid2::relErrMeetsTol ( const Scalar1 &  s1,
const Scalar2 &  s2,
const typename Teuchos::ScalarTraits< typename std::common_type< Scalar1, Scalar2 >::type >::magnitudeType &  smallNumber,
const double &  tol 
)

Adapted from Teuchos::relErr(); for use in code that may be executed on device.

Definition at line 92 of file Intrepid2_TestUtils.hpp.

References Intrepid2::relErrMeetsTol(), and Intrepid2::smallNumber().

Referenced by Intrepid2::relErrMeetsTol().

◆ smallNumber()

template<class Scalar >
const Teuchos::ScalarTraits< Scalar >::magnitudeType Intrepid2::smallNumber ( )

Use Teuchos small number determination on host; pass this to Intrepid2::relErr() on device.

Definition at line 82 of file Intrepid2_TestUtils.hpp.

References Intrepid2::smallNumber().

Referenced by Intrepid2::relErrMeetsTol(), and Intrepid2::smallNumber().

◆ testFloatingEquality() [1/2]

template<class FunctorType1 , class FunctorType2 , int rank, typename Scalar = typename FunctorType1::value_type, class ExecutionSpace = typename FunctorType1::execution_space>
std::enable_if<!(supports_rank< FunctorType1, rank >::value &&supports_rank< FunctorType2, rank >::value), void >::type Intrepid2::testFloatingEquality ( const FunctorType1 &  functor1,
const FunctorType2 &  functor2,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  functor1Name = "Functor 1",
std::string  functor2Name = "Functor 2" 
)

Definition at line 616 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality() [2/2]

template<class FunctorType1 , class FunctorType2 , int rank, typename Scalar = typename FunctorType1::value_type, class ExecutionSpace = typename FunctorType1::execution_space>
std::enable_if<(supports_rank< FunctorType1, rank >::value &&supports_rank< FunctorType2, rank >::value), void >::type Intrepid2::testFloatingEquality ( const FunctorType1 &  functor1,
const FunctorType2 &  functor2,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  functor1Name = "Functor 1",
std::string  functor2Name = "Functor 2" 
)

this method assumes both functors are accesible on device.

Definition at line 625 of file Intrepid2_TestUtils.hpp.

References Intrepid2::getFunctorRank().

◆ testFloatingEquality1()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality1 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 725 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality2()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality2 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 732 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality3()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality3 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 739 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality4()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality4 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 746 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality5()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality5 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 753 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality6()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality6 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 760 of file Intrepid2_TestUtils.hpp.

◆ testFloatingEquality7()

template<class ViewType , class FunctorType >
void Intrepid2::testFloatingEquality7 ( const ViewType &  view,
const FunctorType &  functor,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View",
std::string  view2Name = "Functor" 
)

Definition at line 767 of file Intrepid2_TestUtils.hpp.

◆ testViewFloatingEquality()

template<class ViewType1 , class ViewType2 >
void Intrepid2::testViewFloatingEquality ( const ViewType1 &  view1,
const ViewType2 &  view2,
double  relTol,
double  absTol,
Teuchos::FancyOStream &  out,
bool &  success,
std::string  view1Name = "View 1",
std::string  view2Name = "View 2" 
)

Definition at line 774 of file Intrepid2_TestUtils.hpp.

◆ toZeroOne()

KOKKOS_INLINE_FUNCTION double Intrepid2::toZeroOne ( double  x_minus_one_one)

Definition at line 145 of file Intrepid2_TestUtils.hpp.

◆ toZeroOne_dx()

KOKKOS_INLINE_FUNCTION double Intrepid2::toZeroOne_dx ( double  dx_minus_one_one)

Definition at line 157 of file Intrepid2_TestUtils.hpp.

◆ valuesAreSmall()

template<typename ScalarType >
KOKKOS_INLINE_FUNCTION bool Intrepid2::valuesAreSmall ( const ScalarType &  a,
const ScalarType &  b,
const double &  epsilon 
)

Definition at line 120 of file Intrepid2_TestUtils.hpp.

Variable Documentation

◆ MAX_FAD_DERIVATIVES_FOR_TESTS

constexpr int Intrepid2::MAX_FAD_DERIVATIVES_FOR_TESTS = 3
constexpr

Maximum number of derivatives to track for Fad types in tests.

Definition at line 68 of file Intrepid2_TestUtils.hpp.

◆ TEST_TOLERANCE_TIGHT

const double Intrepid2::TEST_TOLERANCE_TIGHT = 1.e2 * std::numeric_limits<double>::epsilon()
static

Definition at line 110 of file Intrepid2_TestUtils.hpp.