Update PolyGrid.m

This code now splits the vertex info into different sections based on the user specification.