new stages added. stage 0 taken into account