single cell iteration seems to work for density computation