| IGLib 1.4 The IGLib base library for development of numerical, technical and business applications.

- Main Page
- Namespaces
- Classes
- Files
- Directories

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Protected Attributes | Properties | Private Attributes

# IG::Num::AnalysisComparer Class Reference

Compares two sets of analysis results in various different ways. More...

Collaboration diagram for IG::Num::AnalysisComparer:
[legend]

List of all members.

## Public Member Functions
| AnalysisComparer ()
| AnalysisComparer (double barrierLength, double barrierHeight)
| Creates analysis results comparer with initialized penalty evaluator containing one penalty function (common for all constraints) initialized to the default penalty function with specified characteristic barrier length and height.
| AnalysisComparer (double barrierLength, double barrierHeight, double maxZero)
| Creates analysis results comparer with initialized penalty evaluator with penalty function (common for all constraints) initialized to the default penalty function with specified characteristic barrier length and height and transition point where penalty function becomes non-zero.
int | Compare (IAnalysisResults an1, IAnalysisResults an2)
  | Compares two sets of analysis results points.</summary Parameters:
  an1 | First set of analysis results.
  an2 | Second set of analysis results.
Returns: 0 if result sets are equal, -1 if the first set is smaller than the second, and 1 if the first set is larger than the second.
## Protected Attributes
double | _equalityConstraintTolerance
bool | _cmpNumViolated = false
bool | _cmpMaxResidual = false
bool | _cmpSumResiduals = true
bool | _cmpMaxPenalty = false
bool | _cmpSumPenalties = false
bool | _cmpObjectiveFunction = true
## Properties
double | EqualityConstraintTolerance`[get, set]`
| Gets or sets tolerance for equality constraints. When absolute value of a constraint function is below this tolerance, the corresponding constraint is not considered violated. Tolerance must not be negative.
IPenaltyEvaluator | PenaltyEvaluator`[get, set]`
| Gets or sets evaluator of penalty terms. This is needed when e.g. sums of penalty terms are defined.
bool | CompareNumViolated`[get, set]`
| Whether number of violated constraints is compared.
bool | CompareMaxResidual`[get, set]`
| Whether maximal constraint residual is compared.
bool | CompareSumResiduals`[get, set]`
| Whether sum of constraint residuals is compared.
bool | CompareMaxPenalty`[get, set]`
| Whether maximal penalty term is compared.
bool | CompareSumPenalties`[get, set]`
| Whether sum of penalty terms is compared.
bool | CompareObjectiveFunction`[get, set]`
| Whether value of the objective function is compared.
## Private Attributes
IPenaltyEvaluator | _penaltyEvaluator = null

## Detailed Description

Compares two sets of analysis results in various different ways.

## Constructor & Destructor Documentation

IG::Num::AnalysisComparer::AnalysisComparer | ( |  | ) | `[inline]`

IG::Num::AnalysisComparer::AnalysisComparer | ( | double | barrierLength,
|  | double | barrierHeight
| ) |  | `[inline]`

Creates analysis results comparer with initialized penalty evaluator containing one penalty function (common for all constraints) initialized to the default penalty function with specified characteristic barrier length and height.

Parameters:

  barrierLength | Characteristic barrrier length. Within this length the created penalty function grows approximately from 0 to characteristic height.
  barrierHeight | Characteristic barrier height.

IG::Num::AnalysisComparer::AnalysisComparer | ( | double | barrierLength,
|  | double | barrierHeight,
|  | double | maxZero
| ) |  | `[inline]`

Creates analysis results comparer with initialized penalty evaluator with penalty function (common for all constraints) initialized to the default penalty function with specified characteristic barrier length and height and transition point where penalty function becomes non-zero.

Parameters:

  barrierLength | Characteristic barrrier length. Within this length the created penalty function grows approximately from 0 to characteristic height.
  barrierHeight | Characteristic barrier height.
  zeroEnd | Maximal argument for which the created function is 0.

## Member Function Documentation

int IG::Num::AnalysisComparer::Compare | ( | IAnalysisResults | an1,
|  | IAnalysisResults | an2
| ) |  | `[inline]`

Compares two sets of analysis results points.</summary

Parameters:

  an1 | First set of analysis results.
  an2 | Second set of analysis results.

Returns:
  0 if result sets are equal, -1 if the first set is smaller than the second, and 1 if the first set is larger than the second.

## Member Data Documentation

double IG::Num::AnalysisComparer::_equalityConstraintTolerance`[protected]`

IPenaltyEvaluator IG::Num::AnalysisComparer::_penaltyEvaluator = null`[private]`

bool IG::Num::AnalysisComparer::_cmpNumViolated = false`[protected]`

bool IG::Num::AnalysisComparer::_cmpMaxResidual = false`[protected]`

bool IG::Num::AnalysisComparer::_cmpSumResiduals = true`[protected]`

bool IG::Num::AnalysisComparer::_cmpMaxPenalty = false`[protected]`

bool IG::Num::AnalysisComparer::_cmpSumPenalties = false`[protected]`

bool IG::Num::AnalysisComparer::_cmpObjectiveFunction = true`[protected]`

## Property Documentation

double IG::Num::AnalysisComparer::EqualityConstraintTolerance`[get, set]`

Gets or sets tolerance for equality constraints. When absolute value of a constraint function is below this tolerance, the corresponding constraint is not considered violated. Tolerance must not be negative.

IPenaltyEvaluator IG::Num::AnalysisComparer::PenaltyEvaluator`[get, set, private]`

Gets or sets evaluator of penalty terms. This is needed when e.g. sums of penalty terms are defined.

bool IG::Num::AnalysisComparer::CompareNumViolated`[get, set]`

Whether number of violated constraints is compared.

bool IG::Num::AnalysisComparer::CompareMaxResidual`[get, set]`

Whether maximal constraint residual is compared.

bool IG::Num::AnalysisComparer::CompareSumResiduals`[get, set]`

Whether sum of constraint residuals is compared.

bool IG::Num::AnalysisComparer::CompareMaxPenalty`[get, set]`

Whether maximal penalty term is compared.

bool IG::Num::AnalysisComparer::CompareSumPenalties`[get, set]`

Whether sum of penalty terms is compared.

bool IG::Num::AnalysisComparer::CompareObjectiveFunction`[get, set]`

Whether value of the objective function is compared.

The documentation for this class was generated from the following file:

- AnalysisComparer.cs

All Classes Namespaces Files Functions Variables Enumerations Properties Events