Skip to main content

Questions tagged [chess-algorithms]

For questions about algorithms used in computer chess software.

Filter by
Sorted by
Tagged with
1 vote
0 answers
156 views

Why is my negamax/quiescence search slow?

I'm currently making a chess engine in Java and my search function is extremely slow to the point that it's slower than my perft function. My search function is currently a negamax search that uses ...
wdk23's user avatar
  • 90
4 votes
1 answer
397 views

A different hashing algorithm for chess positions

This is not a question, it is a curious discovery I wanted to share The most common hashing algorithm in chess programming is, I believe, Zobrist hashing. However, I may have found a different way of ...
Grande Dorgas's user avatar
1 vote
1 answer
287 views

Help with Negamax using transposition table

I've recently been improving my Negamax algorithm for chess, adding a transposition table. The algorithm was working well before this addition. After this addition I can't see no big improvements in ...
SKAE's user avatar
  • 11
1 vote
2 answers
114 views

Does a reinforcement learning style model actually need to be combined with a search algo to produce the best moves?

I have recently been studying up on Machine Learning based chess engines and have begun to develop one of my own. I was wondering, realistically, doesn't the board technically contain all of the data ...
OldAmmo's user avatar
  • 19
14 votes
2 answers
4k views

Which methods can be used to prove that a position is illegal?

Given a board position, there are programs that try to find a series of legal moves that lead to it. Are there algorithms that can do the opposite - prove that the position is not reachable by a ...
2080's user avatar
  • 936
4 votes
1 answer
959 views

Chess Engine Using LazySMP

I was hoping to parallelize the chess engine I was currently working on. I have done some research on some of the various types of algorithms such as YBWC, ABDADA, and LazySMP which is currently used ...
Freddy-FazBear's user avatar
26 votes
4 answers
7k views

Given a legal chess position, is there an algorithm that generates a series of moves that lead to it?

Given a FEN board position, is there an algorithm that can return a PGN move list that evaluates to it from the standard initial position?
2080's user avatar
  • 936
11 votes
1 answer
2k views

Why does a chess engine not get excited about a piece exchange at the end of its analysis depth?

I read about the chess engine algorithms and came up with a question. If, for example roughly all (disregarding alpha-beta pruning) possible 20 moves variations are calculated, why does a chess ...
Nick's user avatar
  • 121
6 votes
1 answer
512 views

Comparison of tactics trainers

I've noticed that the nature of the tactics differ from one website to another. For instance, on lichess.org/training (the website which I train tactics the most on), I have noticed that tactics ...
Emilio Ferrucci's user avatar
0 votes
1 answer
528 views

How to make a chess engine that can identify tactics in the position?

I want to make a program that can identify chess tactics in the position, while searching moves according to given heuristics. but I am not sure exactly how to go about this. Related to this Is there ...
eguneys's user avatar
  • 473
14 votes
2 answers
3k views

How do chess engines decide which best line to play when the game outcome is within their horizon?

Inspired by the Hot Network Question "In this puzzle, why does white play dxe5?", when a chess engine is in a position that it can definitively call lost, drawn, or won, what policy is used to decide ...
which-line's user avatar
12 votes
3 answers
34k views

Average centipawn loss

I had no inacurracies, blunders or mistakes then also my centipawn loss was 48, or 50. What is the problem here or I have misunderstood average centipawn loss. You can have a look at that game at ...
Amar Shukla's user avatar
3 votes
2 answers
813 views

How does Allie's search algorithm work?

Allie is a strong engine that's looking competitive with the top ones (Leela Chess Zero and Stockfish). It's supposedly based off AlphaZero, but works differently. As far as I understand it, the most ...
Allure's user avatar
  • 29k
15 votes
6 answers
3k views

Is the dead position problem solvable?

In chess, there are some dead positions (FIDE Laws of Chess). 5.2.2 The game is drawn when a position has arisen in which neither player can checkmate the opponent’s king with any series of legal ...
user avatar
2 votes
2 answers
7k views

Swiss Pairing Algorithm

I am building a simple Android application for hosting Chess tournaments, I am having some difficulty implementing a Swiss paring algorithm, I need link to an article or a paper that explains how I ...
oziomajnr's user avatar
  • 517
12 votes
4 answers
2k views

When checkmate is impossible in a position

The laws of chess say 1.5. If the position is such that neither player can possibly checkmate the opponent’s king, the game is drawn (see Article 5.2.2). 5.2.2. The game is drawn when a position has ...
usul's user avatar
  • 347
7 votes
3 answers
2k views

How can minimax chess engines do alpha-beta pruning without reaching the final positions?

In order to calculate far ahead, minimax chess engines must perform alpha-beta pruning, where they don't calculate positions that are obviously winning or obviously losing. Without doing pruning, ...
Inertial Ignorance's user avatar
5 votes
1 answer
4k views

Is Deep Blue outdated?

I bought a laptop, a Dell, model XPS 13. I found a technical review which mentioned the Fritz test: Fritz is a chess benchmark that tests the computing capabilities of the CPU with various chess ...
trocchietto's user avatar
34 votes
8 answers
18k views

If given infinite processing power, is there an algorithm that would play chess perfectly?

Does there exist such an algorithm where, if given infinite processing power, a computer could play chess perfectly, i.e., it can generate perfect moves from any position? If so, where can I find the ...
Jonah's user avatar
  • 467
8 votes
3 answers
1k views

Lecture/Book on AlphaGo/AlphaZero

I am very interested in how AlphaGo resp. AlphaZero works. It seems to me, the related Google Papers are very dense and not easy to read. Is there any textbook or lecture that explains on a technical ...
ndbd's user avatar
  • 571
5 votes
1 answer
1k views

Calculation for game phase

What is the best or alternative ways to detect game phase by a chess AI? What is a good algorithm to use? Chess programming wiki says to count material or pieces? What would be the expected piece or ...
Νικόλαος Μανωλακος's user avatar
0 votes
1 answer
164 views

What does the sign of the score represent in chess engines?

I am trying to code a small chess engine, but I am confused with what the sign of the score means. This is my current minimax algorithm: INFINITY = 999999 def minimax(self, depth, color): if ...
Legoboy's user avatar
19 votes
5 answers
2k views

How did the engines improve since Deep Blue?

Computer chess engines have gotten better since Deep Blue beat Kasparov in 1997. Did the algorithms get better, or were the improvements mostly due to the same algorithms running faster thanks to ...
MWB's user avatar
  • 483
5 votes
1 answer
2k views

What is alternative to Zobrist hashing?

Zobrist hashing is very good method save position but it is not good to read position - is any good alternative to this algorithm which allow to store and restore position with minimum of bits. For ...
Chameleon's user avatar
  • 525
18 votes
3 answers
6k views

How do I learn Chess Programming?

Basically I have seen that people write a lot of chess algorithms, and ask questions in this forum, which I fumble to answer appropriately. I see the code, but unable to make out whether it is correct ...
Seth Projnabrata's user avatar
0 votes
3 answers
3k views

My chess AI makes the same repeated moves

I've built a chess game engine using Minimax and when I play AI against the AI, everything goes fine(for sometime) until both the AI players make the same set of moves again and again. Observe the ...
Srikara Krishna Kanduri's user avatar
3 votes
1 answer
162 views

How do you implement Alpha-Beta search when you can only compare 2 positions to each other?

In their paper about DeepChess, http://www.cs.tau.ac.il/~wolf/papers/deepchess.pdf, David et al show a cool way to train a net to play chess. I've trained my net to some degree of success and I want ...
Dan's user avatar
  • 31
2 votes
3 answers
1k views

Search Algorithms used by top engines?

what are the top parallel search algorithms used by top engines ,and which one is the best ? And is there a reference implementation of them in any programming language ? I know most of the top ...
user8501's user avatar
4 votes
3 answers
1k views

Chess Statistics How to?

I am a graduate student studying statistics and I play chess once in a while for fun. I was thinking (just for the fun of it) -- applying some of what I've learned in statistics to chess games: I ...
user1172468's user avatar
9 votes
1 answer
763 views

How does timeseal work? [closed]

I know the the fics (free internet chess server: www.freechess.org/) does use a program called timeseal to measure the time that a user needed to take a move. This timeseal is some time measurement on ...
Simon Meyer's user avatar
9 votes
7 answers
5k views

Is there a chess engine that does NOT use brute-force search?

Every chess engine I've ever heard of (including all I found listed on Wikipedia) uses brute-force search with an evaluation function (minmax algorithm) to decide on its move. This is not how most ...
user57565488's user avatar
4 votes
1 answer
418 views

Alpha-beta safe on incomplete tree?

I'm writing a simple chess program from scratch on a hobbyist basis. I think there is something fundamental I'm overlooking or don't understand. I read the following http://chessprogramming....
AttributedTensorField's user avatar
15 votes
5 answers
2k views

What is the highest known lower bound for mate in N from starting position?

Edit: It seems my question was not clear enough. Let me rephrase: What is the largest N for which we can knowingly say "chess, from the starting position, is not a forced mate in N moves"? Chess is ...
Sami Liedes's user avatar
37 votes
5 answers
31k views

How do chess engines "think"?

What I want to know is how engines are programmed to find moves. I'm sure they first calculate the most forcing lines such as captures and checks. But what about subtle, deep positional moves? They ...
chubbycantorset's user avatar
17 votes
8 answers
21k views

What is an accurate way to evaluate chess positions?

I've been interested for a while about a computer chess AI algorithms (and got the chance to work on one at some point) like Minimax, and as the core component of these algorithms is the so-called ...
Charles Menguy's user avatar
20 votes
1 answer
4k views

What algorithms and heuristics are popular in computer chess?

Computer chess has exploded in the last twenty years, with a computer world championship being established and many chess computer designers becoming quite profitable from their endeavors. Some of ...
Andrew Latham's user avatar