index pay logic