30  for (
int i= 0; 
i < 
k; 
i++)
 
   44  double pi= 3.141592653589793;
 
   45  double a= 0.140012288;
 
   48  double buf= 2.0/(
pi*a)+
log (1.0-d*d)/2.0;
 
   74  double pn= 
pow ((
double) 
p, (
double) n);
 
   75  double p1= (double) 1/
p;
 
   82  double p2= (double) (2*
p-1)/(
p*
p);
 
   87  p2= (double) (2*
p - 1)/(
p*
p)-p2;
 
   98  int trials= (int) floor (
pow (sqrtTrials, 2.0));
 
  100  double experimentalNumZeros= 
numZeros (
G, trials);
 
  102  double pmiddle= 
sqrt (p1*p2);
 
  108  if (experimentalNumZeros < pmiddle)
 
Rational pow(const Rational &a, int e)
 
const CanonicalForm CFMap CFMap & N
 
CanonicalForm compress(const CanonicalForm &f, CFMap &m)
CanonicalForm compress ( const CanonicalForm & f, CFMap & m )
 
generate random integers, random elements of finite fields
 
generate random elements in F_p
 
CanonicalForm generate() const
 
const CanonicalForm int s
 
double numZeros(const CanonicalForm &F, int k)
evaluate F at k random points in Z/p^n and count the number of zeros that occur
 
int probIrredTest(const CanonicalForm &F, double error)
given some error probIrredTest detects irreducibility or reducibility of F with confidence level 1-er...
 
double inverseERF(double d)
 
This file provides a probabilistic irreducibility test for polynomials over Z/p.
 
gmp_float sqrt(const gmp_float &a)
 
gmp_float log(const gmp_float &a)
 
int status int void * buf