<s>
In	O
computer	B-General_Concept
science	I-General_Concept
,	O
a	O
monotone	B-Application
priority	I-Application
queue	I-Application
is	O
a	O
variant	O
of	O
the	O
priority	B-Application
queue	I-Application
abstract	O
data	O
type	O
in	O
which	O
the	O
priorities	O
of	O
extracted	O
items	O
are	O
required	O
to	O
form	O
a	O
monotonic	O
sequence	O
.	O
</s>
<s>
That	O
is	O
,	O
for	O
a	O
priority	B-Application
queue	I-Application
in	O
which	O
each	O
successively	O
extracted	O
item	O
is	O
the	O
one	O
with	O
the	O
minimum	O
priority	O
(	O
a	O
min-heap	O
)	O
,	O
the	O
minimum	O
priority	O
should	O
be	O
monotonically	O
increasing	O
.	O
</s>
<s>
The	O
assumption	O
of	O
monotonicity	O
arises	O
naturally	O
in	O
several	O
applications	O
of	O
priority	B-Application
queues	I-Application
,	O
and	O
can	O
be	O
used	O
as	O
a	O
simplifying	O
assumption	O
to	O
speed	O
up	O
certain	O
types	O
of	O
priority	B-Application
queues	I-Application
.	O
</s>
<s>
A	O
necessary	O
and	O
sufficient	O
condition	O
on	O
a	O
monotone	B-Application
priority	I-Application
queue	I-Application
is	O
that	O
one	O
never	O
attempts	O
to	O
add	O
an	O
element	O
with	O
lower	O
priority	O
than	O
the	O
most	O
recently	O
extracted	O
one	O
.	O
</s>
<s>
Monotone	B-Application
priority	I-Application
queues	I-Application
arise	O
naturally	O
when	O
arranging	O
events	O
in	O
order	O
of	O
time	O
,	O
such	O
as	O
network	O
timeouts	O
or	O
discrete	B-General_Concept
event	I-General_Concept
simulation	I-General_Concept
.	O
</s>
<s>
An	O
event	O
can	O
cause	O
some	O
action	O
to	O
be	O
scheduled	O
at	O
some	O
time	O
in	O
the	O
future	O
,	O
but	O
(	O
real	O
or	O
simulated	O
)	O
causality	B-Application
makes	O
attempts	O
to	O
schedule	O
actions	O
in	O
the	O
past	O
meaningless	O
.	O
</s>
<s>
In	O
Dijkstra	B-Algorithm
's	I-Algorithm
algorithm	I-Algorithm
for	O
the	O
shortest	O
path	O
problem	O
,	O
vertices	O
of	O
a	O
given	O
weighted	O
graph	O
are	O
extracted	O
in	O
increasing	O
order	O
by	O
their	O
distance	O
from	O
the	O
starting	O
vertex	O
,	O
and	O
a	O
priority	B-Application
queue	I-Application
is	O
used	O
to	O
determine	O
the	O
closest	O
remaining	O
vertex	O
to	O
the	O
starting	O
vertex	O
.	O
</s>
<s>
Therefore	O
,	O
in	O
this	O
application	O
,	O
the	O
priority	B-Application
queue	I-Application
operations	O
are	O
monotonic	O
.	O
</s>
<s>
Similarly	O
,	O
in	O
sweep	B-Algorithm
line	I-Algorithm
algorithms	I-Algorithm
in	O
computational	O
geometry	O
,	O
events	O
at	O
which	O
the	O
sweep	B-Algorithm
line	I-Algorithm
crosses	O
a	O
point	O
of	O
interest	O
are	O
prioritized	O
by	O
the	O
coordinate	O
of	O
the	O
crossed	O
point	O
,	O
and	O
these	O
events	O
are	O
extracted	O
in	O
monotonic	O
ordering	O
.	O
</s>
<s>
A	O
monotonic	O
extraction	O
order	O
also	O
occurs	O
in	O
the	O
best-first	B-Algorithm
version	O
of	O
branch	B-Algorithm
and	I-Algorithm
bound	I-Algorithm
.	O
</s>
<s>
Any	O
priority	B-Application
queue	I-Application
that	O
can	O
handle	O
non-monotone	O
extraction	O
operations	O
can	O
also	O
handle	O
monotone	O
extractions	O
,	O
but	O
some	O
priority	B-Application
queues	I-Application
are	O
specialized	O
to	O
work	O
only	O
for	O
monotone	O
extractions	O
or	O
work	O
better	O
when	O
the	O
extractions	O
are	O
monotone	O
.	O
</s>
<s>
For	O
instance	O
,	O
the	O
bucket	B-Application
queue	I-Application
is	O
a	O
simple	O
priority	B-Application
queue	I-Application
data	O
structure	O
consisting	O
of	O
an	O
array	O
indexed	O
by	O
priority	O
,	O
where	O
each	O
array	O
cell	O
contains	O
a	O
bucket	O
of	O
items	O
with	O
that	O
priority	O
.	O
</s>
<s>
An	O
extract-min	O
operation	O
performs	O
a	O
sequential	B-Algorithm
search	I-Algorithm
for	O
the	O
first	O
non-empty	O
bucket	O
and	O
chooses	O
an	O
arbitrary	O
item	O
in	O
that	O
bucket	O
.	O
</s>
<s>
However	O
,	O
when	O
used	O
as	O
a	O
monotone	B-Application
priority	I-Application
queue	I-Application
,	O
the	O
search	O
for	O
the	O
next	O
non-empty	O
bucket	O
can	O
begin	O
at	O
the	O
priority	O
of	O
the	O
most	O
recent	O
previous	O
extract-min	O
operation	O
rather	O
than	O
at	O
the	O
start	O
of	O
the	O
array	O
.	O
</s>
<s>
describe	O
a	O
more	O
complicated	O
scheme	O
called	O
a	O
Heap-on-top	O
(	O
HOT	O
)	O
queue	O
for	O
monotone	B-Application
priority	I-Application
queues	I-Application
with	O
integer	O
priorities	O
,	O
based	O
on	O
multilevel	O
bucketing	O
together	O
with	O
a	O
conventional	O
heap	O
priority	B-Application
queue	I-Application
.	O
</s>
<s>
The	O
hot	O
queue	O
uses	O
constant	O
time	O
per	O
insertion	O
or	O
decrease-priority	O
operation	O
and	O
amortized	B-General_Concept
time	I-General_Concept
per	O
extract-min	O
operation	O
.	O
</s>
<s>
Another	O
related	O
structure	O
of	O
allows	O
the	O
priorities	O
to	O
be	O
machine	O
integers	O
,	O
and	O
again	O
allows	O
constant-time	O
insertion	O
and	O
decrease-priority	O
operations	O
,	O
with	O
extract-min	O
operations	O
on	O
a	O
priority	B-Application
queue	I-Application
of	O
items	O
taking	O
amortized	B-General_Concept
time	I-General_Concept
.	O
</s>
<s>
These	O
results	O
lead	O
to	O
a	O
corresponding	O
speedup	O
in	O
Dijkstra	B-Algorithm
's	I-Algorithm
algorithm	I-Algorithm
for	O
graphs	O
with	O
integer	O
edge	O
weights	O
.	O
</s>
