Skip to main content

Table 1 Algorithm for computing q* by a binary search strategy.

From: Efficient computation of absent words in genomic sequences

1: determine sequence length n

2: l ← 1

3: r ← log4 (n + 1)

4: while lr do

5:    q ← (l + r)/2

6:    compute Ω q

7:    if q | < 4qthen

8:       q'q

9:       Ω q' ← Ω q

10:       rq - 1

11:    else

12:       lq + 1

13:    end if

14: end while

15: q* ← q'

16: Ωq*← Ω q'

17: for all j [0, 4q* - 1] do

18:    if Ωq*[j] = 0 then

19:       print w such that φq*(w) = j

20:    end if

21: end for