Updated grid generator