Lattice Tester Online Documentation 0.1.0-861
Software Package For Testing The Uniformity Of Integral Lattices In The Real Space
Loading...
Searching...
No Matches
LLL_FP_lt.cc File Reference
#include <NTL/fileio.h>
#include <NTL/vector.h>
#include <NTL/matrix.h>
#include <NTL/vec_double.h>
#include <NTL/ZZ.h>
#include <NTL/mat_ZZ.h>
#include <NTL/LLL.h>
#include <latticetester/LLL_lt.h>

Macros

#define TR_BND   (NTL_FDOUBLE_PRECISION/2.0)
 

Functions

static NTL_START_IMPL void CheckFinite (double *p)
 
static double InnerProduct (double *a, double *b, long n)
 
static void RowTransform (vec_ZZ &A, vec_ZZ &B, const ZZ &MU1)
 
static double max_abs (double *v, long n)
 
static void RowTransformStart (double *a, long *in_a, long &in_float, long n)
 
static void RowTransformFinish (vec_ZZ &A, double *a, long *in_a)
 
static void RowTransform (vec_ZZ &A, vec_ZZ &B, const ZZ &MU1, double *a, double *b, long *in_a, double &max_a, double max_b, long &in_float)
 
static void RowTransform2 (vec_ZZ &A, vec_ZZ &B, const ZZ &MU1)
 
static void ComputeGS (mat_ZZ &B, double **B1, double **mu, double *b, double *c, long k, double bound, long st, double *buf)
 
static void LLLStatus (long max_k, double t, long m, const mat_ZZ &B)
 
static void init_red_fudge ()
 
static void inc_red_fudge ()
 
void ComputeGS (const mat_ZZ &B, mat_RR &B1, mat_RR &mu, vec_RR &b, vec_RR &c, long k, const RR &bound, long st, vec_RR &buf, const RR &bound2)
 
static void RR_GS (mat_ZZ &B, double **B1, double **mu, double *b, double *c, double *buf, long prec, long rr_st, long k, long m_orig, mat_RR &rr_B1, mat_RR &rr_mu, vec_RR &rr_b, vec_RR &rr_c)
 
static long ll_LLL_FP (mat_ZZ &B, mat_ZZ *U, double delta, long deep, LLLCheckFct check, double **B1, double **mu, double *b, double *c, long m, long init_k, long &quit)
 
long LLL_FP_lt (mat_ZZ &BB, double delta, long m, long n, vec_double *sqlen)
 This function is similar to LLL_FP in NTL, but only the first r rows and first c columns of the matrix B are considered, and a basis is built for the lattice generated by these (partial) rows.
 
static void ComputeBKZConstant (long beta, long p)
 
static void ComputeBKZThresh (double *c, long beta)
 
static void BKZStatus (double tt, double enum_time, unsigned long NumIterations, unsigned long NumTrivial, unsigned long NumNonTrivial, unsigned long NumNoOps, long m, const mat_ZZ &B)
 
long BKZ_FP_lt (mat_ZZ &BB, double delta, long beta, long prune, long m, long n, vec_double *sqlen)
 This function is similar to BKZ_FP in NTL, with the same modifications as in LLL_FPInt above.
 

Variables

NTL_CHEAP_THREAD_LOCAL double LLLStatusInterval64 = 900.0
 
NTL_CHEAP_THREAD_LOCAL char * LLLDumpFile64 = 0
 
static NTL_CHEAP_THREAD_LOCAL double red_fudge = 0
 
static NTL_CHEAP_THREAD_LOCAL long log_red = 0
 
static NTL_CHEAP_THREAD_LOCAL unsigned long NumSwaps = 0
 
static NTL_CHEAP_THREAD_LOCAL double RR_GS_time = 0
 
static NTL_CHEAP_THREAD_LOCAL double StartTime = 0
 
static NTL_CHEAP_THREAD_LOCAL double LastTime = 0
 
static vec_double BKZConstant
 
static vec_double BKZThresh
 

Macro Definition Documentation

◆ TR_BND

#define TR_BND   (NTL_FDOUBLE_PRECISION/2.0)

Function Documentation

◆ BKZ_FP_lt()

long BKZ_FP_lt ( mat_ZZ & BB,
double delta,
long beta,
long prune,
long m,
long n,
vec_double * sqlen )

This function is similar to BKZ_FP in NTL, with the same modifications as in LLL_FPInt above.

◆ BKZStatus()

static void BKZStatus ( double tt,
double enum_time,
unsigned long NumIterations,
unsigned long NumTrivial,
unsigned long NumNonTrivial,
unsigned long NumNoOps,
long m,
const mat_ZZ & B )
static

◆ CheckFinite()

static NTL_START_IMPL void CheckFinite ( double * p)
inlinestatic

◆ ComputeBKZConstant()

static void ComputeBKZConstant ( long beta,
long p )
static

◆ ComputeBKZThresh()

static void ComputeBKZThresh ( double * c,
long beta )
static

◆ ComputeGS() [1/2]

void ComputeGS ( const mat_ZZ & B,
mat_RR & B1,
mat_RR & mu,
vec_RR & b,
vec_RR & c,
long k,
const RR & bound,
long st,
vec_RR & buf,
const RR & bound2 )

◆ ComputeGS() [2/2]

static void ComputeGS ( mat_ZZ & B,
double ** B1,
double ** mu,
double * b,
double * c,
long k,
double bound,
long st,
double * buf )
static

◆ inc_red_fudge()

static void inc_red_fudge ( )
static

◆ init_red_fudge()

static void init_red_fudge ( )
static

◆ InnerProduct()

static double InnerProduct ( double * a,
double * b,
long n )
static

◆ ll_LLL_FP()

static long ll_LLL_FP ( mat_ZZ & B,
mat_ZZ * U,
double delta,
long deep,
LLLCheckFct check,
double ** B1,
double ** mu,
double * b,
double * c,
long m,
long init_k,
long & quit )
static

◆ LLL_FP_lt()

long LLL_FP_lt ( mat_ZZ & B,
double delta = 0.99,
long r = 0,
long c = 0,
vec_double * sqlen = 0 )

This function is similar to LLL_FP in NTL, but only the first r rows and first c columns of the matrix B are considered, and a basis is built for the lattice generated by these (partial) rows.

The other elements of B are ignored. The basis is returned in the upper left corner of B, with the shortest basis vector always in the first row. If r=0, then all the rows of the IntMat object are taken. If c=0, then all the columns are taken. The square lengths of the returned basis vectors are also returned in the double vector sqlen, in sqlen[0],..., sqlen[d-1], if this vector given. The indices of B and sqlen start at 0. The function returns the dimension of the computed basis (the number of independent rows).

◆ LLLStatus()

static void LLLStatus ( long max_k,
double t,
long m,
const mat_ZZ & B )
static

◆ max_abs()

static double max_abs ( double * v,
long n )
static

◆ RowTransform() [1/2]

static void RowTransform ( vec_ZZ & A,
vec_ZZ & B,
const ZZ & MU1 )
static

◆ RowTransform() [2/2]

static void RowTransform ( vec_ZZ & A,
vec_ZZ & B,
const ZZ & MU1,
double * a,
double * b,
long * in_a,
double & max_a,
double max_b,
long & in_float )
static

◆ RowTransform2()

static void RowTransform2 ( vec_ZZ & A,
vec_ZZ & B,
const ZZ & MU1 )
static

◆ RowTransformFinish()

static void RowTransformFinish ( vec_ZZ & A,
double * a,
long * in_a )
static

◆ RowTransformStart()

static void RowTransformStart ( double * a,
long * in_a,
long & in_float,
long n )
static

◆ RR_GS()

static void RR_GS ( mat_ZZ & B,
double ** B1,
double ** mu,
double * b,
double * c,
double * buf,
long prec,
long rr_st,
long k,
long m_orig,
mat_RR & rr_B1,
mat_RR & rr_mu,
vec_RR & rr_b,
vec_RR & rr_c )
static

Variable Documentation

◆ BKZConstant

vec_double BKZConstant
static

◆ BKZThresh

vec_double BKZThresh
static

◆ LastTime

NTL_CHEAP_THREAD_LOCAL double LastTime = 0
static

◆ LLLDumpFile64

NTL_CHEAP_THREAD_LOCAL char* LLLDumpFile64 = 0

◆ LLLStatusInterval64

NTL_CHEAP_THREAD_LOCAL double LLLStatusInterval64 = 900.0

◆ log_red

NTL_CHEAP_THREAD_LOCAL long log_red = 0
static

◆ NumSwaps

NTL_CHEAP_THREAD_LOCAL unsigned long NumSwaps = 0
static

◆ red_fudge

NTL_CHEAP_THREAD_LOCAL double red_fudge = 0
static

◆ RR_GS_time

NTL_CHEAP_THREAD_LOCAL double RR_GS_time = 0
static

◆ StartTime

NTL_CHEAP_THREAD_LOCAL double StartTime = 0
static