added NaN test for hypot and added missing using statement