A particle is released from rest at the center of a spherical cavity of radius r inside a uniform solid sphere of density ρ. The center of the cavity is at a distance d from the center of the solid sphere. Find the velocity of the particle after it has traveled a distance x along the direction of the field inside the cavity.