MOAB: Mesh Oriented datABase  (version 5.3.0)
ObjectiveFunctionTests.cpp File Reference
+ Include dependency graph for ObjectiveFunctionTests.cpp:

Go to the source code of this file.

Classes

class  OFTestBadQM

Defines

#define CHECK_EQUAL_MATRICES(A, B)   CPPUNIT_ASSERT_MATRICES_EQUAL( ( A ), ( B ), MAT_EPS( A ) )

Functions

static bool init_pd (PatchData &pd)
double MAT_EPS (const Matrix3D &A)

Variables

const size_t HANDLE_VAL = 0xDEADBEEF

Detailed Description

Author:
Jason Kraftcheck

Definition in file ObjectiveFunctionTests.cpp.


Define Documentation

#define CHECK_EQUAL_MATRICES (   A,
 
)    CPPUNIT_ASSERT_MATRICES_EQUAL( ( A ), ( B ), MAT_EPS( A ) )

Function Documentation

static bool init_pd ( PatchData pd) [static]

get a patchdata to use for testing

Definition at line 43 of file ObjectiveFunctionTests.cpp.

References MBMesquite::PatchData::fill(), fixed, and MBMesquite::TRIANGLE.

Referenced by ObjectiveFunctionTests::patch().

{
    MsqError err;
    const double coords[]  = { 0, 0, 0, 1, 1, 1, 2, 2, 2 };
    const bool fixed[]     = { false, true, true };
    const size_t indices[] = { 0, 1, 2 };
    pd.fill( 3, coords, 1, TRIANGLE, indices, fixed, err );
    return !err;
}
double MAT_EPS ( const Matrix3D A)

Definition at line 504 of file ObjectiveFunctionTests.cpp.

References MBMesquite::Frobenius_2().

{
    return std::max( 0.001 * sqrt( Frobenius_2( A ) ), 0.001 );
}

Variable Documentation

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines