gaioguys / GAIO.jl

A Julia package for set oriented computations.
MIT License
8 stars 4 forks source link

Add `BoxSet` constructor, fix bad url in `docs | latest` button, ensure consistent one-based indexing in `BoxPartition` #66

Closed April-Hannah-Lena closed 1 year ago

April-Hannah-Lena commented 1 year ago

I'm preparing the update to FLoops.jl, and have some small changes that are required for that future PR. Also some docstrings had typos.

Adds a constructor to allow Boxsets to be made using arrays of boxes, ie

S = [Box(center_1, radius_1), Box(center_2, radius_2), Box(center_3, radius_3)]
P = BoxPartition(Box(center_1, radius_1 .+ radius_2 .+ radius_3), (100,100,100))
B = P[S]

returns a covering of S using boxes from P.

Also, some sections in partition_regular.jl use zero-based indexing, which caused some confusing errors. They are now fixed. partition_tree.jl still uses zero-based indexing and one-based indexing together; I'm considering a rework on that file.

gaioguy commented 1 year ago

Useful indeed.