@@ -57,23 +57,24 @@ function tocanonical(d::Circle{T},ζ) where T<:SVector
5757 _tocanonical (v)
5858end
5959
60+ orientationsign (d:: Circle ) = d. orientation ? 1 : - 1
6061
6162fromcanonical (d:: Circle{T,V,Complex{V}} ,θ) where {T<: Number ,V<: Real } =
62- d. radius* exp ((d . orientation ? 1 : - 1 ) * 1.0im * θ) + d. center
63+ d. radius * cis ( orientationsign (d) * θ) + d. center
6364fromcanonicalD (d:: Circle{T} ,θ) where {T<: Number } =
64- (d . orientation ? 1 : - 1 ) * d. radius* 1.0im * exp ((d . orientation ? 1 : - 1 ) * 1.0im * θ)
65+ orientationsign (d) * d. radius * 1.0im * cis ( orientationsign (d) * θ)
6566
6667
6768fromcanonical (d:: Circle{T} ,θ:: Number ) where {T<: SVector } =
68- d. radius* SVector (cos ((d . orientation ? 1 : - 1 )* θ),sin ((d . orientation ? 1 : - 1 )* θ)) + d. center
69+ d. radius* SVector (cos (orientationsign (d )* θ),sin (orientationsign (d )* θ)) + d. center
6970fromcanonicalD (d:: Circle{T} ,θ:: Number ) where {T<: SVector } =
70- d. radius* (d . orientation ? 1 : - 1 )* SVector (- sin ((d . orientation ? 1 : - 1 )* θ),cos ((d . orientation ? 1 : - 1 )* θ))
71+ d. radius* orientationsign (d )* SVector (- sin (orientationsign (d )* θ),cos (orientationsign (d )* θ))
7172
7273
7374indomain (z,d:: Circle ) = norm (z- d. center) ≈ d. radius
7475
7576arclength (d:: Circle ) = 2 π* d. radius
76- complexlength (d:: Circle ) = (d . orientation ? 1 : - 1 )* im* arclength (d) # TODO : why?
77+ complexlength (d:: Circle ) = orientationsign (d )* im* arclength (d) # TODO : why?
7778
7879
7980== (d:: Circle ,m:: Circle ) = d. center == m. center && d. radius == m. radius && d. orientation == m. orientation
0 commit comments