mathjs
mathjs copied to clipboard
cot reports wrong value for (0, 0)
b = math.complex(0,0)
then b.cot()
reports (NaN, NaN) as compared to Mathematica's ComplexInfinity. Not that the correct answere is always useful, but it (the NaN answer) did cause a problem in testing extended precision complex functions.
I can't remember exact what the status is but mathjs definitely has some issues regarding complex infinite values. You are definitely right that the current behaviour is not ideal.
refs: #804
Thanks for reporting.
@infusion what do you think about this edge case?