Skip to content

Instantly share code, notes, and snippets.

@glyphx
Created November 22, 2017 22:34
Show Gist options
  • Save glyphx/7f0ba10307326fbbd3ecbbca3143b014 to your computer and use it in GitHub Desktop.
Save glyphx/7f0ba10307326fbbd3ecbbca3143b014 to your computer and use it in GitHub Desktop.
t2 = +2.0 * (w * w + z * z) - 1
t2 = +1.0 if t2 > +1.0 else t2
t2 = -1.0 if t2 < -1.0 else t2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment