Original Post
Hello everyone, I have some questions about my transposition tables. One question I am having is this, is a transposition entry more valuable if it was cached at a level closer to the root then to the leaf nodes? Sometimes I wonder if how I refer to the root/leaf nodes is different then others... I consider zero the root node, and the maximum search depth the ply of the leaf nodes. With that in mind, In a hypothetical 6 ply minimax search, it would make more sense that a move cached at level 1 would be of more value then a move cached at level six, because the score of the move at level 1 is calculated based on all of the many leaf nodes in the tree below it. Is that the proper thinking? Check out this psuedocode which reflects my thinking: hashmap TransTable = new hashmap() score CheckTranspositionTable( zobkey ) { if( TransTable.get(zobkey) != null) { entry = TransTable.get(zobkey); return entry->score; } return null; } void cacheTransposition(zobkey, score, depth) { if( TransTable.get(zobkey) != null) { entry = TransTable.get(zobkey); // Dont cache if there exists an entry with a lower depth if(entry->depth < depth) { return; } } entry = new cacheEntry() entry->score = score; entry->depth = depth; TransTable.put(zobkey, entry); } Thanks everyone