liveBook · Manning

Average-case hardness

As explained in Advanced Algorithms and Data Structures

Average-case hardness is the difficulty of solving problem instances according to a specified typical or practical input distribution.

Average-case hardness measures how difficult a problem is on the instances encountered in practical scenarios, rather than on its hardest possible inputs. This distinction explains why heuristics can be useful even when worst-case guarantees are discouraging. section 16.1.1

Use the concept to guide algorithm choices:

  • Accept a suboptimal answer when obtaining a useful result quickly matters more than guaranteeing the optimum. section 16.1.1
  • Distinguish rare hard edge cases from the typical inputs produced by real applications. section 16.1.1
  • Prefer heuristics with proven accuracy bounds when available. section 16.1.1

Graph embedding

Randomly assign graph vertices to positions, reject invalid embeddings, count edge intersections, and retain the valid arrangement with the fewest crossings. Repeated sampling may work well in practice without guaranteeing the optimum. section 16.1.1

How Advanced Algorithms and Data Structures covers it

How deep it goes
Contrasts worst-case NP-hardness with practical input difficulty and stops short of formal distributional analysis.
Examples
Uses traveling salesman, maximum clique, and graph-embedding heuristics as concrete optimization examples.
What it assumes
Assumes familiarity with optimization problems, NP-hardness, heuristics, and graph algorithms.
What you can do after
Evaluate/understand when a heuristic can solve real-world instances effectively despite lacking an all-input optimality guarantee.
How it connects
Connects NP-hardness, heuristics, approximate algorithms, graph algorithms, traveling salesman problem, clique, and graph embedding.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Advanced Algorithms and Data Structures. The section links point to the parts of the book it draws on.