cis
cis(z)
Return $\exp(iz)$.
Examples
cis(z)
The cis(z)
function returns the complex exponential of iz
, which is equivalent to exp(iz)
.
julia> cis(π/2)
6.123233995736766e-17 + 1.0im
Here are some common examples of using cis(z)
:
-
Calculate the complex exponential:
julia> z = 2 + 3im; julia> cis(z) -0.131202 + 0.991057im
The
cis(z)
function returns the complex exponential ofz
. - Generate points on the unit circle:
julia> angles = range(0, stop=2π, length=8); julia> points = cis.(angles) 8-element Vector{ComplexF64}: 1.0 + 0.0im 0.7071067811865476 + 0.7071067811865475im 6.123233995736766e-17 + 1.0im -0.7071067811865475 + 0.7071067811865476im -1.0 + 1.2246467991473532e-16im -0.7071067811865477 - 0.7071067811865474im -1.8369701987210297e-16 - 1.0im 0.7071067811865474 - 0.7071067811865477im
This example generates complex points on the unit circle using
cis(z)
.
Remember, the cis(z)
function is equivalent to exp(iz)
, where z
is a complex number.
See Also
User Contributed Notes
Add a Note
The format of note supported is markdown, use triple backtick to start and end a code block.