FM-index backward search counts exact matches by shrinking a suffix-array interval.
highlighted = computed this step
Search right to left
Backward search scans the pattern from right to left. Each scanned letter shrinks a suffix-array interval until only matching suffixes remain.
right-to-left pattern scan
The final interval counts matches
For pattern A, backward search returns interval [1,4). The width is 3, matching the number of occurrences.
[1,4) has width 3
Read mappers use this idea
Tools such as BWA and Bowtie use FM-index ideas to map reads without storing every suffix explicitly. The index narrows the candidate locations for exact seeds.