Fixed #1006

Also some grid fixes for 2D model