Subject: | Inconsistent behaviour in many functions |
In general, when the input to a function is a Math::Complex object, the output
is also a Math::Complex object, but the are some odd exceptions. I consider
this inconsistent behaviour to be a bug.
The following cases return a Perl scalar, not a Math::Complex object:
$x = Math::Complex->new(0); $z = asin($x);
$x = Math::Complex->new(1); $z = acos($x);
$x = Math::Complex->new(0); $z = atan($x);
$x = Math::Complex->new(-100); $z = tanh($x);
$x = Math::Complex->new(100); $z = tanh($x);
$x = Math::Complex->new(1); $z = acosh($x);