 # Gmx densmap : what does counts option do?

Dear gromacs users :

I am using gmx densmap to calculate the population of solute around the receptor.
In the densmap you can choose solute and then a 2D map of density is be generated.

There are multiple options for normalisation and I am bit confused about those :

The normalisation of the output is set with the -unit option.",

1. The default (nm-3) produces a true number density.
2. Unit nm-2 leaves out","the normalization for the averaging or the angular direction.,
3. "Option count produces the count for each grid cell.

So if I choose non-radial and “count” then that’s default from nmpower switch (code) :
default: vol = j+1; (volume is defined by just next grid point boundary ?)
and the counts are actual count of number of instances of the solute in each grid cell of (bin 0.02 nm in xyz)- without being normalized by the volume ? as it is given in the code : grid[i][j] /= nfr

But those are still normalized by number of frames and thus are representing the
“probability of that solute in that particular grid cell”?
Is my understanding correct?

------CODE snippet grom gmx densmap------

if (std::strcmp(eunit, “nm-3”) == 0)
{
nmpower = -3;
unit = “(nm^-3)”;
}
else if (std::strcmp(eunit, “nm-2”) == 0)
{
nmpower = -2;
unit = “(nm^-2)”;
}
else
{
nmpower = 0;
unit = “count”;
}

/* normalize gridpoints /
maxgrid = 0;
{
for (i = 0; i < n1; i++)
{
for (j = 0; j < n2; j++)
{
grid[i][j] /= nfr;
if (grid[i][j] > maxgrid)
{
maxgrid = grid[i][j];
}
}
}
}
else
{
for (i = 0; i < n1; i++)
{
vol_old = 0;
for (j = 0; j < nradial; j++)
{
switch (nmpower)
{
case -3: vol = M_PI
(j+1)(j+1)/(invspzinvspzinvspa); break;
case -2: vol = (j+1)/(invspz
invspa); break;
default: vol = j+1; break;
}
if (bMirror)
{