Bin contents depends on total number of bins

If your “exampledebug.dat” file contains values which are “exactly” equal to “i0.01" then, due to floating-point rounding problems, they may enter either into the histogram’s bin which begins with "i0.01” or which ends with “i*0.01” (note that, in the verbose screen output, you just see the leading several decimal places of the “lower edges”).
Try, for example (even shifting by something like +1e-11 instead of +0.5 should be sufficient): TH1D* h1 = new TH1D("h1", "sum E dep. of all 3x3 pixels (MeV)" , nbins1, 0.0 + 0.5 * delta, nbins1*delta + 0.5 * delta ); TH1D* h2 = new TH1D("h2", "sum E dep. of all 3x3 pixels (MeV)" , nbins2, 0.0 + 0.5 * delta, nbins2*delta + 0.5 * delta ); TH1D* h3 = new TH1D("h3", "sum E dep. of all 3x3 pixels (MeV)" , nbins3, 0.0 + 0.5 * delta, nbins3*delta + 0.5 * delta );
See also: Different Values on cout and TH2