The System.Numerics.Complex type was introduced in .NET Framework 4.0. It was not originally implemented to be IEEE 754 compliant and deviates from the established standards that C and other languages specify for correct behavior.
We are introducing System.Numerics.Complex in .NET 11 #127333 and so should go through the effort of updating the implementation to be IEEE 754 compliant with regards to the various NaN, +/-Infinity, and +/- edge cases.
Noting that while IEEE 754 doesn't itself explicitly call out the behavior for complex numbers and somewhat leaves it "out of scope", it does provide enough information around intent and there are likewise formal mathematical models and behaviors documented for the "extended real number system" that make the "spec compliant" behaviors obvious. These behaviors are explicitly called out and documented in Annex G - IEC 60559 compatible complex arithmetic of the C Language standard as well, under the same general rationale, and are the "de facto" standard for behavior here.
The System.Numerics.Complex type was introduced in .NET Framework 4.0. It was not originally implemented to be IEEE 754 compliant and deviates from the established standards that C and other languages specify for correct behavior.
We are introducing System.Numerics.Complex in .NET 11 #127333 and so should go through the effort of updating the implementation to be IEEE 754 compliant with regards to the various NaN, +/-Infinity, and +/- edge cases.
Noting that while IEEE 754 doesn't itself explicitly call out the behavior for
complexnumbers and somewhat leaves it "out of scope", it does provide enough information around intent and there are likewise formal mathematical models and behaviors documented for the "extended real number system" that make the "spec compliant" behaviors obvious. These behaviors are explicitly called out and documented inAnnex G - IEC 60559 compatible complex arithmeticof the C Language standard as well, under the same general rationale, and are the "de facto" standard for behavior here.