add cell size calculation