amago wrote:
Great about Kevin Waugh is he has some code published:
https://github.com/kdub0/hand-isomorphismI tried to run check.exe and got an assertion error. Anyone else get this?
(note there was a compile warning)
$ make check
cc -std=c99 -Wall -g -O2 -c -o src/check-main.o src/check-main.c
cc -std=c99 -Wall -g -O2 -c -o src/deck.o src/deck.c
cc -std=c99 -Wall -g -O2 -c -o src/hand_index.o src/hand_index.c
src/hand_index.c: In function ‘hand_index_ctor’:
src/hand_index.c:25:5: warning: suggest parentheses around ‘-’ in operand of ‘&’ [-Wparentheses]
for(uint_fast32_t j=0, set=~i&(1<<RANKS)-1; j<RANKS; ++j, set&=set-1) {
^
cc -o src/check src/check-main.o src/deck.o src/hand_index.o
./src/check
testing hand-isomorphism...
sizes: 169 1286792 55190538 2428287420
configurations: 2 15 46 158
permutations: 19 1315 8227 63523
preflop table:
A K Q J T 9 8 7 6 5 4 3 2
A 3053826047 7149443039322 7149443039321 7149443039320 7149443039319 7149443039318 7149443039317 7149443039316 7149443039315 7149443039314 7149443039313 7149443039312 7149443039311
K 3053826046 3053826034 7149443039310 7149443039309 7149443039308 7149443039307 7149443039306 7149443039305 7149443039304 7149443039303 7149443039302 7149443039301 7149443039300
Q 3053826045 3053826033 3053826022 7149443039299 7149443039298 7149443039297 7149443039296 7149443039295 7149443039294 7149443039293 7149443039292 7149443039291 7149443039290
...
...
full preflop...
assertion "index < size" failed: file "src/check-main.c", line 30, function: test_full