When you figure my average gobbler succumbs well inside 20 yards, you might think I was the wrong guy to answer. However, let's get Newtonian here and see what gives.
First off, look at pellet count and velocity buys you. Pellets? You are imparting a force on the turkey with pellets. If a pellet hits in the vital region, it is going to do damage. It contributes to the mass component of the Force= Mass X Acceleration equation. What you want in the end is more F. How much M or A is immaterial
Velocity is a component of the F= M X A equation . It is buried in the Acceleration. Acceleration is change in Velocity over time. In this case, you've got so many feet per second suddenly going to Zero when it hits the turkey's head. A higher V results in a higher A.
So what you would have to do is figure how much additional Mass is in one load versus the higher Acceleration in the other and how each affects the Force.
AHHHHH! However, you had the answer all along and you weren't really noticing. The key here is not the total number of pellets, but how many landed in the vitals. The second load has 9 versus the other's 7. The second load has:
a) More Massive pellets (a greater M)
b) More Pellets (still greater M)
c) Higher Velocity (greater A)
F=M X A : Definitely the second load is a better bet at 40 yards. At 20 yards. . .well, we can't say, but if your aim is right , that gob is going to be missing his head. Honestly, my guess is both are going to bring the turkey down out to 40 yards. However, I have always been a fan of bigger Mass myself. I always shoot #4.