complex.sin

fn sin(self: T) -> T;

Returns the sine of the complex number.

Args

  • self(T) - The input complex number.

Returns

A complex number representing the sin of the input value.

Examples

use orion::numbers::complex_number::{complex_trait::ComplexTrait, complex64::complex64};
use orion::numbers::{FP64x64, FP64x64Impl, FixedTrait};

fn sin_complex64_example() -> complex64 {
    let z: complex64 = ComplexTrait::new(
        FixedTrait::new(36893488147419103232, false),
        FixedTrait::new(55340232221128654848, false)
    ); // 2 + 3i
    z.sin()
}
>>> {real: {mag: 168870549816927860082, sign: false}, im: {mag: 76902690389051588309, sign: true}} // 9.15449914 - 4.168906959 i

Last updated