Package pypower :: Package t :: Module t_is
[hide private]
[frames] | no frames]

Module t_is

source code

Tests if two matrices are identical to some tolerance.

Functions [hide private]
 
t_is(got, expected, prec=5, msg='')
Tests if two matrices are identical to some tolerance.
source code
Variables [hide private]
  __package__ = 'pypower.t'
Function Details [hide private]

t_is(got, expected, prec=5, msg='')

source code 

Tests if two matrices are identical to some tolerance.

Increments the global test count and if the maximum difference between corresponding elements of got and expected is less than 10**(-prec) then it increments the passed tests count, otherwise increments the failed tests count. Prints 'ok' or 'not ok' followed by the MSG, unless the global variable t_quiet is true. Intended to be called between calls to t_begin and t_end.

Authors:
Ray Zimmerman (PSERC Cornell), Richard Lincoln