addaptic

Reference Complex inverse functions

lzc_arctangent

The principal arctangent of a complex number.

long lzc_arctangent( CLZComplex* leftOperand, CLZComplex* targetNumber = nullptr );

The principal value, each part correctly rounded, the whole angle written in the thread's unit. On a cut it takes the operand's +0 side: arctan 2i is π/2 + i artanh ½. In degrees arctan(0.6 + 0.8i) has a real part of exactly 45. ±i are poles: kUndefinedResult, the point at infinity.

Examples

CallAnswerReturns
lzc_arctangent( 0 + 2i )1.570796326794896619231321691639751442 + 0.549306144334054845697622618461262852ikNoError
lzc_arctangent( 0.6 + 0.8i ) degrees45 + 31.472923730945380019772415390685888252ikNoError
lzc_arctangent( 0 + 1i )the point at infinitykUndefinedResult

Each answer is what Addaptic printed for the call, in radians, at 36 places unless a setting is shown.

Returns

kNoError (0) when the answer is written. Otherwise an error code, with the answer flagged infinite or not-a-number; see Errors and flags.

See also