# Pressure inside the sphere

## Homework Statement

I have a sphere filled with unknown gas. I have to estimate the pressure inside of it.

• The tricky part is that density of the sphere changes as we go deeper inside of it with the given formula:
ρ=ρo*(1-r/R), where R is radius of the sphere and is known: R=5*1010m, and r is a variable.
• Gas has mol mass m=2.7 g/mol.
• Mass of the whole sphere is M=3.3*1050 kg.
• Gas is ideal.

• pV=nRT
• p=F/A

## The Attempt at a Solution

The force of gravity of an infinitesimal layer of thickness dr inside the sphere at some radius r caused by the inner sphere is:

dF=GmM/r2 where m is the mass of the infinitesimal layer and M is the mass of inner part of the sphere.

Mass m=V*ρ=4*PI*r2o*(1-r/R)*dr
Mass M=4/3*PI*r3o*(1-r/R)

so dF=G*16/3*PI2*r3o2*(1-r/R)2*dr

dp=dF/A
dp=dF/4*PI*r2
dp=4/3*PI*G*ρo2*(1-r/R)2*r*dr

so
p(r)=4/3*PI*G*ρo2*$$\int$$(1-r/R)2*r*dr from r to R

After making the calculations I will put p(r=0) and get the pressure inside the sphere. Is my method good?