page368.html
来自「Data Structures And Algorithms With Obje」· HTML 代码 · 共 45 行
HTML
45 行
<HTML><HEAD><TITLE>Binomial Queues</TITLE></HEAD><BODY bgcolor="#FFFFFF"> <a href="../index.html" target="_top"><img src="../icons/usins.gif" alt="Logo" align=right></a><b>Data Structures and Algorithms with Object-Oriented Design Patterns in Python</b><br><A NAME="tex2html5424" HREF="page369.html"><IMG WIDTH=37 HEIGHT=24 ALIGN=BOTTOM ALT="next" SRC="../icons/next_motif.gif"></A> <A NAME="tex2html5422" HREF="page351.html"><IMG WIDTH=26 HEIGHT=24 ALIGN=BOTTOM ALT="up" SRC="../icons/up_motif.gif"></A> <A NAME="tex2html5416" HREF="page367.html"><IMG WIDTH=63 HEIGHT=24 ALIGN=BOTTOM ALT="previous" SRC="../icons/previous_motif.gif"></A> <A NAME="tex2html5426" HREF="page611.html"><IMG WIDTH=43 HEIGHT=24 ALIGN=BOTTOM ALT="index" SRC="../icons/index_motif.gif"></A> <BR><HR><H1><A NAME="SECTION0011400000000000000000">Binomial Queues</A></H1><P>A binomial queue is a priority queue that is implemented not as a single treebut as a collection of heap-ordered trees.A collection of trees is called a <em>forest</em><A NAME=26010> </A>.Each of the trees in a binomial queue has a very special shapecalled a binomial tree.Binomial trees are general trees.That is, the maximum degree of a node is not fixed.<P>The remarkable characteristic of binomial queues is thatthe merge operation is similar in structure to binary addition.That is, the collection of binomial trees that make up the binomial queueis like the set of bits that make up the binary representation of anon-negative integer.Furthermore, the merging of two binomial queues is done byadding the binomial trees that make up that queue in the sameway that the bits are combined when adding two binary numbers.<P><BR> <HR><UL> <LI> <A NAME="tex2html5427" HREF="page369.html#SECTION0011410000000000000000">Binomial Trees</A><LI> <A NAME="tex2html5428" HREF="page370.html#SECTION0011420000000000000000">Binomial Queues</A><LI> <A NAME="tex2html5429" HREF="page371.html#SECTION0011430000000000000000">Implementation</A><LI> <A NAME="tex2html5430" HREF="page378.html#SECTION0011440000000000000000">Merging Binomial Queues</A><LI> <A NAME="tex2html5431" HREF="page379.html#SECTION0011450000000000000000">Putting Items into a Binomial Queue</A><LI> <A NAME="tex2html5432" HREF="page380.html#SECTION0011460000000000000000">Removing an Item from a Binomial Queue</A></UL><HR><A NAME="tex2html5424" HREF="page369.html"><IMG WIDTH=37 HEIGHT=24 ALIGN=BOTTOM ALT="next" SRC="../icons/next_motif.gif"></A> <A NAME="tex2html5422" HREF="page351.html"><IMG WIDTH=26 HEIGHT=24 ALIGN=BOTTOM ALT="up" SRC="../icons/up_motif.gif"></A> <A NAME="tex2html5416" HREF="page367.html"><IMG WIDTH=63 HEIGHT=24 ALIGN=BOTTOM ALT="previous" SRC="../icons/previous_motif.gif"></A> <A NAME="tex2html5426" HREF="page611.html"><IMG WIDTH=43 HEIGHT=24 ALIGN=BOTTOM ALT="index" SRC="../icons/index_motif.gif"></A> <P><ADDRESS><img src="../icons/bruno.gif" alt="Bruno" align=right><a href="../copyright.html">Copyright © 2003</a> by <a href="../signature.html">Bruno R. Preiss, P.Eng.</a> All rights reserved.</ADDRESS></BODY></HTML>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?