Computer Chess Club Archives


Search

Terms

Messages

Subject: Question to Dieter Buerssner

Author: Alvaro Jose Povoa Cardoso

Date: 03:33:51 04/21/02


>I am not Martin, and I neither do no much about checkers. But you seem to miss
>one idea: that the pieces are indistinguishable. Arguing for Chess and an
>illegal QQ position (both Qs same color, no Ks for this example). How many
>different positions are there? Ignoring symmetry, the naive answer would be
>64*64 (or 64*63, doesn't matter for this). But Qa1,b1 is the same as Qb1,a1. So
>you only need 64*63/2 indices. For 3 Qs, it would be 64*63*62/3!, etc. You >might ask, how to index them then. For example by a precalculated helper array:
>
>index = precalculated_index[sq1][sq2]... // instead of sq1 + sq2*64 + ...
>
>Regards,
>Dieter


Hi Dieter,
first of all thanks for you help.

Could you please elaborate a little more on that precalculated index array?
Please remember I'm  a novice :)
How do I construct that array?
Will the very same array serve for all piece types/color?
Suppose I have 3Qs and 3Bs (all white), could I use that same array for the 3
queens and the 3 bishops the same time?

Should I have a one dimension array for 1 piece, and a two dimension array for 2
piece, and a 3 dimension array for 3 piece and so on?

Best regards,
Alvaro Cardoso



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.