logoalt Hacker News

sigmoid10today at 10:21 AM1 replyview on HN

The point is that the case T=0 doesn't just "exist" as a special code branch - it is still well defined mathematically without any change to the output function. What the above comment refers to with the extra "if" check is just a limitation of computers not liking to divide anything by zero, even if the actual function exists and is well behaved at zero. It is not some weird or special theoretical construction.


Replies

StilesCrisistoday at 12:42 PM

Floating point defines n/0 the same as math. It's infinity as long as n isn't zero.

show 2 replies