Heuristic algorithms
What Are Heuristic Algorithms?
Heuristic algorithms are problem-solving procedures that find good-quality solutions to computationally hard problems through guided search strategies, accepting approximate rather than provably optimal results in exchange for practical runtime. The term "heuristic" derives from the Greek word for "to find" or "to discover," and in the context of algorithms it denotes a method that uses problem-specific knowledge or analogical reasoning to direct the search toward promising regions of a solution space without exhaustively examining every candidate. Heuristic algorithms are applied most widely to combinatorial optimization problems, where the number of possible solutions grows exponentially with problem size and exact methods become computationally prohibitive.
The field draws on operations research, artificial intelligence, and theoretical computer science. Problems such as the traveling salesman problem, vehicle routing, and job-shop scheduling are NP-hard, meaning no polynomial-time exact algorithm is known for them. Heuristics address this gap by trading the guarantee of optimality for solutions that are good enough in practice. A foundational treatment of metaheuristics in combinatorial optimization, published by Blum and Roli in ACM Computing Surveys, distinguishes between simple heuristics tuned to a specific problem instance and the higher-level metaheuristic frameworks designed to guide any subordinate heuristic across a broad class of problems.
Construction and Local Search Heuristics
Construction heuristics build a solution incrementally, adding one component at a time according to a greedy rule. The nearest-neighbor heuristic for the traveling salesman problem, for example, always extends a partial tour by visiting the closest unvisited city. Construction heuristics are fast and produce a feasible solution in a single pass, but greedy choices made early can commit to poor partial solutions that cannot be undone. Local search heuristics address this by starting from a complete solution and iteratively replacing it with a neighboring solution of lower cost, where neighbors are defined by a move operator such as swapping two cities in a tour or reassigning a job to a different machine. Pure local search terminates at a local optimum, which may be far from the global optimum. The Cornell Computational Optimization textbook on heuristic algorithms surveys both construction and local search strategies and their behavior on benchmark instances.
Metaheuristic Frameworks
Metaheuristics are algorithm templates that apply general strategies to escape local optima and explore the solution space more broadly. Simulated annealing, introduced by Kirkpatrick and colleagues in 1983, accepts worse solutions with a probability that decreases according to a cooling schedule, allowing occasional uphill moves that escape local traps. Tabu search maintains a short-term memory of recently visited solutions and forbids returning to them, forcing diversification. Genetic algorithms maintain a population of candidate solutions and apply selection, crossover, and mutation operators inspired by biological evolution to generate new candidates. Ant colony optimization, developed by Marco Dorigo in the 1990s, has populations of agents deposit pheromone trails on solution components, reinforcing paths that appear in high-quality solutions. A survey of metaheuristic algorithms for optimization identifies intensification and diversification as the two fundamental forces in any metaheuristic: intensification refines promising solutions, while diversification prevents the search from stagnating in a single region of the space.
Applications
Heuristic algorithms have applications in a range of fields, including:
- Vehicle routing and logistics for delivery fleet optimization
- Job-shop scheduling in manufacturing and cloud computing resource allocation
- Network design and telecommunications routing under capacity constraints
- VLSI circuit placement and routing in electronic design automation
- Protein structure prediction and bioinformatics sequence alignment