106 for (
i = 1;
i <= p;
i++) {
107 if (alphabet !=
NULL)
111 *cursor = *cursor + 1;
156 for (j = 1; j <=
n -
i; j++)
163 while (
a[
i] == k - 1)
192 Int4 num_entries = 0;
#define sfree(x)
Safe free a pointer: belongs to a higher level header.
static const char location[]
uint8_t Uint1
1-byte (8-bit) unsigned integer
int32_t Int4
4-byte (32-bit) signed integer
int64_t Int8
8-byte (64-bit) signed integer
Int4 EstimateNumTableEntries(BlastSeqLoc *location, Int4 *max_off)
Given a list of query locations, estimate the number of words that would need to be added to a lookup...
static void fkm(Int4 *a, Int4 n, Int4 k, Uint1 *output, Int4 *cursor, Uint1 *alphabet)
iterative fredricksen-kessler-maiorana algorithm to generate de bruijn sequences.
Int4 iexp(Int4 x, Int4 n)
Integer exponentiation using right to left binary algorithm.
Int4 ilog2(Int8 x)
Integer base two logarithm.
void debruijn(Int4 n, Int4 k, Uint1 *output, Uint1 *alphabet)
generates a de Bruijn sequence containing all substrings of length n over an alphabet of size k.
static void fkm_output(Int4 *a, Int4 n, Int4 p, Uint1 *output, Int4 *cursor, Uint1 *alphabet)
Output a Lyndon word as part of a de Bruijn sequence.
Utility functions for lookup table generation.
#define MAX(a, b)
returns larger of a and b.
double r(size_t dimension_, const Int4 *score_, const double *prob_, double theta_)
static SQLCHAR output[256]
Used to hold a set of positions, mostly used for filtering.
SSeqRange * ssr
location data on the sequence.
struct BlastSeqLoc * next
next in linked list
Int4 left
left endpoint of range (zero based)
Int4 right
right endpoint of range (zero based)
voidp calloc(uInt items, uInt size)