The.Algorithm.Design.Manual.Springer-Verlag.1998
The.Algorithm.Design.Manual.Springer-Verlag.1998 The.Algorithm.Design.Manual.Springer-Verlag.1998
Data Structures ● Priority Queues ● Suffix Trees and Arrays ● Graph Data Structures ● Set Data Structures ● Kd-Trees Next: Dictionaries Up: A Catalog of Algorithmic Previous: Caveats Algorithms Mon Jun 2 23:33:50 EDT 1997 file:///E|/BOOK/BOOK3/NODE128.HTM (2 of 2) [19/1/2003 1:30:01]
Dictionaries Next: Priority Queues Up: Data Structures Previous: Data Structures Dictionaries Input description: A set of n records, each identified by one or more key fields. Problem description: Build and maintain a data structure to efficiently locate, insert, or delete the record associated with any query key q. Discussion: The abstract data type ``dictionary'' is one of the most important structures in computer science. Dozens of different data structures have been proposed for implementing dictionaries including hash tables, skip lists, and balanced/unbalanced binary search trees - so choosing the right one can be tricky. Depending on the application, it is also a decision that can significantly impact performance. In practice, it is more important to avoid using a bad data structure than to identify the single best option available. An essential piece of advice is to carefully isolate the implementation of the dictionary data structure from its interface. Use explicit calls to subroutines that initialize, search, and modify the data structure, rather than embedding them within the code. This leads to a much cleaner program, but it also makes it easy to try different dictionary implementations to see how they impact performance. Do not obsess about the cost of the procedure call overhead inherent in such an abstraction. If your application is so time-critical that such overhead can impact performance, then it is even more essential that you be able to file:///E|/BOOK/BOOK3/NODE129.HTM (1 of 5) [19/1/2003 1:30:03]
- Page 295 and 296: War Story: Annealing Arrays Next: P
- Page 297 and 298: War Story: Annealing Arrays optimal
- Page 299 and 300: Parallel Algorithms Next: War Story
- Page 301 and 302: War Story: Going Nowhere Fast Next:
- Page 303 and 304: Exercises Next: Implementation Chal
- Page 305 and 306: Problems and Reductions Next: Simpl
- Page 307 and 308: Simple Reductions Next: Hamiltonian
- Page 309 and 310: Hamiltonian Cycles Next: Independen
- Page 311 and 312: Independent Set and Vertex Cover pr
- Page 313 and 314: Clique and Independent Set These la
- Page 315 and 316: Satisfiability Mon Jun 2 23:33:50 E
- Page 317 and 318: The Theory of NP-Completeness Next:
- Page 319 and 320: 3-Satisfiability where for , , , an
- Page 321 and 322: Integer Programming Next: Vertex Co
- Page 323 and 324: Integer Programming possible IP ins
- Page 325 and 326: Vertex Cover reduction for the 3-SA
- Page 327 and 328: Other NP-Complete Problems hard. Th
- Page 329 and 330: The Art of Proving Hardness easiest
- Page 331 and 332: War Story: Hard Against the Clock N
- Page 333 and 334: War Story: Hard Against the Clock I
- Page 335 and 336: Approximation Algorithms Next: Appr
- Page 337 and 338: Approximating Vertex Cover Next: Th
- Page 339 and 340: The Euclidean Traveling Salesman Ne
- Page 341 and 342: The Euclidean Traveling Salesman Ne
- Page 343 and 344: Exercises 1. Prove that the low deg
- Page 345: Data Structures Next: Dictionaries
- Page 349 and 350: Dictionaries use a function that ma
- Page 351 and 352: Dictionaries Implementation-oriente
- Page 353 and 354: Priority Queues ● Besides access
- Page 355 and 356: Priority Queues Fibonacci heaps [FT
- Page 357 and 358: Suffix Trees and Arrays Figure: A t
- Page 359 and 360: Suffix Trees and Arrays [GBY91]. Se
- Page 361 and 362: Graph Data Structures algorithms).
- Page 363 and 364: Graph Data Structures including the
- Page 365 and 366: Set Data Structures Next: Kd-Trees
- Page 367 and 368: Set Data Structures parent pointers
- Page 369 and 370: Kd-Trees Next: Numerical Problems U
- Page 371 and 372: Kd-Trees about p. Say we are lookin
- Page 373 and 374: Numerical Problems Next: Solving Li
- Page 375 and 376: Numerical Problems Mon Jun 2 23:33:
- Page 377 and 378: Solving Linear Equations algorithm
- Page 379 and 380: Solving Linear Equations Matrix inv
- Page 381 and 382: Bandwidth Reduction images near eac
- Page 383 and 384: Matrix Multiplication Next: Determi
- Page 385 and 386: Matrix Multiplication The linear al
- Page 387 and 388: Determinants and Permanents Next: C
- Page 389 and 390: Determinants and Permanents exposit
- Page 391 and 392: Constrained and Unconstrained Optim
- Page 393 and 394: Constrained and Unconstrained Optim
- Page 395 and 396: Linear Programming variable assignm
Dictionaries<br />
Next: Priority Queues Up: Data Structures Previous: Data Structures<br />
Dictionaries<br />
Input description: A set of n records, each identified by one or more key fields.<br />
Problem description: Build and maintain a data structure to efficiently locate, insert, or delete the record<br />
associated with any query key q.<br />
Discussion: <strong>The</strong> abstract data type ``dictionary'' is one of the most important structures in computer<br />
science. Dozens of different data structures have been proposed for implementing dictionaries including<br />
hash tables, skip lists, and balanced/unbalanced binary search trees - so choosing the right one can be<br />
tricky. Depending on the application, it is also a decision that can significantly impact performance. In<br />
practice, it is more important to avoid using a bad data structure than to identify the single best option<br />
available.<br />
An essential piece of advice is to carefully isolate the implementation of the dictionary data structure<br />
from its interface. Use explicit calls to subroutines that initialize, search, and modify the data structure,<br />
rather than embedding them within the code. This leads to a much cleaner program, but it also makes it<br />
easy to try different dictionary implementations to see how they impact performance. Do not obsess<br />
about the cost of the procedure call overhead inherent in such an abstraction. If your application is so<br />
time-critical that such overhead can impact performance, then it is even more essential that you be able to<br />
file:///E|/BOOK/BOOK3/NODE129.HTM (1 of 5) [19/1/2003 1:30:03]