compute the right study modes