Message314102
> By the same logic, if there's an infinite argument to hypot(), it doesn't matter what any other argument is - the result is +inf regardless.
Yep, that's what IEEE 754-2008 says for the two-argument case, so I think that's the logic that should be followed in the many-argument case: if any of the inputs is an infinity, the output should be infinity.
From section 9.2.1 of IEEE 754:
> For the hypot function, hypot(±0, ±0) is +0, hypot(± , qNaN) is + , and
> hypot(qNaN, ± ) is + . |
|
Date |
User |
Action |
Args |
2018-03-19 16:41:56 | mark.dickinson | set | recipients:
+ mark.dickinson, tim.peters, rhettinger, steven.daprano, skrah, serhiy.storchaka |
2018-03-19 16:41:56 | mark.dickinson | set | messageid: <1521477716.03.0.467229070634.issue33089@psf.upfronthosting.co.za> |
2018-03-19 16:41:56 | mark.dickinson | link | issue33089 messages |
2018-03-19 16:41:55 | mark.dickinson | create | |
|