Inside a sphere of constant density, gravity is linearly related to distance from the center.
So for example the Earth has a radius of ~4000 miles. Assuming it has constant density, a 200 pound man would be weightless at its center, weigh 0.2 pounds at 4 miles from the center, weigh 2 pounds at 40 miles from the center, weigh 100 pounds at halfway to the surface, and so on.