DoxigAlpha

sin

Returns the sine of z.

Function parameters

Parameters

#
z:anytype

Returns the sine of z.

Functions

#
sin
Returns the sine of z.

Source

Implementation

#
pub fn sin(z: anytype) Complex(@TypeOf(z.re, z.im)) {
    const T = @TypeOf(z.re, z.im);
    const p = Complex(T).init(-z.im, z.re);
    const q = cmath.sinh(p);
    return Complex(T).init(q.im, -q.re);
}