closed path of grid