variance_of_rank function

variance of rank