News for hackers. Stuff that matters.
Re:Can 1/3 and 1/3 = 2/6? It seemed so by MaxBarraclough on Tuesday May 26, 2020 @10:21AM (#23311466)
A good example of this can be found in an incredible algorithm with a terrible name: Fast inverse square root.

It sounds like an algorithm for computing the inverse of the square root function, so one might think it's for squaring non-negative numbers, or something along those lines. Not so. It's for computing the reciprocal (the 'multiplicative inverse') of the square root of a number. [0]

Related to this: the way a superscript '2' next to a function means the function shall be applied twice (that is, composition with itself)... unless it's a trigonometric function, in which case it means the square of the result. [1] [2]

[0] https://en.wikipedia.org/wiki/Fast_inverse_square_root

[1] https://en.wikipedia.org/wiki/Function_composition#Functiona...

[2] https://en.wikipedia.org/wiki/List_of_trigonometric_identiti...

Re:Can 1/3 and 1/3 = 2/6? It seemed so by saagarjha on Tuesday May 26, 2020 @03:15PM (#23315285)
That one is clear to me, although it might be for a reason you find displeasing: if the thing being computed was an "inverse square root" in the sense of a functional inverse, then you'd be computing a square and it would make much more sense to call it that instead.