Removed <math.h> from grid.cc.