#include "Sacado_No_Kokkos.hpp"
#include "Sacado_Random.hpp"
#include "Fad/fad.h"
#include <cppunit/extensions/HelperMacros.h>
Go to the source code of this file.
#define COMPARE_VALUES |
( |
|
a, |
|
|
|
b |
|
) |
| CPPUNIT_ASSERT( std::abs(a-b) < this->tol_a + this->tol_r*std::abs(a) ); |
#define COMPARE_FADS |
( |
|
a, |
|
|
|
b |
|
) |
| |
Value:CPPUNIT_ASSERT(
a.size() == b.size()); \
CPPUNIT_ASSERT(
a.hasFastAccess() == b.hasFastAccess());
\
for (
int zz=0; zz<
a.size(); zz++) {
\
} \
;
#define COMPARE_VALUES(a, b)
Definition at line 46 of file NestedFadUnitTests.hpp.
#define COMPARE_NESTED_FADS |
( |
|
a, |
|
|
|
b |
|
) |
| |
Value:CPPUNIT_ASSERT(
a.size() == b.size()); \
CPPUNIT_ASSERT(
a.hasFastAccess() == b.hasFastAccess());
\
for (
int z=0; z<
a.size(); z++) {
\
} \
;
#define COMPARE_FADS(a, b)
Definition at line 56 of file NestedFadUnitTests.hpp.
#define BINARY_OP_TEST |
( |
|
TESTNAME, |
|
|
|
OP |
|
) |
| |
Value:void TESTNAME () { \
c_dfad = a_dfad OP b_dfad; \
c_fad = a_fad OP b_fad;
\
\
double
val = urand.number(); \
c_dfad = a_dfad OP
val; \
\
c_dfad = val OP b_dfad; \
}
Sacado::Fad::DFad< double > FadType
#define COMPARE_NESTED_FADS(a, b)
Definition at line 66 of file NestedFadUnitTests.hpp.
#define RELOP_TEST |
( |
|
TESTNAME, |
|
|
|
OP |
|
) |
| |
Value:void TESTNAME () { \
bool r1 = a_dfad OP b_dfad; \
bool r2 = a_fad OP b_fad; \
CPPUNIT_ASSERT(r1 == r2); \
\
double
val = urand.number(); \
CPPUNIT_ASSERT(r1 == r2); \
\
r1 = val OP b_dfad; \
CPPUNIT_ASSERT(r1 == r2); \
}
Sacado::Fad::DFad< double > FadType
Definition at line 82 of file NestedFadUnitTests.hpp.
#define BINARY_FUNC_TEST |
( |
|
TESTNAME, |
|
|
|
FUNC |
|
) |
| |
Value:void TESTNAME () { \
c_dfad = FUNC (a_dfad,b_dfad); \
c_fad = FUNC (a_fad,b_fad);
\
\
double
val = urand.number(); \
c_dfad = FUNC (a_dfad,val); \
\
c_dfad = FUNC (val,b_dfad); \
}
Sacado::Fad::DFad< double > FadType
#define COMPARE_NESTED_FADS(a, b)
Definition at line 98 of file NestedFadUnitTests.hpp.
#define UNARY_OP_TEST |
( |
|
TESTNAME, |
|
|
|
OP |
|
) |
| |
Value:void TESTNAME () { \
c_dfad = OP a_dfad; \
}
#define COMPARE_NESTED_FADS(a, b)
Definition at line 114 of file NestedFadUnitTests.hpp.
#define UNARY_FUNC_TEST |
( |
|
TESTNAME, |
|
|
|
FUNC |
|
) |
| |
Value:void TESTNAME () { \
c_dfad = FUNC (a_dfad); \
}
#define COMPARE_NESTED_FADS(a, b)
Definition at line 121 of file NestedFadUnitTests.hpp.
#define UNARY_ASSIGNOP_TEST |
( |
|
TESTNAME, |
|
|
|
OP |
|
) |
| |
Value:void TESTNAME () { \
c_dfad OP a_dfad; \
\
double
val = urand.number(); \
}
Sacado::Fad::DFad< double > FadType
#define COMPARE_NESTED_FADS(a, b)
Definition at line 128 of file NestedFadUnitTests.hpp.