aboutsummaryrefslogtreecommitdiff
path: root/src/numerics.cpp
AgeCommit message (Collapse)Author
2024-07-27iterate now returns a tuple of the three fractions worked onAryadev Chavali
The left, currently processed (centre) and right fractions are returned by iterate. This allows us to see exactly what fractions have been generated/worked on in every iteration.
2024-07-26NodeAllocator constructor now reserves space in vectorAryadev Chavali
This is different to vec{capacity}, which would adjust vec::size. This adjusts vec::capacity instead, which is what I want.
2024-07-26NodeAllocator can now get nodes by value or by referenceAryadev Chavali
Abstracting the interface more, such that callers can use functions rather than accessing internals directly, allows me to refactor the allocator without having to do a ton of edits all across the source tree.
2024-07-26Changed from int64_t to optional<word_t> for pointers in NodeAryadev Chavali
2024-07-26`iterate` now computes highest value fraction it generated.Aryadev Chavali
Not very useful, but isn't a massive performance waster (I think) and it will be useful when thinking about colour schemes in graphics.
2024-07-26Introduce normalised value in fraction classAryadev Chavali
Bit of a cheat but it would allow us to do some interesting graphical stuff later.
2024-07-26Implemented numerics in numerics.cppAryadev Chavali
Simple implementation, few refactors from the main.cpp version based on API changes.