corrected rank wrap-around