better calculations of cell width