I would go wider than a 4". It will give you a wider "ledge" to put the log on.
Most commercial splitters use a 7" beam, but usually not an I-beam. Just 1/4" plates welded to form an i-beam.
Something along the lines of an 8"x 6-1/2" or 10"x8" beam should suffice with no worries
On wideflange beams, they name them by
W...stands for wide flange
#
#...inches of depth
x
#
#...pounds per ft
So I would reccomend something along the lines of a W8 x 28 or W10x33
That is a wide-flange 8" depth and has a weight of 28lbs per foot.
I-beams are NOT sized by flange width. You can look up the specs online, but for example, there are about 6 different beams that fall into the 8x8 size. They are 31,35,40,48,58,and 67 lbs per foot.
Here is a good site for getting physical sizing, but as far as load capacity, theres a WHOLE lot of calculations involved.
Steel I Beam, Wide Flange Beam, S, Jr., WF, details, sizes, dimensions, beams
There are twisting forces, as well as the shear tonnage of the ram. and it isnt a direct perpendicular load to the beam. So the calculations are hard to figure. That is why most are just made pleanty big with room for error.