aeq

Functions

int main(int argc, char *argv[])

aeq [ option ] exfile [ infile ]

  • -t double

    • absolute tolerance (0ϵ)

  • -e int

    • error type

      • 0 absolute error

      • 1 relative error

  • -L

    • disable to check length

  • exfile str

    • double-type expected values

  • infile str

    • double-type actual values

  • stdout

    • result messages

This command checks whether two data sequences are almost equal or not.

Given the two data sequences

x1(0),x1(1),,x1(T1),x2(0),x2(1),,x2(T2),
the absolute error e(t) is calculated sample-by-sample:
e(t)=|x1(t)x2(t)|.
If e(t) is greater than tolerance ϵ or T1 is not equal to T2, the command prints a warning message.

The below example checks the equality between two data:

aeq -t 0 data.x1 data.x2
Parameters:
  • argc[in] Number of arguments.

  • argv[in] Argument vector.

Return values:
  • -1 – Given two data sequences are not almost equal.

  • 0 – Given two data sequences are almost equal.

  • 1 – Failed to run this command.