Macaulay2 Engine
Loading...
Searching...
No Matches
F4SPairSet Class Reference

S-pair scheduling queue used by F4GB: collects pairs, deduplicates them, and hands out the next degree's worth on demand. More...

#include <f4-spairs.hpp>

Public Member Functions

 F4SPairSet (const MonomialInfo *MI0, const gb_array &gb0)
 ~F4SPairSet ()
void insert_generator (int deg, packed_monomial lcm, int column)
void insert_spair (pre_spair *p, int me)
void delete_spair (spair *p)
int find_new_pairs (bool remove_disjoints)
std::pair< bool, intsetThisDegree ()
std::pair< bool, spairget_next_pair ()
void discardSPairsInCurrentDegree ()
void display_spair (spair *p)
void display ()
long n_unneeded_pairs () const
size_t numberOfSPairs () const
double secondsToMinimizePairs () const
double secondsToCreatePrePairs () const

Private Member Functions

spairmake_spair (SPairType type, int deg, int i, int j)
bool pair_not_needed (spair *p, gbelem *m)
int remove_unneeded_pairs ()
pre_spaircreate_pre_spair (int i)
int construct_pairs (bool remove_disjoints)

Private Attributes

F4MemoryBlock< pre_spairPS
F4MemoryBlock< varpower_wordVP
MemoryBlock mSPairLCMs
int max_varpower_size
const MonomialInfoM
const gb_arraygb
std::vector< spairmSPairs
SPairCompare mSPairCompare
std::priority_queue< size_t, std::vector< size_t >, SPairComparemSPairQueue
long mThisDegree
long nsaved_unneeded
double mMinimizePairsSeconds
double mPrePairsSeconds

Detailed Description

S-pair scheduling queue used by F4GB: collects pairs, deduplicates them, and hands out the next degree's worth on demand.

Note
AI-generated documentation. Verify against the source before relying on it.

Pre-S-pairs are built from each newly inserted GB element and slotted into the working pool. make_spair promotes a pre_spair into a full spair with its LCM and sugar degree. A std::priority_queue ordered by SPairCompare keeps the next degree at the top. MemoryBlocks back the monomial storage so pair construction stays bump-pointer cheap, and the held mtbb::task_arena& lets the queue share the scheduler F4GB uses for Gauss elimination.

Definition at line 67 of file f4-spairs.hpp.


The documentation for this class was generated from the following files: