Search found 67 matches

by grant
Sun May 25, 2008 4:32 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: How to reduce the "bits" used in a magic number ca
Replies: 67
Views: 29396

Re: How to reduce the "bits" used in a magic numbe

Edmund

I don't see any errors in my code. I have now checked and double checked again, and it works.
B2 is square 49 for me, so maybe B7 for you. Could you check again?

I have also found more 9-bit magic numbers for rooks so it would be nice to get this verified.

Grant
by grant
Sun May 25, 2008 10:29 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: How to reduce the "bits" used in a magic number ca
Replies: 67
Views: 29396

Re: How to reduce the "bits" used in a magic numbe

Magic number found!

B2 9-bit = 48FFFE99FECFAA00

Hmm. This is the same as A2 10-bit. Double checking... Yep it works.

Grant
by grant
Sun May 25, 2008 10:13 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: How to reduce the "bits" used in a magic number ca
Replies: 67
Views: 29396

Re: How to reduce the "bits" used in a magic numbe

If you are looking for more optimal magics, you shouldn't just rely on random numbers. As grant said, splitting the search into smaller parts, helps. So for example, if you are trying to find magics for rooks, you could start with the row and then adding the columns. Then you can always check, how ...
by grant
Sat May 24, 2008 6:16 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: How to reduce the "bits" used in a magic number ca
Replies: 67
Views: 29396

Re: How to reduce the "bits" used in a magic numbe

Zach Wegner wrote: The magics were found by just pumping a bunch of random numbers and testing them out. Not exactly! First I realized that the random numbers needed to be very dense, then by analyzing the results I printed whilst searching I was easily able to identify which bits of the magic numb...
by grant
Wed Mar 19, 2008 1:03 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: small rybka source code released by author to public
Replies: 7
Views: 4390

Re: small rybka source code released by author to public

Knight capture code in Atlanchess. Moves are pushed onto the stack and retrieved at the end of the function. mov edi, dword ptr [boards+18h] //white knights bitboard mov ebx, dword ptr [boards+1Ch] mov eax, edi or eax, ebx je short capwBP1 //jump to bishops if no knights mov dword ptr [temp], edi //...
by grant
Sun Feb 24, 2008 11:10 pm
Forum: Computer Chess Club: Tournaments and Matches
Topic: Results of Crafty 22.0, Sloppy 0.2.0 and Atlanchess 4.1
Replies: 16
Views: 2851

Re: Results of Crafty 22.0, Sloppy 0.2.0 and Atlanchess 4.1

Tony

Thanks for your kind comments on Atlanchess 4.1

Grant
by grant
Sun Feb 24, 2008 3:02 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Magic Move Generation
Replies: 33
Views: 18043

Re: Magic Move Generation

As an example, the rook on square B7, it should take long to find a 10-bit magic number for this square, and upon investigation, all 1024 elements are used. However if you then generate another 10-bit magic number you might discover that this number only requires 1023 elements such that the very las...
by grant
Sat Feb 23, 2008 10:10 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Magic Move Generation
Replies: 33
Views: 18043

Re: Magic Move Generation

Mine is already compressed to 4909 for bishops, 99768 for rooks and 20118 for castling

Grant
by grant
Fri Feb 22, 2008 3:17 pm
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: Magic Move Generation
Replies: 33
Views: 18043

Re: Magic Move Generation

Hi If you look at a bishop on the C8 square, masking off the border, there are a possible 32 different combinations of occupancy for the squares that this bishop can reach. So 5 bits you would expect to be optimal for C8. For square D5 on the other hand there are 512 different combinations of occupa...
by grant
Mon Jan 28, 2008 11:55 am
Forum: Computer Chess Club: Programming and Technical Discussions
Topic: speed question about strelka
Replies: 5
Views: 2479

Re: speed question about strelka

Hi Interesting that you can use magic to calculate the pawn shield. If the white king is on the 1st rank (or 2nd rank as I do), shift the WhitePawns bitboard to the left then AND with 0x0000000000000707. Then use magic to calculate an index into an array[64] containing a value representing the stren...