mod the index