The acceleration due to gravity at a radial distance r (r < R) from the centre of a sphere of constant mass density ρ is given by
g=r2G(34πr3)ρ=34πρGr .
Consider a spherical shell of radius r and thickness dr.

Let P and P + dP be the fluid pressures inside and outside the shell. Consider a small element of area A and mass dm=ρAdr on the shell. The forces on this element are gravitational force (dm g) direted inwards, the force due to pressure of the fluid outside the shell ((P+dP)A) directed inwards, and the force due to pressure of the fluid inside the shell (PA) directed outwards. In equilibrium, net force on the element is zero, i.e.,
(ρAdr)34πρGr+(P+dP)A=PA , or
dP=−34πGρ2rdr .
Note that the pressure decreases with increase in r. The pressure is zero at the surface of the sphere i.e., P = 0 at r = R. Integrate to get
∫0P(r)dP=P(r)=−34πGρ2∫Rrrdr
=32πGρ2(R2−r2) .
Now, P(r=0)=32πρ2GR2=0
P(r=2R/3)P(r=3R/4)=R2−(2R/3)2R2−(3R/4)2=167×59=8063
P(r=2R/5)P(r=3R/5)=R2−(2R/5)2R2−(3R/5)2=2516×2125=2116
P(r=R/3)P(r=R/2)=R2−(R/3)2R2−(R/2)2=43×89=3227=2720