Remix.run Logo
guccihat 4 days ago

Cool demo. A minor nitpick is that the code (and the article) forgets to handle the special case of a point inside the cube that happens to be exactly (0,0,0). This will result in a divide by zero when the vector is normalized.

NoahZuniga 4 days ago | parent | next [-]

The chance of this happening is less than 1 in 2^128. This will never happen.

pavel_lishin 3 days ago | parent | next [-]

Unless you're demoing it to someone very important, in which case it'll happen twice in a row.

rkomorn 5 hours ago | parent [-]

Especially if you have already had the conversation with anyone and confidently stated that, yes, the possibility exists but it's so remote that it's just not worth addressing.

cluckindan 5 hours ago | parent | prev [-]

With long enough timescales, every event with a non-zero probability will eventually happen.

pavel_lishin 3 days ago | parent | prev [-]

That nitpick is both minor, and absolutely correct!