It looks like you are averaging data sets of differing resolutions. Use 3dinfo on each of the bricks you are passing to 3dmerge and see which one has the differing number of voxels in any of the three dimensions. (The number of voxels is between parenthesis at the end the *-to-* extent lines.)
As to why you end up with data sets of different sizes, I can't tell.
cheers
-ziad