Go to: Synopsis. Return value. MEL examples.

Synopsis

int equivalent(float $a, float $b)

Compare 2 float values within the current linear tolerance value.

Return value

None

Arguments

Variable Name Variable Type Description
$afloatFirst value to compare
$bfloatValue to compare with

MEL examples

  tolerance -q -l;
  // Result : 0.001 //
  equivalent(0.0, 0.0005);
  // Result : 1 //
  equivalent(0.0, 0.005);
  // Result : 0 //