Properly varabilizing the block grid
Removing redundant code