LINE Solver (C++)
Templated C++ port of the LINE queueing solver
Loading...
Searching...
No Matches
line::perm::HuberLawSampler Class Reference

Huber-Law acceptance-rejection sampler for the permanent. More...

#include <line/api/perm/perm_sampling.h>

Public Types

enum class  Mode { Classic , Time , Sample }

Public Member Functions

 HuberLawSampler (const Matrix< double > &matrix, double delta=0.1, double alpha2=0.000001, double epsilon=0.1, Mode mode=Mode::Classic, int number_of_samples=1000, double maximum_time=30000.0, std::uint64_t seed=0)
double solve ()
 Run the sampler in the configured mode and return the estimate.
double value () const
 Estimate of the last solve.

Detailed Description

Huber-Law acceptance-rejection sampler for the permanent.

The matrix is rescaled to be doubly stochastic, a permutation is drawn column by column under the Huber-Law upper bound on the remaining permanent, and the acceptance ratio times the rescaling constant estimates the permanent.

Definition at line 493 of file perm_sampling.h.

Member Enumeration Documentation

◆ Mode

Enumerator
Classic 
Time 
Sample 

Definition at line 495 of file perm_sampling.h.

Constructor & Destructor Documentation

◆ HuberLawSampler()

line::perm::HuberLawSampler::HuberLawSampler ( const Matrix< double > & matrix,
double delta = 0.1,
double alpha2 = 0.000001,
double epsilon = 0.1,
Mode mode = Mode::Classic,
int number_of_samples = 1000,
double maximum_time = 30000.0,
std::uint64_t seed = 0 )
inlineexplicit
Parameters
matrixnonnegative square matrix
deltarelative accuracy target, sets the budget K
alpha2convergence threshold of the rescaling
epsilonfailure probability target, sets the budget K
modewhich budget applies
number_of_samplesdraw budget of Sample
maximum_timetime budget in milliseconds of Time
seedseed of the draws

Definition at line 507 of file perm_sampling.h.

References Classic.

Member Function Documentation

◆ solve()

double line::perm::HuberLawSampler::solve ( )
inline

Run the sampler in the configured mode and return the estimate.

Definition at line 528 of file perm_sampling.h.

References Classic, line::InputError::InputError(), Sample, and Time.

Referenced by line::perm::perm_huberlaw().

◆ value()

double line::perm::HuberLawSampler::value ( ) const
inline

Estimate of the last solve.

Definition at line 556 of file perm_sampling.h.


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