Skip to content

Commit

Permalink
Update DividedRectangles.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
tawheeler authored Sep 22, 2024
1 parent cb0bfdb commit a79649f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/DividedRectangles.jl
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ function is_ccw(a::DirectRectangle, b::DirectRectangle, c::DirectRectangle)
return a.r*(b.y-c.y)-a.y*(b.r-c.r)+(b.r*c.y-b.y*c.r) < 1e-6
end

"""
A helper function that returns a basis vector with a single 1 entry in an otherwise zero vector.
"""
basis(i, n) = [k == i ? 1.0 : 0.0 for k in 1 : n]

"""
A routine for obtaining the split intervals from a given list of intervals and a minimum radius.
The potentially optimal intervals form a lower-right convex hull in r and y.
Expand Down

0 comments on commit a79649f

Please sign in to comment.