Bitbucket is a code hosting site with unlimited public and private repositories. We're also free for small teams!

Close

Brainless

This is the homepage of Brainless, an xboard-based C++ chess engine written by Matthew Lai and Wieland Belka with contributions from Pawel Koziol (evaluation function). It is a standard bitboard based alpha-beta searcher implementing well-known algorithms.

The program is licensed under the GNU General Public License (GPL), meaning you have the right to do pretty much anything with it (use, modify, redistribute, and even make a profit out of it) as long as your derivative work is also under the GPL (specifically, it must also be open-sourced). You are not required to get my permission or even let me know if you make a derivative of it, but it would certainly be nice to let me know. Also, if you do base your program on mine, I would appreciate it if you do not participate in tournaments and such as I will be entering Brainless myself (clones and close-derivatives are usually not welcomed in tournaments anyways).

It is currently playing on FICS under the handle BrainlessChess(C) and has a standard rating of ~2300 and blitz rating of ~2200. Feel free to log on to FICS and give it a try.

I developed the program under GNU/Linux, but it also works under Windows (using the MinGW or ICC compiler). It runs about twice as fast on a 64-bit system (running a 64-bit binary obviously) due to the extensive use of bitboards. The only requirement for compilation, aside from the standard library, is the Boost library (used for threading in pondering).

Feature List

  • Alpha-beta (negamax)
  • Quiescence search considering only captures and promotions
  • Rotated bitboards move generation (pioneered by Dr. Robert Hyatt, author of Crafty, and Heinz, of DarkThought)
  • Aspiration search (0.3 pawn) on root
  • Internal iterative deepening
  • Principal variation search
  • Late move reduction
  • Transposition table
  • Pawn hash table
  • Static exchange evaluation (SEE)
  • Adaptive null move prunning (R=2 + depth >= 7)
  • Killer moves
  • Check extension
  • A basic opening book converted from the Beowolf book (many thanks!)
  • Pondering by thinking as the opponent (filling up the transposition table)
  • The evaluation function, written by Wieland Belka, with contributions from Pawel Koziol, consists mainly of material, piece-square table, pawn structure, king safety and some pattern recognition
  • Configuration file

TODO

  • Improved evaluation function
  • EGTB
  • Parallel searching (probably never =) )

Recent activity

Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.