<s>
In	O
computer	B-General_Concept
science	I-General_Concept
,	O
a	O
suffix	B-Architecture
tree	I-Architecture
(	O
also	O
called	O
PAT	O
tree	O
or	O
,	O
in	O
an	O
earlier	O
form	O
,	O
position	B-Architecture
tree	I-Architecture
)	O
is	O
a	O
compressed	O
trie	B-General_Concept
containing	O
all	O
the	O
suffixes	O
of	O
the	O
given	O
text	O
as	O
their	O
keys	O
and	O
positions	O
in	O
the	O
text	O
as	O
their	O
values	O
.	O
</s>
<s>
Suffix	B-Architecture
trees	I-Architecture
allow	O
particularly	O
fast	O
implementations	O
of	O
many	O
important	O
string	O
operations	O
.	O
</s>
<s>
Once	O
constructed	O
,	O
several	O
operations	O
can	O
be	O
performed	O
quickly	O
,	O
for	O
instance	O
locating	O
a	O
substring	O
in	O
,	O
locating	O
a	O
substring	O
if	O
a	O
certain	O
number	O
of	O
mistakes	O
are	O
allowed	O
,	O
locating	O
matches	O
for	O
a	O
regular	B-Language
expression	I-Language
pattern	O
etc	O
.	O
</s>
<s>
Suffix	B-Architecture
trees	I-Architecture
also	O
provided	O
one	O
of	O
the	O
first	O
linear-time	O
solutions	O
for	O
the	O
longest	B-Algorithm
common	I-Algorithm
substring	I-Algorithm
problem	I-Algorithm
.	O
</s>
<s>
These	O
speedups	O
come	O
at	O
a	O
cost	O
:	O
storing	O
a	O
string	O
's	O
suffix	B-Architecture
tree	I-Architecture
typically	O
requires	O
significantly	O
more	O
space	O
than	O
storing	O
the	O
string	O
itself	O
.	O
</s>
<s>
Rather	O
than	O
the	O
suffix	O
,	O
Weiner	O
stored	O
in	O
his	O
trie	B-General_Concept
the	O
prefix	O
identifier	O
for	O
each	O
position	O
,	O
that	O
is	O
,	O
the	O
shortest	O
string	O
starting	O
at	O
and	O
occurring	O
only	O
once	O
in	O
.	O
</s>
<s>
His	O
Algorithm	O
D	O
takes	O
an	O
uncompressed	B-General_Concept
trie	B-General_Concept
for	O
and	O
extends	O
it	O
into	O
a	O
trie	B-General_Concept
for	O
.	O
</s>
<s>
This	O
way	O
,	O
starting	O
from	O
the	O
trivial	O
trie	B-General_Concept
for	O
,	O
a	O
trie	B-General_Concept
for	O
can	O
be	O
built	O
by	O
successive	O
calls	O
to	O
Algorithm	O
D	O
;	O
however	O
,	O
the	O
overall	O
run	O
time	O
is	O
.	O
</s>
<s>
Weiner	O
's	O
Algorithm	O
B	O
maintains	O
several	O
auxiliary	O
data	O
structures	O
,	O
to	O
achieve	O
an	O
over	O
all	O
run	O
time	O
linear	O
in	O
the	O
size	O
of	O
the	O
constructed	O
trie	B-General_Concept
.	O
</s>
<s>
for	O
Weiner	O
's	O
Algorithm	O
C	O
finally	O
uses	O
compressed	O
tries	B-General_Concept
to	O
achieve	O
linear	O
overall	O
storage	O
size	O
and	O
run	O
time	O
.	O
</s>
<s>
The	O
text	O
book	O
reproduced	O
Weiner	O
's	O
results	O
in	O
a	O
simplified	O
and	O
more	O
elegant	O
form	O
,	O
introducing	O
the	O
term	O
position	B-Architecture
tree	I-Architecture
.	O
</s>
<s>
was	O
the	O
first	O
to	O
build	O
a	O
(	O
compressed	O
)	O
trie	B-General_Concept
of	O
all	O
suffixes	O
of	O
.	O
</s>
<s>
Although	O
the	O
suffix	O
starting	O
at	O
is	O
usually	O
longer	O
than	O
the	O
prefix	O
identifier	O
,	O
their	O
path	O
representations	O
in	O
a	O
compressed	O
trie	B-General_Concept
do	O
not	O
differ	O
in	O
size	O
.	O
</s>
<s>
He	O
provided	O
the	O
first	O
online-construction	O
of	O
suffix	B-Architecture
trees	I-Architecture
,	O
now	O
known	O
as	O
Ukkonen	B-Algorithm
's	I-Algorithm
algorithm	I-Algorithm
,	O
with	O
running	O
time	O
that	O
matched	O
the	O
then	O
fastest	O
algorithms	O
.	O
</s>
<s>
gave	O
the	O
first	O
suffix	B-Architecture
tree	I-Architecture
construction	O
algorithm	O
that	O
is	O
optimal	O
for	O
all	O
alphabets	O
.	O
</s>
<s>
Farach	O
's	O
algorithm	O
has	O
become	O
the	O
basis	O
for	O
new	O
algorithms	O
for	O
constructing	O
both	O
suffix	B-Architecture
trees	I-Architecture
and	O
suffix	B-Algorithm
arrays	I-Algorithm
,	O
for	O
example	O
,	O
in	O
external	O
memory	O
,	O
compressed	O
,	O
succinct	O
,	O
etc	O
.	O
</s>
<s>
The	O
suffix	B-Architecture
tree	I-Architecture
for	O
the	O
string	O
of	O
length	O
is	O
defined	O
as	O
a	O
tree	O
such	O
that	O
:	O
</s>
<s>
In	O
a	O
complete	O
suffix	B-Architecture
tree	I-Architecture
,	O
all	O
internal	O
non-root	O
nodes	O
have	O
a	O
suffix	O
link	O
to	O
another	O
internal	O
node	O
.	O
</s>
<s>
A	O
generalized	B-Algorithm
suffix	I-Algorithm
tree	I-Algorithm
is	O
a	O
suffix	B-Architecture
tree	I-Architecture
made	O
for	O
a	O
set	O
of	O
strings	O
instead	O
of	O
a	O
single	O
string	O
.	O
</s>
<s>
A	O
suffix	B-Architecture
tree	I-Architecture
for	O
a	O
string	O
of	O
length	O
can	O
be	O
built	O
in	O
time	O
,	O
if	O
the	O
letters	O
come	O
from	O
an	O
alphabet	O
of	O
integers	O
in	O
a	O
polynomial	O
range	O
(	O
in	O
particular	O
,	O
this	O
is	O
true	O
for	O
constant-sized	O
alphabets	O
)	O
.	O
</s>
<s>
For	O
larger	O
alphabets	O
,	O
the	O
running	O
time	O
is	O
dominated	O
by	O
first	O
sorting	B-Algorithm
the	O
letters	O
to	O
bring	O
them	O
into	O
a	O
range	O
of	O
size	O
;	O
in	O
general	O
,	O
this	O
takes	O
time	O
.	O
</s>
<s>
Assume	O
that	O
a	O
suffix	B-Architecture
tree	I-Architecture
has	O
been	O
built	O
for	O
the	O
string	O
of	O
length	O
,	O
or	O
that	O
a	O
generalised	B-Algorithm
suffix	I-Algorithm
tree	I-Algorithm
has	O
been	O
built	O
for	O
the	O
set	O
of	O
strings	O
of	O
total	O
length	O
.	O
</s>
<s>
Search	O
for	O
a	O
regular	B-Language
expression	I-Language
P	O
in	O
time	O
expected	O
sublinear	O
in	O
.	O
</s>
<s>
Find	O
the	O
longest	B-Algorithm
common	I-Algorithm
substrings	I-Algorithm
of	O
the	O
string	O
and	O
in	O
time	O
.	O
</s>
<s>
Find	O
the	O
Lempel	B-Algorithm
–	I-Algorithm
Ziv	I-Algorithm
decomposition	O
in	O
time	O
.	O
</s>
<s>
The	O
suffix	B-Architecture
tree	I-Architecture
can	O
be	O
prepared	O
for	O
constant	O
time	O
lowest	O
common	O
ancestor	O
retrieval	O
between	O
nodes	O
in	O
time	O
.	O
</s>
<s>
Find	O
the	O
longest	B-Algorithm
common	I-Algorithm
substrings	I-Algorithm
to	O
at	O
least	O
strings	O
in	O
for	O
in	O
time	O
.	O
</s>
<s>
Find	O
the	O
longest	O
palindromic	O
substring	O
of	O
a	O
given	O
string	O
(	O
using	O
the	O
generalized	B-Algorithm
suffix	I-Algorithm
tree	I-Algorithm
of	O
the	O
string	O
and	O
its	O
reverse	O
)	O
in	O
linear	O
time	O
.	O
</s>
<s>
Suffix	B-Architecture
trees	I-Architecture
can	O
be	O
used	O
to	O
solve	O
a	O
large	O
number	O
of	O
string	O
problems	O
that	O
occur	O
in	O
text-editing	O
,	O
free-text	O
search	O
,	O
computational	O
biology	O
and	O
other	O
application	O
areas	O
.	O
</s>
<s>
Suffix	B-Architecture
trees	I-Architecture
are	O
often	O
used	O
in	O
bioinformatics	O
applications	O
,	O
searching	O
for	O
patterns	O
in	O
DNA	O
or	O
protein	O
sequences	O
(	O
which	O
can	O
be	O
viewed	O
as	O
long	O
strings	O
of	O
characters	O
)	O
.	O
</s>
<s>
Suffix	B-Architecture
trees	I-Architecture
are	O
also	O
used	O
in	O
data	B-General_Concept
compression	I-General_Concept
;	O
they	O
can	O
be	O
used	O
to	O
find	O
repeated	O
data	O
,	O
and	O
can	O
be	O
used	O
for	O
the	O
sorting	B-Algorithm
stage	O
of	O
the	O
Burrows	B-Algorithm
–	I-Algorithm
Wheeler	I-Algorithm
transform	I-Algorithm
.	O
</s>
<s>
Variants	O
of	O
the	O
LZW	B-Algorithm
compression	I-Algorithm
schemes	O
use	O
suffix	B-Architecture
trees	I-Architecture
(	O
LZSS	B-Algorithm
)	O
.	O
</s>
<s>
A	O
suffix	B-Architecture
tree	I-Architecture
is	O
also	O
used	O
in	O
suffix	B-Operating_System
tree	I-Operating_System
clustering	I-Operating_System
,	O
a	O
data	B-Algorithm
clustering	I-Algorithm
algorithm	O
used	O
in	O
some	O
search	O
engines	O
.	O
</s>
<s>
The	O
worst-case	O
space	O
usage	O
of	O
a	O
suffix	B-Architecture
tree	I-Architecture
is	O
seen	O
with	O
a	O
fibonacci	B-Algorithm
word	I-Algorithm
,	O
giving	O
the	O
full	O
nodes	O
.	O
</s>
<s>
An	O
important	O
choice	O
when	O
making	O
a	O
suffix	B-Architecture
tree	I-Architecture
implementation	O
is	O
the	O
parent-child	O
relationships	O
between	O
nodes	O
.	O
</s>
<s>
The	O
most	O
common	O
is	O
using	O
linked	B-Data_Structure
lists	I-Data_Structure
called	O
sibling	O
lists	O
.	O
</s>
<s>
Other	O
implementations	O
with	O
efficient	O
running	O
time	O
properties	O
use	O
hash	B-Algorithm
maps	I-Algorithm
,	O
sorted	O
or	O
unsorted	O
arrays	O
(	O
with	O
array	B-Data_Structure
doubling	I-Data_Structure
)	O
,	O
or	O
balanced	O
search	O
trees	O
.	O
</s>
<s>
The	O
large	O
amount	O
of	O
information	O
in	O
each	O
edge	O
and	O
node	O
makes	O
the	O
suffix	B-Architecture
tree	I-Architecture
very	O
expensive	O
,	O
consuming	O
about	O
10	O
to	O
20	O
times	O
the	O
memory	O
size	O
of	O
the	O
source	O
text	O
in	O
good	O
implementations	O
.	O
</s>
<s>
The	O
suffix	B-Algorithm
array	I-Algorithm
reduces	O
this	O
requirement	O
to	O
a	O
factor	O
of	O
8	O
(	O
for	O
array	B-Data_Structure
including	O
LCP	B-Data_Structure
values	O
built	O
within	O
32-bit	O
address	O
space	O
and	O
8-bit	O
characters	O
.	O
)	O
</s>
<s>
This	O
factor	O
depends	O
on	O
the	O
properties	O
and	O
may	O
reach	O
2	O
with	O
usage	O
of	O
4-byte	O
wide	O
characters	O
(	O
needed	O
to	O
contain	O
any	O
symbol	O
in	O
some	O
UNIX-like	B-Operating_System
systems	I-Operating_System
,	O
see	O
wchar_t	O
)	O
on	O
32-bit	O
systems	O
.	O
</s>
<s>
Various	O
parallel	O
algorithms	O
to	O
speed	O
up	O
suffix	B-Architecture
tree	I-Architecture
construction	O
have	O
been	O
proposed	O
.	O
</s>
<s>
Recently	O
,	O
a	O
practical	O
parallel	O
algorithm	O
for	O
suffix	B-Architecture
tree	I-Architecture
construction	O
with	O
work	B-Operating_System
(	O
sequential	O
time	O
)	O
and	O
span	B-Operating_System
has	O
been	O
developed	O
.	O
</s>
<s>
is	O
theoretically	O
optimal	O
,	O
with	O
an	O
I/O	O
complexity	O
equal	O
to	O
that	O
of	O
sorting	B-Algorithm
.	O
</s>
<s>
TDD	O
and	O
TRELLIS	O
scale	O
up	O
to	O
the	O
entire	O
human	O
genome	O
resulting	O
in	O
a	O
disk-based	O
suffix	B-Architecture
tree	I-Architecture
of	O
a	O
size	O
in	O
the	O
tens	O
of	O
gigabytes	O
.	O
</s>
<s>
ERA	O
is	O
a	O
recent	O
parallel	O
suffix	B-Architecture
tree	I-Architecture
construction	O
method	O
that	O
is	O
significantly	O
faster	O
.	O
</s>
