Test: absolute tolerance for vectors

See the documentation, eg ?isapprox in the REPL. In particular,

x and y may also be arrays of numbers, in which case norm defaults to the usual
norm function in LinearAlgebra, but may be changed by passing a norm::Function keyword argument. (For numbers, norm is the same thing as abs.) When x and y are arrays, if norm(x-y) is not finite (i.e. ±Inf or NaN), the comparison falls back to checking whether all elements of x and y are approximately equal component-wise.

1 Like