end of iteration G