Fixed incorrect sign in refraction