Unexpected NANs in complex arithmetic

Steven D'Aprano steve+comp.lang.python at pearwood.info
Wed Jun 22 02:17:16 EDT 2016


On Wednesday 22 June 2016 13:54, Dan Sommers wrote:

> By the time Python returns a result for inf+3j, you're already in
> trouble (or perhaps Python is already in trouble).

I don't see why. It is possible to do perfectly sensible arithmetic on INFs.


> A complex number has
> a real part and an imaginary part, and inf isn't real (i.e., it's not an
> element of ℝ).

That's okay, because floats are not the set ℝ.


-- 
Steve




More information about the Python-list mailing list