Skip to content
Fetching contributors…
Cannot retrieve contributors at this time
115 lines (94 sloc) 5.41 KB

Clever Algorithms: Nature-Inspired Programming Recipes


Clever Algorithms: Nature-Inspired Programming Recipes is an open source book that describes a large number of algorithmic techniques from the the fields of Biologically Inspired Computation, Computational Intelligence and Metaheuristics in a complete, consistent, and centralized manner such that they are accessible, usable, and understandable. This is a repository for the book project used during the development and ongoing maintenance of the books’ content.

The book was first released in early 2011 for free on the website and is available for purchase as a paperback from Amazon and Lulu

Book Details

Title Clever Algorithms: Nature-Inspired Programming Recipes
Author Jason Brownlee
Release Revision 2. 16th June 2012


Implementing an Artificial Intelligence algorithm is difficult. Algorithm descriptions may be incomplete, inconsistent, and distributed across a number of papers, chapters and even websites. This can result in varied interpretations of algorithms, undue attrition of algorithms, and ultimately bad science. This book is an effort to address these issues by providing a handbook of algorithmic recipes drawn from the fields of Metaheuristics, Biologically Inspired Computation and Computational Intelligence, described in a complete, consistent, and centralized manner. These standardized descriptions were carefully designed to be accessible, usable, and understandable. Most of the algorithms described were originally inspired by biological and natural systems, such as the adaptive capabilities of genetic evolution and the acquired immune system, and the foraging behaviors of birds, bees, ants and bacteria. An encyclopedic algorithm reference, this book is intended for research scientists, engineers, students, and interested amateurs. Each algorithm description provides a working code example in the Ruby Programming Language.

Table of Contents

  1. Background
    1. Introduction
  2. Algorithms
    1. Stochastic Algorithms
      1. Random Search
      2. Adaptive Random Search
      3. Stochastic Hill Climbing
      4. Iterated Local Search
      5. Guided Local Search
      6. Variable Neighborhood Search
      7. Greedy Randomized Adaptive Search
      8. Scatter Search
      9. Tabu Search
      10. Reactive Tabu Search
    2. Evolutionary Algorithms
      1. Genetic Algorithm
      2. Genetic Programming
      3. Evolution Strategies
      4. Differential Evolution
      5. Evolutionary Programming
      6. Grammatical Evolution
      7. Gene Expression Programming
      8. Learning Classifier System
      9. Non-dominated Sorting Genetic Algorithm
      10. Strength Pareto Evolutionary Algorithm
    3. Physical Algorithms
      1. Simulated Annealing
      2. Extremal Optimization
      3. Harmony Search
      4. Cultural Algorithm
      5. Memetic Algorithm
    4. Probabilistic Algorithms
      1. Population-Based Incremental Learning
      2. Univariate Marginal Distribution Algorithm
      3. Compact Genetic Algorithm
      4. Bayesian Optimization Algorithm
      5. Cross-Entropy Method
    5. Swarm Algorithms
      1. Particle Swarm Optimization
      2. Ant System
      3. Ant Colony System
      4. Bees Algorithm
      5. Bacterial Foraging Optimization Algorithm
    6. Immune Algorithms
      1. Clonal Selection Algorithm
      2. Negative Selection Algorithm
      3. Artificial Immune Recognition System
      4. Immune Network Algorithm
      5. Dendritic Cell Algorithm
    7. Neural Algorithms
      1. Perceptron
      2. Back-propagation
      3. Hopfield Network
      4. Learning Vector Quantization
      5. Self-Organizing Map
  3. Extensions
    1. Advanced Topics
      1. Programming Paradigms
      2. Devising New Algorithms
      3. Testing Algorithms
      4. Visualizing Algorithms
      5. Problem Solving Strategies
      6. Benchmarking Algorithms
  4. Appendix A – Ruby: Quick-Start Guide


How to Build

  1. Assumes a Linux or Mac workstation with make, Latex such as TeXLive or MacTex installed and maybe JabRef
  2. git clone
  3. cd CleverAlgorithms
  4. make r (creates the file book/book.pdf)
  5. make vl (to view the PDF on linux) or make vm (to view the PDF on mac)
  6. make epub (creates epub versions)


If you find a typo or a mistake, please email me at or clone this project and make, make a change and submit a pull request. I will happily give you credit in the acknowledgments.


The best support you can give to this project is to buy a copy of the paperback and spread the word by writing a review, blog post or tweet.


© Copyright 2013 Jason Brownlee. Some Rights Reserved.
This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 2.5 Australia License.

Creative Commons License

Something went wrong with that request. Please try again.