In 2000, Paolo Ferragina and Giovanni Manzini published a deceptively simple idea: take a string, apply the Burrows-Wheeler Transform (BWT), and you simultaneously compress the text and build a searchable index over it. The resulting structure — the FM-index — lets you count every occurrence of a pattern of length in O(m) time, regardless of how large the underlying text is.
That might sound routine. It is not. Before the FM-index, searching a large text typically meant either keeping the full text in memory (expensive) or decompressing it before searching (slow). The FM-index does neither. It answers queries directly on the compressed representation.
The breakthrough landed at exactly the right moment: the Human Genome Project had just deposited three billion base pairs of DNA into public databases, and researchers desperately needed a way to align short sequencing reads against that reference without loading the entire thing into RAM. Tools like BWA and Bowtie — both built on the FM-index — became the workhorses of an entire generation of genomics. Today every short-read aligner you are likely to encounter uses a variant of this structure.
The core idea rests on two components working together: the BWT, which rearranges the characters of the text so that repeated substrings cluster together (making the text highly compressible), and backward search, which exploits that rearrangement to count pattern occurrences by scanning the pattern from right to left, maintaining a shrinking interval in a sorted array of suffixes.
Comments
Loading comments...