Experimental design. A, In a bistable visual perception test, participants were presented with a structure-from-motion stimulus to both their eyes and asked to report when their perception switched between downward and upward rotating with a button press. B, TS tests consisted of shape and brightness tasks. On each trial, participants had to choose the circle (shape task) or the brightest figure (brightness task). C, In the spontaneous TS test, participants could freely choose which task to perform for each trial. We quantified cognitive rigidity as how long participants repeated the same task continuously. D, In the instructed TS test, participants were given instructions about which task to perform for each trial. E, Order of the instruction in the instructed TS tests was determined based on their own responses during the spontaneous TS tests. Therefore, the participants performed the same TS pattern in the two TS tests.