-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
fc_botelho
committed
Jan 31, 2005
1 parent
8401ce6
commit 4951ded
Showing
13 changed files
with
738 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
Minimal Perfect Hash Functions - Introduction | ||
|
||
|
||
%!includeconf: CONFIG.t2t | ||
|
||
---------------------------------------- | ||
==Basic Concepts== | ||
|
||
Suppose [figs/img14.png] is a universe of //keys//. | ||
Let [figs/img15.png] be a //hash function// that maps the keys from [figs/img14.png] to a given interval of integers [figs/img16.png]. | ||
Let [figs/img17.png] be a set of [figs/img8.png] keys from [figs/img14.png]. | ||
Given a key [figs/img18.png], the hash function [figs/img7.png] computes an | ||
integer in [figs/img19.png] for the storage or retrieval of [figs/img11.png] in | ||
a //hash table//. | ||
Hashing methods for //non-static sets// of keys can be used to construct | ||
data structures storing [figs/img20.png] and supporting membership queries | ||
"[figs/img18.png]?" in expected time [figs/img21.png]. | ||
However, they involve a certain amount of wasted space owing to unused | ||
locations in the table and waisted time to resolve collisions when | ||
two keys are hashed to the same table location. | ||
|
||
For //static sets// of keys it is possible to compute a function | ||
to find any key in a table in one probe; such hash functions are called | ||
//perfect//. | ||
More precisely, given a set of keys [figs/img20.png], we shall say that a | ||
hash function [figs/img15.png] is a //perfect hash function// | ||
for [figs/img20.png] if [figs/img7.png] is an injection on [figs/img20.png], | ||
that is, there are no //collisions// among the keys in [figs/img20.png]: | ||
if [figs/img11.png] and [figs/img22.png] are in [figs/img20.png] and [figs/img23.png], | ||
then [figs/img24.png]. | ||
Figure 1(a) illustrates a perfect hash function. | ||
Since no collisions occur, each key can be retrieved from the table | ||
with a single probe. | ||
If [figs/img25.png], that is, the table has the same size as [figs/img20.png], | ||
then we say that [figs/img7.png] is a //minimal perfect hash function// | ||
for [figs/img20.png]. | ||
Figure 1(b) illustrates a minimal perfect hash function. | ||
Minimal perfect hash functions totally avoid the problem of wasted | ||
space and time. A perfect hash function [figs/img7.png] is //order preserving// | ||
if the keys in [figs/img20.png] are arranged in some given order | ||
and [figs/img7.png] preserves this order in the hash table. | ||
|
||
| [figs/img26.png] | ||
| **Figure 1:** (a) Perfect hash function. (b) Minimal perfect hash function. | ||
|
||
Minimal perfect hash functions are widely used for memory efficient | ||
storage and fast retrieval of items from static sets, such as words in natural | ||
languages, reserved words in programming languages or interactive systems, | ||
universal resource locations (URLs) in Web search engines, or item sets in | ||
data mining techniques. | ||
|
||
---------------------------------------- | ||
| [Home index.html] | [CHM chm.html] | [BMZ bmz.html] | ||
---------------------------------------- | ||
|
||
%!include: FOOTER.t2t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,46 @@ | ||
%! style(html): DOC.css | ||
%! PreProc(html): '^%html% ' '' | ||
%! PreProc(txt): '^%txt% ' '' | ||
%! PostProc(html): "&" "&" | ||
%! PostProc(txt): " " " " | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img7.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img7.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img57.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img57.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img32.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img32.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img20.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img20.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img60.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img60.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img62.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img62.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img79.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img79.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img139.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img139.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img140.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img140.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img143.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img143.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img115.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img115.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img11.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img11.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img169.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img169.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img96.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img96.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img178.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img178.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img180.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img180.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img183.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img183.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img189.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img189.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img196.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img196.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img172.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img172.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img8.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img8.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img1.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img1.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img14.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img14.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img128.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img128.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img112.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img112.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img12.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img12.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img13.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img13.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img244.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img244.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img245.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img245.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img246.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img246.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img15.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img15.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img25.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img25.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img168.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img168.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img6.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img6.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img5.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img5.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img28.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img28.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img237.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img237.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img248.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img237.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img248.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img237.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img249.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img249.png"\1>' | ||
%! PostProc(html): 'ALIGN="middle" SRC="figs/img250.png"(.*?)>' 'ALIGN="bottom" SRC="figs/img250.png"\1>' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
/* implement both fixed-size and relative sizes */ | ||
SMALL.XTINY { } | ||
SMALL.TINY { } | ||
SMALL.SCRIPTSIZE { } | ||
BODY { font-size: 13 } | ||
TD { font-size: 13 } | ||
SMALL.FOOTNOTESIZE { font-size: 13 } | ||
SMALL.SMALL { } | ||
BIG.LARGE { } | ||
BIG.XLARGE { } | ||
BIG.XXLARGE { } | ||
BIG.HUGE { } | ||
BIG.XHUGE { } | ||
|
||
/* heading styles */ | ||
H1 { } | ||
H2 { } | ||
H3 { } | ||
H4 { } | ||
H5 { } | ||
|
||
|
||
/* mathematics styles */ | ||
DIV.displaymath { } /* math displays */ | ||
TD.eqno { } /* equation-number cells */ | ||
|
||
|
||
/* document-specific styles come next */ | ||
DIV.navigation { } | ||
DIV.center { } | ||
SPAN.textit { font-style: italic } | ||
SPAN.arabic { } | ||
SPAN.eqn-number { } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<a href="http://sourceforge.net"><img src="http://sourceforge.net/sflogo.php?group_id=96251&type=1" width="88" height="31" border="0" alt="SourceForge.net Logo" /> </a> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.