Modified RNTN code