MOAB: Mesh Oriented datABase  (version 5.2.1)
TerminationCriterionTest.cpp File Reference
#include "Mesquite.hpp"
#include "MsqError.hpp"
#include "Vector3D.hpp"
#include "OFEvaluator.hpp"
#include "ObjectiveFunction.hpp"
#include "PatchData.hpp"
#include "TerminationCriterion.hpp"
#include "VertexMover.hpp"
#include "VertexPatches.hpp"
#include "UnitUtil.hpp"
#include "PatchDataInstances.hpp"
#include "ArrayMesh.hpp"
#include "MeshUtil.hpp"
#include "SimpleStats.hpp"
#include "InstructionQueue.hpp"
#include <iostream>
#include <algorithm>
#include <vector>
#include <set>
+ Include dependency graph for TerminationCriterionTest.cpp:

Go to the source code of this file.

Classes

class  DummyOF
class  TerminationCriterionTest
class  TCTFauxOptimizer

Functions

 CPPUNIT_TEST_SUITE_NAMED_REGISTRATION (TerminationCriterionTest,"TerminationCriterionTest")
 CPPUNIT_TEST_SUITE_NAMED_REGISTRATION (TerminationCriterionTest,"Unit")
static double lenfunc (const Vector3D *vect, int len)
static double maxfunc (const Vector3D *vect, int len)
static bool limit_absolute_quality (double, double, double curr_value, double epsilon)
static bool limit_relative_quality (double init_value, double, double curr_value, double epsilon)
static bool limit_absolute_sucessive (double, double prev_value, double curr_value, double epsilon)
static bool limit_relative_sucessive (double init_value, double prev_value, double curr_value, double epsilon)

Detailed Description

Author:
kraftche@cae.wisc.edu

Tests for the TerminationCriterion class..

Definition in file TerminationCriterionTest.cpp.


Function Documentation

CPPUNIT_TEST_SUITE_NAMED_REGISTRATION ( TerminationCriterionTest  ,
"TerminationCriterionTest"   
)
static double lenfunc ( const Vector3D vect,
int  len 
) [static]

Definition at line 441 of file TerminationCriterionTest.cpp.

References MBMesquite::length().

Referenced by TerminationCriterionTest::test_gradient_common().

{
    return MBMesquite::length( vect, len );
}
static bool limit_absolute_quality ( double  ,
double  ,
double  curr_value,
double  epsilon 
) [static]

Definition at line 508 of file TerminationCriterionTest.cpp.

References epsilon.

Referenced by TerminationCriterionTest::test_quality_common().

{
    return curr_value <= epsilon;
}
static bool limit_absolute_sucessive ( double  ,
double  prev_value,
double  curr_value,
double  epsilon 
) [static]

Definition at line 516 of file TerminationCriterionTest.cpp.

References epsilon.

Referenced by TerminationCriterionTest::test_quality_common().

{
    return ( prev_value - curr_value ) <= epsilon;
}
static bool limit_relative_quality ( double  init_value,
double  ,
double  curr_value,
double  epsilon 
) [static]

Definition at line 512 of file TerminationCriterionTest.cpp.

Referenced by TerminationCriterionTest::test_quality_common().

{
    return curr_value <= epsilon * init_value;
}
static bool limit_relative_sucessive ( double  init_value,
double  prev_value,
double  curr_value,
double  epsilon 
) [static]

Definition at line 520 of file TerminationCriterionTest.cpp.

Referenced by TerminationCriterionTest::test_quality_common().

{
    return ( prev_value - curr_value ) <= epsilon * ( init_value - curr_value );
}
static double maxfunc ( const Vector3D vect,
int  len 
) [static]

Definition at line 445 of file TerminationCriterionTest.cpp.

References MBMesquite::Linf().

Referenced by TerminationCriterionTest::test_gradient_common().

{
    return MBMesquite::Linf( vect, len );
}
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines