std › math › complex › tantanReturns the tangent of z. Function parametersParameters#z:anytype Returns the tangent of z.Functions#tan Returns the tangent of z.SourceImplementation#pub fn tan(z: anytype) Complex(@TypeOf(z.re, z.im)) { const T = @TypeOf(z.re, z.im); const q = Complex(T).init(-z.im, z.re); const r = cmath.tanh(q); return Complex(T).init(r.im, -r.re); }
pub fn tan(z: anytype) Complex(@TypeOf(z.re, z.im)) { const T = @TypeOf(z.re, z.im); const q = Complex(T).init(-z.im, z.re); const r = cmath.tanh(q); return Complex(T).init(r.im, -r.re); }