📘 Sets

📘 Sets#

In the GALACTIC framework, sets are fundamental data structures that allow us to store and manipulate unique elements. This tutorial will guide you through the various set types available in the galactic.algebras.set.core module.

We will cover the following set types:

  • FIFOSet and FrozenFIFOSet are set implementations that maintain the order of element insertion using a First-In-First-Out (FIFO) strategy. They are particularly useful when the order of elements matters.

  • Universe are sets that represent a complete indexable universe of elements. They are immutable.

  • IndexRange are sets that represent a range of integer indices. They are immutable and can be used to efficiently represent a range of integers.

  • SubSet are sets that represent a subset of a universe (a Universe or IndexRange). They are immutable and are efficiently represented by bitmaps.