Skip to content

Conversation

@Haadi-Khan
Copy link
Member

No description provided.

@Haadi-Khan Haadi-Khan marked this pull request as draft February 27, 2025 23:00
Haadi-Khan and others added 13 commits February 27, 2025 18:15
The variable naming scheme is abysmal — I'll reread the original
codebase so I have a better idea for our implementation
Going (very far) away from the C++ impl we found. Kevin's code didn't
compile so I fixed it and did some modifications to better fit our aim.
All I need to do is add the "upper rank" colonies and then we can get to
implementing our scheme.
Basically all the Harrington rules will be implemented through
LatticeManager (at least the way I see it right now). Broadcasting and
all other roles can probably be handled through it. Maybe this should be
refactored at some point, but I think this is the most straightforward
impl to start with.
I created three levels of lattices in order to get around the problem with having every lattice field be an Option type. All of the automata and edges are now owned by LatticeManager, in addition to the lattices. This is to resolve the issue of what owns the edges between BaseLattices. The primary and dual fields in LatticeManager own the Edges and map the Automata to their edges. The BaseLattice just has a HashMap from points to AutomatonId's, which are used to access the fields in LatticeManager. I also added some basic structure for the HarringtonRules to build on. Some of the creation/building of the LatticeManager and all of its children still needs to be implemented
There are now three separate stores for the lattices. The Lattice trait is used to insert and get lattices from the store so that they access the correct store based on the type of the lattice.
…ifetimes are terrible and I have no idea how they work, will figure out later. Also need to actually assign neighbors. I created point associated with each higher level lattice (relative to supercolony), should be able to use to assign neighbors easily (maybe make hashmap from each point to lattice id in super colony to make look up extremely easy).
…in top lattice. Again has a couple errors mostly with lifetime stuff, but think this structure should be solid. Will need more work for assigning neighbors for lower levels due to neighbors being within seperate middle lattices for lower lattices
I think that some of it stems from what owns middle_id, since it is being dropped. The mid_store of the lattice manager should own it, but create_middle_lattice may not be doing this properly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants