use the vectorized loops for reciprocal too
ignore invalid value errors when testing nans