How can I make N/0 be equal to N/0?

Since dividing by 0 is mathematically undefined, and therefore not allowed, surely the solution is to trap the fact that division by 0 is imminent and provide the user with some kind of warning?

I seem to recall (some?) floating point standards defining a NaN (not a number) representation for any math operations causing by an undefined results?