The question describes a procedure that's unreliable at best. A wave diagram seldom includes any thoughts at all, and if there ARE some present, then either their number is constant, or they occur at a very slow rate. So it's unlikely that any hat can be found in this way.