Fen is incomplete

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Henk
Posts: 7216
Joined: Mon May 27, 2013 10:31 am

Fen is incomplete

Post by Henk »

Fen is incomplete for it does not contain information about whether three fold repetition would occur for the next moves to be played.

Looks like you have to store position plus part of the move history of the game the position was taken from.
User avatar
hgm
Posts: 27787
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Fen is incomplete

Post by hgm »

Indeed, a FEN is for encoding board position, not for game history. It only contains the part of the game state relevant for deciding about move legality.
Henk
Posts: 7216
Joined: Mon May 27, 2013 10:31 am

Re: Fen is incomplete

Post by Henk »

I don't know if that will give a problem when doing MCTS. Now I clear the move history when searching the position for then it will comply if I store the game from the given start position (fen).

If I don't clear the move history then I search/simulate and store games where for instance only one move had been played because of three fold repetition draw.
kliles
Posts: 22
Joined: Fri Mar 23, 2012 8:35 pm
Location: Toronto Canada

Re: Fen is incomplete

Post by kliles »

FEN also does not encode other information along the same lines: whether either of the Kings has moved (and moved back for example...) and the same for Rooks (with respect to the legality of castling etc).
zullil
Posts: 6442
Joined: Tue Jan 09, 2007 12:31 am
Location: PA USA
Full name: Louis Zulli

Re: Fen is incomplete

Post by zullil »

kliles wrote:FEN also does not encode other information along the same lines: whether either of the Kings has moved (and moved back for example...) and the same for Rooks (with respect to the legality of castling etc).
But it does explicitly indicate castling availability.
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Fen is incomplete

Post by bob »

kliles wrote:FEN also does not encode other information along the same lines: whether either of the Kings has moved (and moved back for example...) and the same for Rooks (with respect to the legality of castling etc).
Eh? FEN has ALWAYS included castling status for both directions, both sides. The KQkq you often see means that white can castle both directions (KQ) and same for black (kq). If the king moves, those are not shown for that side. If either rook moves, the corresponding K or Q is removed...
Last edited by bob on Mon Feb 12, 2018 11:14 pm, edited 1 time in total.
kliles
Posts: 22
Joined: Fri Mar 23, 2012 8:35 pm
Location: Toronto Canada

Re: Fen is incomplete

Post by kliles »

Thanks for the rebuttal! I appreciate the correction. :oops: