To develop this problem it is necessary to apply the concepts related to the proportion of a neutron star referring to the sun and density as a function of mass and volume.
Mathematically it can be expressed as
[tex]\rho = \frac{m}{V}[/tex]
Where
m = Mass (Neutron at this case)
V = Volume
The mass of the neutron star is 1.4times to that of the mass of the sun
The volume of a sphere is determined by the equation
[tex]V = \frac{4}{3}\pi R^3[/tex]
Replacing at the equation we have that
[tex]\rho = \frac{1.4m_{sun}}{\frac{4}{3}\pi R^3}[/tex]
[tex]\rho = \frac{1.4(1.989*10^{30})}{\frac{4}{3}\pi (1.05*10^4)^3}[/tex]
[tex]\rho = 5.75*10^{17}kg/m^3[/tex]
Therefore the density of a neutron star is [tex] 5.75*10^{17}kg/m^3[/tex]