---
abstract: 'Based on the basic definition of Fermi energy of degenerate and relativistic electrons, we obtain a special solution to electron Fermi energy, $E_{\rm F}(e)$, and express $E_{\rm F}(e)$ as a function of electron fraction, $Y_{e}$, and matter density, $\rho$. Several useful analytical formulae for $Y_{e}$ and $\rho$ within classical models and the work of Dutra et al.  2014 (Type-2) in relativistic mean field theory are obtained using numerically fitting.  When describing the mean-field Lagrangian, density, we adopt the TMA parameter set, which is remarkably consistent with with the updated astrophysical observations of neutron stars.  Due to the importance of the density dependence of the symmetry energy, $S$, in nuclear astrophysics, a brief discussion on the symmetry parameters $S_v$ and $L$ (the slope of $S$) is presented.  Combining these fit formulae with boundary conditions for different density regions, we can evaluate the value of $E_{\rm F}(e)$ in any given matter density, and obtain a schematic diagram of $E_{\rm F}(e)$ as a continuous function of $\rho$. Compared with previous study on the electron Fermi energy in other models, our methods of calculating $E_{\rm F}(e)$ are more simple and convenient, and can be universally suitable for the relativistic electron regions in the circumstances of common neutron stars.  We have deduced a general expression of $E_{\rm F}(e)$ and $n_{e}$, which could be used to indirectly test whether one EoS of a NS is correct in our future studies on neutron star matter properties.  Since URCA reactions are expected in the center of a massive star due to high-value electron Fermi energy and electron fraction, this study could be useful in the future studies on the NS thermal evolution.' 
address:
- |
    1.  Xinjiang Astronomical Observatory, CAS, 150, Science 1-Street, Urumqi, Xinjiang, China.\
    2.  Key Laboratory of Radio Astronomy, Chinese Academy of Sciences, 2 West Beijing Road, Nanjing, Jiangsu, 210008, China\
    3.  University of Chinese Academy of Sciences, 19A Yuquan Road, Beijing, 100049, China 
- |
    1.  Xinjiang Astronomical Observatory, CAS, 150, Science 1-Street, Urumqi, Xinjiang, China\
    2.  Key Laboratory of Radio Astronomy, Chinese Academy of Sciences, 2 West Beijing Road, Nanjing, Jiangsu, 210008, China
- 'Shchool of Astronomy and Space Science, Nanjing University, Nanjing, Jiangshu, China'
- 'Changchun Astronomical Observatory, National Observatories, CAS, Changchun, 130117, China'
- 'National Astronomical Observatories, Chiese Academy of Sciences, Beijing 100012, China'
- 'Xinjiang Astronomical Observatory, CAS, 150, Science 1-Street, Urumqi, Xinjiang, China'
- 'Xinjiang Astronomical Observatory, CAS, 150, Science 1-Street, Urumqi, Xinjiang, China'
author:
- 'Xing Hu, Li'
- 'Zhi Fu, Gao[^1]'
- 'Xiang Dong, Li'
- 'Yan, Xu'
- 'Pei, Wang'
- 'Na, Wang'
- 'Jianping, Yuan'
title: Numerically Fitting The Electron Fermi Energy and The Electron Fraction in A Neutron Star 
---

Introduction {#I}
============

Pulsars are among the most mysterious objects in the universe that provide natural laboratory for investigating the nature of matter under extreme conditions, and are universally recognized as normal neutron stars (NSs), but sometimes have been argued to be quark stars[@Xu02; @Du09; @Lai13] .  The equation of state (EoS) of matter under exotic conditions is an important tool for the understanding of the nuclear force and for astrophysical applications.  The Fermi energy of relativistic electrons $E_{\rm F}(e)$ is one of most important and indispensable physical parameters in the EoS, and varies with matter density $\rho$. The electron Fermi energy influences directly weak-interaction processes including modified URCA reactions[@Yakovlev01], electron capture[@Gao11a; @Gao11b; @Gao12a; @Wang12; @Liu13] and so on, in the circumstance of a NS.  These influences will change intrinsic EoS, interior structure and heat evolution, and even affect the whole properties of the star. 

Another important physical parameter affecting internal properties of a NS is the electron fraction, which is defined as $Y_{e}=n_{e}/n_{B}$ ($n_{e}$ and $n_{B}$ are the electron number density, baryon number density, respectively, and varies with the high-density star matter.  The value of average electron fraction is about 0.05 for a common NS[@Yakovlev01; @Shapiro83].  However, to exactly calculate the values of $Y_{e}$ for the neutron star matter has long been a very challenging task for both the nuclear physics and the astrophysics community[@Lattimer04] due to some uncertainties and artificial assumptions in studying structures and properties of NSs.  Currently, our knowledge of the electron fraction mainly comes from the model-dependence EoSs of NSs.  For the $\beta$- equilibrated NS matter we have free neutron decay $n\rightarrow p+ e^{-}+ \overline{\nu_{e}}$, which are governed by weak interaction and the electron capture process $p+e^{-}\rightarrow n+ \nu_{e}$. Both types of reactions alter $Y_e$, and thus affect the EoS. However, in the currently popular and reliable EoSs of NSs, neutrinos generated in these reactions are always assumed to leave the system.  The absence of neutrino surely has some influence on the EoS and mainly induces a significant change on the value of $Y_e$.

As we know, for degenerate and relativistic electrons in $\beta-$equilibrium, the distribution function $f(E_{e})$ obeys Fermi-Dirac statistics: $f(E_{e})=1/(Exp((E_{e}-\mu_{e})/kT)+1)$, $k$ represents Boltzmann’s constant, and $\mu_{e}$ is the electron chemical potential.  If $T\rightarrow 0$, $\mu_{e}$ is also called the electron Fermi energy, $E_{\rm F}(e)$, which presents the energy of highest occupied states for electrons.  The electron Fermi energy $E_{\rm F}(e)$ has the simple form $$E_{\rm F}(e) = \left(p^{2}_{\rm F}(e)c^{2}+ m^{2}_{e}c^{4}\right)^{1/2}~~,~~%
\label{1}$$ with $p_{\rm F}(e)$ being the electron Fermi momentum.  The isoenergetic surface of $E=E_{\rm F}(e)$ is called the electron Fermi surface[@Gao12b; @Gao13; @Gao11c]. 

In the context of general relativity principle, the matter density is defined as: $\rho= \varepsilon/c^{2}$, $\varepsilon$ is the total energy density, including the rest-mass energies of particles.  Using the basic thermodynamics, we obtain the relation of the total matter pressure $P$ and matter density $\rho$ in a common NS, $$\begin{aligned}
&&P(n_{B})= n_{B}^{2}\frac{d(\varepsilon/n_{B})}{d n_{B}}~, \nonumber\\
&&\rho(n_{B})= \varepsilon(n_{B})/c^{2}, ~~\Rightarrow P= P(\rho)~. % 2
\label{2}\end{aligned}$$ From the above equation, it is obvious that $P$ solely depends on $\rho$. Theoretically, we can obtain the value of $E_{\rm F}(e)$ by solving EOS in a specific matter model.  In this paper, we mainly focus on $E_{\rm F}(e)$ and $Y_e$ for degenerate and relativistic electrons inside a common NS, where the magnetic effects on the EoS are ignored. 

This paper is arranged as follows.  In Sec.  2, we briefly review the structure of a NS.  In Sec.  3, we deduce a special solution to $E_{\rm F}(e)$. We apply the special solution obtained to numerically simulate $E_{\rm F}(e)$ and $Y_e$ of a NS within classical models in Sec.  4, and within the work of Dutra et al.  2014[@Dutra14] in Sec.  5.  In Sec.  6 we present comparisons and discussions.  The conclusion is presented in Sec.7. 

Reviewing A NS’ Structure  {#II}
==========================

The structure of a NS includes an atmosphere and four main internal regions: the outer crust, inner crust, outer core, and inner core.  The atmosphere is a thin layer of plasma which determines the spectrum of thermal electromagnetic radiation of the star.  The geometrical depth of the atmosphere varies from some ten centimeters in a hot star down to some millimeters in a cold one. 

The knowledge of structures and properties of the crust plays an important role in understanding many astrophysical observations[@Horowitz04; @Owen05; @Steiner05; @Burrows06].  The outer crust consists of nuclei in a Coulomb lattice and electron gas, and has a depth of a few hundred meters.  At $\rho\leq 10^{4}$ g cm$^{-3}$, the electron gas may be non-degenerate, and the ionization may be incomplete; at $\rho<10^{7}$ g cm$^{-3}$, the ground state may be $^{56}_{26}Fe$; at $\rho\sim10^{9}$ g cm$^{-3}$, the nuclei capture electrons and become neutron-rich, and at the neutron drip density $\rho_{d}$, the neutrons start to drip from the nuclei and form a free neutron gas.  The neutron drip density $\rho_{d}$ is well determined[@BPS71; @Ruster06] to be about $4.3\times10^{11}$ g cm$^{-3}$.

The inner crust of a NS spans the region from the neutron drip point to the inner edge separating the solid crust from the liquid core, and has several kilometers deep.  The matter of the inner crust in nuclear equilibrium consists of neutron-rich nuclei in a Coulomb lattice, electrons, and free neutrons.  As matter density increases, free neutrons supply an increasingly large fraction of the total matter pressure $P$. At the crust-core transition density, $\rho_{t}$, the baryon number density reaches a critical value, and nuclei dissolve and merge together. 

The outer core consists of neutrons, protons and electrons (hereinafter “$npe$ system”), spans a density range of about $0.5\rho_{0}\sim 2.5\rho_{0}$, and has a depth of several kilometers, $\rho_{0}=2.8\times10^{14}$ g cm$^{-3}$ is the standard nuclear density.  At the inner edge of the outer core small fraction of muons ($\mu$) may appear[@Yakovlev01], because the electron Fermi energy could exceed the muon rest-mass energy $m_{\mu}c^2=105.7$ MeV. However, a definite boundary between the outer core and inner core has not yet been obtained due to the uncertainty of crust-core transition density. 

The inner core is about several kilometers in radius, and has a central density as high as $\sim$ $10^{15}$ g cm$^{-3}$. With still further increase of density, the inner core becomes energetically more economic if some nucleons transform to ¡®exotic¡¯ particles such as hyperons, pion condensates, kaon condensates and quarks, etc.,  when $\rho>\rho_{tr}$, here $\rho_{tr}$ is the transition density to these ¡®exotic¡¯ particles, which is $\sim 4\rho_{0}$[@Tsuruta09].  The maximum of the inner core density could exceed this transition density, so hyperons, pion condensates, kaon condensates, quarks and nucleons with large $Y_e$ are expected to exist in the inner core of a NS. 

Electron Fermi Energy And Its Special Solution {#III}
==============================================

General relation of $E_{\rm F}(e)$, $Y_e$ and $\rho$
----------------------------------------------------

In the interior of a common NS with $B\sim 10^{10}-10^{12}$ G, the isoenergetic surface of degenerate and relativistic electrons is a spherical surface, and the microscopic state number of electrons in a unit volume, $N_{pha}$, is calculated by $$N_{pha}=n_{e}= \frac{g}{h^{3}}\int_{0}^{p_{\rm F}(e)}4\pi p^{2}dp=
\frac{8\pi}{3h^{3}}p_{\rm F}^{3}(e). 
\label{3}$$ where $h$ is Plank’s constant.  For the convenience of calculations, we introduce a dimensionless momentum of electrons, $x_{e}=p_{\rm F}(e)/m_{e}c$. According to Pauli¡¯s exclusion principle, the electron number density is equal to its microscopic state density, $$n_{e}= N_{pha}= \frac{8\pi}{3\lambda_{e}^{3}}x_{e}^{3}~,
\label{4}$$ where $\lambda_{e}=h/m_{e}c= 2.4263\times 10^{-10}$ cm is the electron Compton wavelength.  The average mass of a baryon $m_{B}$ is defined as $$m_{B}\equiv \frac{1}{n}\sum_{i}n_{i}m_{i}= \frac{\sum_{i}n_{i}m_{i}}{\sum_{i}n_{i}A_{i}},
\label{5}$$ with $A_{i}$  the baryon number of species $i$. In the interior of a NS, the relation of $m_{B}\equiv m_{u}\equiv1.6606\times10^{-24}$ g always holds, $m_{u}$ is the mass of an atom.  Thus, the matter density can be expressed as: $$\rho= n_{B}m_{B}= \frac{n_{e}m_{B}}{Y_{e}}~~,
\label{6}$$ Combining Eq.(5) with Eq.(6), we get $$x_{e}=(\frac{3\lambda_{e}^{3}}{8\pi m_{u}}Y_{e}\rho )^{\frac{1}{3}}~~.
\label{7}%$$ Inserting the values of $\lambda_{e}$ and $m_{u}$ into Eq.(7) gives $$x_{e}=1.0088\times 10^{-2}(Y_{e}\rho)^{\frac{1}{3}}~~.
\label{8} %$$ Since the average molecule weight of electrons $\mu_{e}=\frac{m_{B}}
{m_{u}Y_{e}}=\frac{1}{Y_{e}}$, we get $$\rho=\mu_{e}m_{u}n_{e}= 0.97395\times 10^{6}\frac{x_{e}^{3}}{Y_{e}},
\label{9} %$$ Combining Eq.(1) with Eqs.(8) and (9), we get the electron Fermi energy $$E_{\rm F}(e)=m_{e}c^{2}(1+ x_{e}^{2})^{1/2}=[1+1.018\times10^{-4}(\rho Y_{e})^{\frac{2}{3}}]
^{\frac{1}{2}}\times 0.511~{\rm MeV}.~
 \label{10} ~$$ The expression above is a general formula for the electron Fermi energy, which is approximately suitable for relativistic electron matter regions ($\rho\geq 8.6\times 10^{6}$ g cm$^{-3}$) in the whole interior of a common NS.  If $x_{e}=p_{e}/m_{e}c\gg 1 $, Eq.(10) can be approximately reduced as $E_{\rm F}(e)\approx 5.16\times10^{-3}(\rho Y_{e})^{\frac{1}{3}}$ [MeV]{}. 

Special solution to $E_{\rm F}(e)$ 
-----------------------------------

In this part, in order to obtain a special solution to $E_{\rm F}(e)$, we consider an ideal $n-p-e$ system under $\beta$-equilibrium in the outer core, where electrons are relativistic, neutrons and protons are non-relativistic.  According to Shapiro & eukolsky (1983)[@Shapiro83] (hereinafter “ST-83”), when $\rho \gg 10^{13}$  g cm$^{-3}$, the neutron pressure dominates in the interior of a NS, and $\rho
\approx m_{n}n_{n}$, then the neutron number density $n_{n}=1.7\times 10^{38}
(\rho/\rho_{0})$ cm$^{-3}$, the charge neutrality requires the proton number density $n_{p}=n_{e}=9.6\times 10^{35}(\rho/\rho_{0})^{2}$ cm$^{-3}$; $\beta$-equilibrium implies momentum conservation of $p_{\rm F}(p)=p_{\rm F}
(e)= 60(\rho/\rho_{0})^{2/3}$ MeV/c), thus the electron Fermi energy $$E_{\rm F}(e)= 60(\rho/\rho_{0})^{2/3}~~{\rm MeV},
\label{11}$$ where $p_{\rm F}(p)$ is the proton Fermi momentum.  A simple proof of Eq.(11) is presented as follows: From the relations of $n_{p}$, $n_{e}$ and $n_{n}$ above, we get $$Y_{e}=Y_{p}\approx \frac{n_{e}}{n_{n}}\approx 0.005647\times(\frac{\rho}{\rho_{0}})~,
\label{12}$$ where $Y_{p}$ is the proton fraction.  Combining Eq.(12) with Eq.(10), we get $$\begin{aligned}
&&E_{\rm F}(e)=[1+1.018\times10^{-4}(\rho\times0.005647(\frac{\rho}{\rho_{0}}))^{\frac{2}{3}}]^{\frac{1}{2}}\times0.511~ \nonumber\\
&&=[1+1.018\times0^{-4}(2.8\times10^{14}\times0.005647(\frac{\rho}{\rho_{0}})^{2})^{\frac{2}{3}}]^{\frac{1}{2}}\times0.511~ \nonumber\\
&&=[1+1.018\times 10^{-4}(1.58116\times 10^{12})^{\frac{2}{3}}]^{\frac{1}{2}}\nonumber\\
&&\times(\frac{\rho}{\rho_{0}})^{\frac{2}{3}}\times0.511~
=60\times(\frac{\rho}{\rho_{0}})^{\frac{2}{3}}~({\rm MeV}). 
\label{13} %\end{aligned}$$ The above proof indicates that Eq.(10) is an accurate expression.  Inserting Eq.(12) into Eq.(11) yields $$\begin{aligned}
E_{\rm F}(e)=&&60\times(\frac{\rho}{\rho_{0}})^{\frac{1}{3}}(\frac{\rho}{\rho_{0}})^{\frac{1}{3}}= 60\times(\frac{\rho}{\rho_{0}})^{\frac{1}{3}}(\frac{\frac{\rho_{0}Y_{e}}{0.005647}}{\rho_{0}})^{\frac{1}{3}}\nonumber\\
&& =60\times(\frac{\rho}{\rho_{0}})^{\frac{1}{3}}(\frac{Y_{e}}{0.005647})^{\frac{1}{3}}~~~~({\rm MeV}). 
\label{14}\end{aligned}$$ The equation above is a special solution to $E_{\rm F}(e)$, which is suitable relativistic electron matter region of a common NS. 

Test the validity of the special solution 
------------------------------------------

To test the validity of the special solution to $E_{\rm F}(e)$, we will calculate the values of $E_{\rm F}(e)$ in the work of Baym, Bethe & Pethick (1971)[@BBP71] (hereinafter “BBP model”) by using Eq.(14), and will compare our results with those of BBP model.  By introducing a compressible liquid drop model of nuclei, BBP model is more successful than other models in describing matter in the inner crust, where the system becomes a mixture of nuclei, free neutrons, and electrons.  According to BBP model[@BBP71], the total energy density $\varepsilon$ and the total matter pressure $P$ of the system are described by $$\begin{aligned}
&&\varepsilon= \varepsilon_{e}(n_{e})+ n_{N}(W_{N} + W_{L})
+ n_{n}(1-~V_{N}n_{N})W_{n}~~,\nonumber\\
&& P= P_{n} + P_{e} + P_{L}~
\label{16}~\end{aligned}$$ where $n_{n}$ is the number density of neutrons outside of nuclei (hereinafter “neutron gas”), and the new feature is the dependence on the volume of a nucleus $V_{N}$, which decreases with the outside pressure of the neutron gas; $P_{n}$, $P_{e}$ and $P_{L}$ are the neutron gas pressure, electron pressure, and lattice pressure, respectively.  The baryon number density in this model is $$n_{B}= An_{N} + (1- V_{N}n_{N})n_{n}~~~,
\label{16}$$ where $V_{N}n_{N}$ and $1- V_{N}n_{N}$ are the fraction of volume occupied by nuclei, and the fraction occupied by neutron gas, respectively.  Then $E_{\rm F}(e)$ is determined by $$E_{\rm F}(e)=\frac{\partial \varepsilon_{e}}{\partial n_{e}}= \frac{\partial}{\partial n_{e}}(n_{e}E_{e})
=- \frac{\partial}{\partial Z}(E_{N}+E_{L}). 
~\label{17}~$$ The values of $E_{\rm F}(e)$ in BBP model are partly listed in Table 1.  The sign ‘$\dag$’ denotes that $\rho_{m}$ is the maximum equilibrium density at which the nuclide is present.  The data of columns 1, 2, 3, 4 and 7 are cited from Table 2 of Canuto (1974)[@Canuto74].  The electron fraction $Y_{e}
=Y_{p}= \frac{Zn_{N}I}{n_{B}}\simeq \frac{Zn_{N}}{\rho/m_{u}}$, and the values of $E_{\rm F}^{'}(e)$ in column 8 are obtained using the specific solution of Eq.(14). 

In Table 1 the magnitude of $|\frac{E_{\rm F}^{'}(e)-E_{\rm F}(e)}
{E_{\rm F}(e)}|$ is $\sim 10^{-3}$, which illustrates that our calculations are consistent with those of BBP[@BBP71].  From the comparison above, our method of calculating $E_{\rm F}(e)$ is more simple and convenient than that in BBP model.  Be noted that, as a representative model, BBP model is arbitrarily selected to test the validity of the specific solution to $E_{\rm F}(e)$. In this part, other matter models will no longer be enumerated, due to the restriction of space. 

Numerically Simulating $E_{\rm F}(e)$ and $Ye$ in A NS (I) {#IV}
==========================================================

In this Section, we will numerically fit the relation of $Y_{e}$ and $\rho$ in the whole interior of a NS, according to several reliable EoSs within simple but classical matter models.  Combining the analytic expressions of $Y_{e}$ and $\rho$ with the special solution to $E_{\rm F}(e)$, we will obtain schematic diagrams of $E_{\rm F}(e)$ vs. $\rho$ in different density regions for relativistic electrons. 

Numerically fitting in the outer crust
--------------------------------------

By introducing the lattice energy, Baym, Pethick & Sutherland (1971)[@BPS71] (hereafter “BPS model”) improved on Salpeter’s treatment[@Salpeter61], and described the nuclear composition and EoS for catalyzed matter in complete thermodynamic equilibrium below $\rho_{d}$. BPS model is one of most successful models describing matter of the outer crust.  According to BPS model, the total energy density $\varepsilon$ and the total matter pressure $P$ are described by $$\begin{aligned}
&&\varepsilon=\varepsilon_{N}+\varepsilon_{e}+\varepsilon_{L},\nonumber\\
&&P= P_{e} + P_{L}= P_{e}+ \frac{1}{3}\varepsilon_{L},
  \label{18}\end{aligned}$$ where $\varepsilon_{N}$ is the energy density of nucleus, $\varepsilon_{e}$ the energy density of free electrons, and $\varepsilon_{L}$ the $bcc$ Coulomb lattice energy in a unit volume.  The value of $E_{\rm F}(e)$ is obtained by solving the following differential equation, $$E_{\rm F}(e)=\mu_{e}=\frac{\partial \varepsilon_{e}}{\partial n_{e}}
=\frac{\partial}{\partial n_{e}}( n_{e}E_{e}). 
\label{19}$$ For the specific equilibrium nuclei $(A, Z)$ in BPS model, the values of quantities $Y_{e}$, $\rho_{m}$, and $E_{\rm F}(e)$ are tabulated in Table 2. 

  ----- -----
        
   (a)   (b)
  ----- -----

Be note that the relation of $Y_{e}=Y_{p}= Z/A$ always approximately holds in BPS model.  From Table 2, it’s obvious that $Y_{e}$ decreases with $\rho$. Combining Eq.(20) with the special solution, we plot the diagram of $E_{\rm F}(\rm e)$ and $\rho$, and compare our results with those in BPS model.  From Fig.  1(b), it’s obvious that $E_{\rm F}(e)$ increases with $\rho$ in BPS model.  Theoretically, employing Eq.(20), we can obtain an approximate value of $E_{\rm F}(e)$, given a matter density of the outer crust. 

Numerically fitting in the inner crust
--------------------------------------

The uncertainty of crust-core transition density mainly comes from limited knowledge of EoS, especially the density-dependence symmetry energy of neutron-rich nuclear matter [@Lattimer01; @Lattimer07].  Employing the method of quantum mechanics, Negele & Vautherin (1973)[@NV73](hereinafter “NV model”) firstly obtained the value of $\rho_{t}\sim 1.32\times10^{14}$ g cm$^{-3}$. Recently, Atta & Basu (2014) obtained the value of $1.54\times 10^{14}$ g cm$^{-3}$ (or$\rho_{t}\sim$ 0.0938 fm$^{-3}$) in the $M3Y$ nucleon-nucleon effective

interaction model[@Atta14].  However, Atta & Basu (2014)[@Atta14] obtained $Y_{e}\sim 0.031$, which is very close to the value $Y_{e}\sim 0.032$ in NV model[@NV73]. 

Here we select $\rho_{d}=4.3\times 10^{11}$ g cm $^{-3}$, corresponding to $Y_{e}\approx 0.3051$ and $E_{\rm F}
(e)\approx 26.2$ MeV, in BPS model, and select $\rho_{t}= 1.32
\times 10^{14}$ g cm$^{-3}$ in NV model.  Since the nuclei have dissolved by merging together at the base of the inner crust, the matter begins to turn into an ideal $npe$ system.  From ST-83, we obtain $Y_{e}\approx 0.0026$ and $E_{\rm F}(e)\approx 36.3$ MeV at $\rho=\rho_{t}$.

Although the EoS above $\rho_{d}$ is reasonably well understood by BBP model, this model in a higher density region $\rho\geq 1.72\times
10^{14}$ g cm$^{-3}$ was criticized by some authors[@Canuto74; @Shapiro83; @Gao13], due to a monotonic and arbitrary increase of $Z$ with $A$, which causes the relation of $P$ and $\rho$ to be changed not much.  Thus, we stop listing related calculations in the higher density region.  For convenience, the inner crust can be roughly divided into two regions: a lower density region, and a higher density region.  The matter in the lower density region is still described by BBP model, whereas matter in the higher density region is described by an ideal mixed model(hereinafter “IM model”).  With respect to IM model, our main hypotheses are as follows:

1.   Though matter in IM model is also a mixture of nuclei, free neutrons and free electron gas, the details of nucleon-nucleon interactions may be ignored, due to the uncertainty of nuclei compositions in IM model. 

2.   The matter in IM model distributes in a range of $\sim 10^{12}\sim
          1.32\times 10^{14}$ g cm$^{-3}$, $E_{\rm F}(e)$ grows with $\rho$ smoothly, but the growth is not two much. 

3.   Nuclei in IM model are more neutron-rich, and thus the values of $Y_{e}$ are universally smaller than those in BBP model, given the same matter densities. 

4.   The electron fraction steadily decreases with matter density until $\rho=\rho_{t}$. To insure that $E_{\rm F}(e)$ increases with $\rho$, and $Y_{e}$ decrease with $\rho$ in IM model, the initial density of IM model, $\rho_{\rm IM}$, should be $1.0\times 10^{13}$ g cm$^{-3}$, we arbitrarily select $\rho_{m}=6.25\times 10^{12}$ g cm$^{-3}$ for ground state nucleus $^{170}_{48}Cd$ in BBP model to be $\rho_{IM}$ for IM model. 

Based on Table 1, we plot a diagram of $Y_{e}$ and $\rho$ in the lower density region of the inner crust, as shown in Fig.  2.  By numerically fitting, we obtain an analytical expression of $Y_{e}$ and $\rho$, $$Y_{e}=0.0164-214.87e^{-\rm Log_{10}\rho}+3.67\times10^{9}e^{-2\rm Log_{10}\rho}. 
 \label{21}$$ in the range of 4.3$\times 10^{11}\sim 6.25\times 10^{12}$ g cm$^{-3}$. Due to lack of a detailed information on IM model introduced by this work, we cannot give an exact formula of $Y_{e}$ and $\rho$ for the higher density region.  However, we mainly focus on the special solution to $E_{\rm F}(e)$ and its potential applications.  We assume that $E_{\rm F}(e)$ grows with $\rho$ exponentially, and the expression of $E_{\rm F}(e)$ and $\rho$ has a simple exponential form, $$E_{\rm F}(e)= A+ Be^{\rm Log_{10}\rho}~~{\rm MeV},
   \label{22}$$ in the higher density region.  Employing the boundary conditions: (1) $\rho=\rho_{IM}=6.25\times 10^{12}$ g cm$^{-3}$, $Y_{e}\approx 0.0439$, $E_{\rm F}(e)\approx 33.43$ MeV, (2) $\rho=\rho_{t}=1.32\times 10^{12}$ g cm$^{-3}$, $Y_{e}\approx 0.0026$, $E_{\rm F}(e)\approx 36.3$ MeV, we obtain the values of two constants, $A=32.4$ and $B=2.882\times 10^{-6}$. Combining the special solution of Eq.(14) with Eq.(22), we obtain an analytical formula, $$Y_{e}\approx0.005647(\frac{\rho_{0}}{\rho})(0.539+4.803\times10^{-8}e^{\rm Log_{10}\rho})^{3},
  \label{23}$$ in the higher density region.  The relations of $Y_{e}$ and $\rho$, and $E_{\rm F}(e)$ and $\rho$ in the inner crust are shown in Fig.3. 

  ----- -----
        
   (a)   (b)
  ----- -----

In addition, we calculate the values of $E_{\rm F}(e)$ and $Y_{e}$ in IM model , as listed in column 4 and column 5 of Table 3, respectively. 

The data of columns 1, 2, 3, 6, 7 and 8 are cited from Table 1 in this paper.  The data of columns 4, 5, 9 and 10 are obtained from IM model using Eq.(14) and Eq.(24).  From Table 3, IM model may be superior to BBP model in the higher density region. 

Numerically fitting in the outer core
-------------------------------------

The numerical simulations in the outer core are usually subject to two distinct uncertainties:(1) determining the nuclear potential for nucleon-nucleon interaction, and (2) finding an appropriate technique for solving the many-body problem.  The nuclear potential is constrained somewhat by nucleon-nucleon scattering data and nuclear matter results[@Lattimer91; @Haensel07]. 

As mentioned in Section 3.2, the matter in the outer core contains relativistic electrons, non-relativistic neutrons, and non-relativistic protons.  Here, for the sake of simplicity, we consider a homogenous ideal $npe$ system under $\beta$-equilibrium, and adopt ST-83 approximation[@Shapiro83]) as the main method to treat EoS of this system.  The relation of $Y_{e}$ and $\rho$ is described by $$Y_{e}\approx \frac{n_{e}}{n_{n}}= 0.005647\times(\frac{\rho}{\rho_{0}})~,
\label{24}$$ in the density range of $0.5\rho_{0}\sim 2.5\rho_{0}$ (c.f.  Sec.  2.2), Combining the above equation with the special solution, we plot schematic diagrams of $Y_{e}$ vs. $\rm Log_{10}\rho$ and $E_{\rm F}(e)$ vs. $\rm Log_{10}\rho$ in the outer core of a NS, as shown in Fig.  4. 

  ----- -----
        
   (a)   (b)
  ----- -----

Numerically simulating in the inner core
----------------------------------------

Although the maximum inner-core-density could exceed the transition density $\rho_{tr}$[@Tsuruta09], for the sake of simplicity, we focus on a non-relativistic domain of $\sim 2.5\rho_{0}\sim 2.0\times 10^{15}$ g cm$^{-3}$, and consider a system, composed of neutrons, protons, electrons and muons under $\beta$-equilibrium.  Here our first aim is to deduce an analytical expression of $Y_{e}$ and $\rho$ in the inner core.  A detailed deduction is summarized as follows:

When $E_{\rm F}(e)$ is high enough, it is energetically favorable for electrons to turn into muons, so that muons and electrons are in equilibrium: $\mu^{-}\leftrightarrow e^{-}$, here we have as usual assumed that the neutrinos leave the system.  Once we know this equilibrium, thermodynamics does not require us to know any detail of the process of $\mu^{-}\leftrightarrow e^{-}$. Chemical potential equilibrium and charge neutrality give $$\begin{aligned}
&&m_{\mu}c^{2}(1+x_{\mu}^{2})^{1/2}= m_{e}c^{2}(1+x_{e}^{2})^{1/2} ,\nonumber\\
&&m_{n}c^{2}(1+x_{n}^{2})^{1/2}= m_{p}c^{2}(1+x_{p}^{2})^{1/2}+ m_{e}c^{2}(1+x_{e}^{2})^{1/2},~~\nonumber\\
&&(m_{p}x_{p})^{3}=(m_{e}x_{e})^{3}+(m_{\mu}x_{\mu})^{3}~.
\label{24}~~\end{aligned}$$ where $x_{i}=p_{\rm F}(i)/m_{i}c^{2}$ ($i= n, p, e£¬\mu$) is the dimensionless Fermi momenta.  From Eq.(24), the electron fraction can be expressed as a function of $x_{e}$, $$\begin{aligned}
&&Y_{e}=\frac{n_{e}}{n_{B}}\approx \frac{n_{e}}{n_{n}}
=\frac{(m_{e}x_{e})^{3}}{(m_{n}x_{n})^{3}}=\frac{m_{e}^{3}x_{e}^{3}}{m_{n}^{3}\{[\frac{m_{p}}{m_{n}}(1+x_{p}^{2})^{\frac{1}{2}}+
\frac{m_{e}}{m_{n}}(1+x_{e}^{2})^{\frac{1}{2}}]^{2}-1 \}^{\frac{3}{2}}}~,\nonumber\\
&& =\frac{m_{e}^{3}x_{e}^{3}}{m_{n}^{3}\{[1+\frac{m_{e}^{3}x_{e}^{3}+
m_{\mu}^{3}(\frac{m_{e}^{2}x_{e}^{2}}{m_{\mu}^{2}}-1)^{\frac{3}{2}}}{2m_{p}^{2}}+
\frac{m_{e}(1+x_{e}^{2})^{\frac{1}{2}}}{m_{n}}]^{2}-1\}^{\frac{3}{2}}}~~,
\label{25}~\end{aligned}$$ where we used $m_{p}/m_{n}\approx 1$ and $\mu_{\mu}=\mu_{e}$. Inserting $m_{e}=0.511$ MeV, $m_{p}=938.28$ MeV, $m_{n}=939.57$ MeV, and $m_{\mu}=105.7$ MeV, into Eqs.(25), we obtain a schematic diagram of $Y_{e}$ and $x_{e}$ in the inner core of a NS. 

From Fig.  5, it’s obvious that $Y_{e}$ increases with $x_{e}$ in the inner core of a NS. 

The threshold density for muons to appear, $\rho_{\mu}$, is also an important issue.  When at $\rho_{\mu}$, $n_{\mu}=0$ that is $x_{\mu}=0$. Since the electrons are highly relativistic, we can take $x_{e}\gg 1$, Eq.(24) becomes $$\begin{aligned}
&& m_{\mu}= m_{e}x_{e}~,\nonumber\\
&&m_{n}c^{2}(1+x_{n}^{2})^{\frac{1}{2}}=m_{p}c^{2}(1+x_{p}^{2})^{\frac{1}{2}}+ m_{e}x_{e},\nonumber\\
&&m_{p}x_{p}= m_{e}x_{e}.  ~\label{26}~\end{aligned}$$ Inserting the values of $m_{e}$, $m_{p}$, $m_{n}$, and $m_{\mu}$ into Eq.(26), we get $x_{e}=206.8$,$x_{p}=0.1126$, and $x_{n}=0.4986$, corresponding to $\rho_{\mu}=8.21\times10^{14}$ g cm$^{-3}$. Combining Eq.(25) with the expression of $x_{e}=1.0088\times10^{-2}(Y_{e}\rho)^{\frac{1}{3}}$  with , we calculate the values of $Y_{e}$ in the range of $8.2\times 10^{14}\sim
2.0\times 10^{15}$ g cm$^{-3}$, as shown in Fig.  6(a).  By fitting these values of $Y_{e}$ and $\rho$, we obtain an analytical formula of $Y_{e}$ and $\rho$ $$Y_{e}\approx -0.0115+ 7.402\times 10^{-9}e^{\rm Log_{10}\rho},
\label{27}~$$ in the inner core of a NS.  Combining Eq.(27) with the special solution, we plot the diagram of $E_{\rm F}(e)$ and $\rho$, as shown in Fig.  6(b). 

  ----- -----
        
   (a)   (b)
  ----- -----

Here we arbitrarily select a maximum density $2.0\times10^{15}$ g cm$^{-3}$ for the inner core matter, because at higher densities (more than $10^{15}$ g cm$^{-3}$), the composition is expected to include an appreciable number of hyperons, and the nucleon interactions must be treated relativistically.  In a real scenario, matter in the inner core could be more complicated than that of ideal $npe\mu$ system. 

Summary
-------

As to the main purpose and innovations for the simulations above, a brief summary is presented as follows:

  ----- -----
        
   (a)   (b)
  ----- -----

1.   Firstly, in the previous studies, there are too many matter models, some of which are rather successful and thus representative.  By solving the EoSs of these models (including the above models), we can obtain the relations of $E_{\rm F}(e)$ vs. $\rho$ and $Y_{e}$ vs. $\rho$. However, there still exist limitations for each EoS to some extent.  For example, any EoS has a certain application range of matter density, the resulting values of $E_{\rm F}(e)$ and $Y_{e}$ will deviate from those in the actual scenario if the EoS is beyond of its application range of density. 

2.   Secondly, up to now, we have not obtained a uniform EoS of one certain matter model, which is excellent in describing the relations of $E_{\rm F}(e)$, $Y_{e}$ and $\rho$ in the whole interior of a NS.  By numerically simulating, we have obtained a set of analytical expressions for $E_{\rm F}(e)$, $Y_{e}$ and $\rho$ from EoSs.  However, this is not our main purpose.  Our ultimate aim is to investigate the whole variation trends in $Y_{e}$ vs. $\rho$ and $E_{\rm F}(e)$ vs. $\rho$ in the whole relativistic electron matter region of a NS using these analytical expressions obtained. 

3.   Thirdly, as we know, the electron Fermi energy, as well as the electron pressure, is always continuous in the interior of a NS.  From the general formula for $E_{\rm F}(e)$ (see Eq.(10)), $Y_{e}$ is also a continuous function of $\rho$ in a NS.  Utilizing the boundary conditions and the fitting formula of $E_{\rm F}(e)$, $Y_{e}$ and $\rho$ in four matter regions (the outer crust, inner crust, outer core, and inner core), we obtain the values of $E_{\rm F}(e)$ and $Y_{e}$, which are smooth and continuous functions of matter density, as well shown in Fig.7. 

4.   At last, we can see that the electron fraction $Y_{e}$ firstly decreases in the crust, then increases in the core (from Fig.7(a)).  The decrease in $Y_{e}$ is caused by increasing neutronization of nuclei, as the depths of the crust increases, whereas the increase in $Y_{e}$ is due to the fact that, the proton fraction $Y_p$ always increases with the core matter density required by the chemical potential equilibrium under $\beta-$ equilibrium, and the charge neutrality gives $n_p=n_e + n_{\mu}$. Be note that $n_{\mu}$ is far less than $n_e$ given a matter density.  From Fig.7(b), the electron Fermi energy always increases with matter density, the reason for the increase in $E_{\rm F}(e)$ is that $E_{\rm F}(e)$ solely depends on $n_e$, which always increases with $\rho$ (for details see in Sec.6.) 

It should be admitted that our method of fitting $Y_{e}$ and $E_{\rm F}(e)$ is somewhat simple, but is practically convenient.  Especially, it is convenient to calculate the value of $E_{\rm F}(e)$ given a matter density inside a NS. 

Numerically Simulating $E_{\rm F}(e)$ and $Ye$ in A NS (II) {#V}
===========================================================

As mentioned in Sec.4, numerically fitting $E_{\rm F}(e)$ and $Y_{e}$ in the core of a NS are subject to many uncertainties, including the possibility of neutron and proton superfluid, of pion condensation, of phase transitions to quark matter[@Du09; @Lai13], and the consequences of the $\Delta$ resonances[@Xu13a; @Xu13b].  To date, many of relativistic models[@Glendenning85; @Schaffner93; @Shen02; @Yang08; @Dutra12] have drawn attentions in investigating EoSs because they are particularly suited for describing NSs according to the special relativity.  The most common among them is the relativistic-mean- field (RMF) theory, which has become a standard method to study nuclear matter and finite-nuclei properties. 

As an up-to-date representative theoretical work in RMF theory is Dutra et al. ( 2014)[@Dutra14], in which 263 RMF models are examined three different sets of constraints related to pure neutron matter, symmetric nuclear matter, symmetry energy, and its derivatives are used.  The authors gave a detailed discussion of these models when investigating properties like realistic values of the asymmetry energy and its slope, compressibility and the question that whether the EoS can actually reproduce 2-solar mass stars, as have been observed in PSR J1615-2230[@Demorest10], within the whole NS interior, and added extensive supernova EOS online tables (like on http://compose.obspm.fr). 

According to RMF theory, baryonic interactions include three cases: (1) exchanging three mesons of $\sigma$, $\omega$ and $\rho$; (2) exchanging four mesons of $\sigma$, $\omega$, $\rho$ and $\sigma$; (3) exchanging five mesons of $\sigma$, $\omega$, $\rho$, $\sigma^{*}$, $\phi$. In order to provide a new insight into application of RMF models to the nuclear matter properties, Dutra et al. ( 2014) considered the four-meson-exchange baryonic interactions, and divided the RMF models into seven types regarding their lagrangian density structures: Typ1-1: linear finite range models in which $A=B=C=\alpha_{1}=\alpha_{2}=\alpha^{'}_{1}=\alpha^{'}_{2}=\alpha^{'}_{3}=g_{\sigma}=0$; Type-2:$\sigma^{3}+\sigma^{4}$ models in which $C=\alpha_{1}=\alpha_{2}=\alpha^{'}_{1}=\alpha^{'}_{2}=\alpha^{'}_{3}=g_{\sigma}=0$ ; Type-3: $\sigma^{3}+\sigma^{4}+\omega^{4}_{0}$ models in which $\alpha_{1}=\alpha_{2}=\alpha^{'}_{1}=\alpha^{'}_{2}=\alpha^{'}_{3}=g_{\sigma}=0$; Type-4: $\sigma^{3}+\sigma^{4}+\omega^{4}_{0}+$ cross terms models in which $g_{\sigma}=0$ and at least one of the coupling constants, $\alpha_{1}, \alpha_{2}, \alpha^{'}_{1}, \alpha^{'}_{2}$, or $\alpha^{'}_{3}$ is different from zero; Type-5: density-dependent models in which $g_\delta \rightarrow T_{\delta}(\rho)=0$; Type-6: point-coupling models in which $g_\delta \neq 0$; and Type-7: $\delta-$ meson models in which $a_{TS}=0$. For the physical meaning of each parameter above, see Dutra et al. ( 2014). 

In this paper, for the purpose of comparing with the classical models applied in Sec.4, we will choose Type-2 in Dutra et al. ( 2014) as a representative RMF theoretical work.  The main merit of Type-2 in Dutra et al (2014) lies in that it describes well the properties of EoS of a NS in the vicinity of the saturated nuclear density $\rho_{0}$.

From Eq.(1) of Dutra et al. ( 2014), we get the effective lagrangian of Type-2 **in Dutra et al (2014)** $$\begin{aligned}
&& \mathcal{L}=\sum_{B}\bar{\psi}_{B}\left[ i\gamma _{\mu }\partial
^{\mu }-m_{B}-g_{\sigma B}\sigma -g_{\omega B}\gamma _{\mu }\omega ^{\mu }
-g_{\rho B}\gamma _{\mu }\tau_{i}\rho _{i}^{\mu }\right] \psi _{B} \nonumber \\
&&+\frac{1}{2}\partial _{\mu }\sigma
\partial ^{\mu }\sigma -\frac{1}{2}m_{\sigma }^{2}\sigma ^{2}
-\frac{1}{3}g_{2}\sigma ^{3}-\frac{1}{4}g_{3}\sigma ^{4}-\frac{1}{4}W_{\mu
\nu }W^{\mu \nu }+\frac{1}{2}m_{\omega }^{2}\omega _{\mu }\omega ^{\mu }\nonumber \\
&&-\frac{1}{4}R_{i\mu \nu }R_{i}^{\mu \nu }+\frac{1}{2}m_{\rho }^{2}\rho _{i\mu }\rho
_{i}^{\mu }+\sum_{l}\bar{\psi}_{l}\left[ i\gamma _{\mu }\partial ^{\mu }-m_{l}\right]
\psi _{l},  \label{29}\end{aligned}$$where the baryon species are marked as B,and the sum on $l$ is over electrons and muons ($e^{-}$ and $\mu
^{-}$).  In the RMF models, the meson fields are treated as classical fields, and the field operators are replaced by their expectation values.  The meson field equations in uniform matter have the following form: $$\begin{aligned}
&&m_{\sigma }^{2}\sigma +g_{2}\sigma ^{2}+g_{3}\sigma ^{3}=-\sum_{B}\frac{%
g_{\sigma B}}{\pi ^{2}}\int_{0}^{k_{F}^{B}}\frac{m_{B}^{\ast }}{\sqrt{%
k^{2}+m_{B}^{\ast 2}}}k^{2}dk,  \label{30} \\
&&m_{\omega }^{2}\omega +c_{3}\omega ^{3}=\sum_{B}\frac{g_{\omega B}\left(
k_{F}^{B}\right) ^{3}}{3\pi ^{2}},  \label{31} \\
&&m_{\rho }^{2}\rho =\sum_{B}\frac{g_{\rho B}\tau _{3B}\left(
k_{F}^{B}\right) ^{3}}{3\pi ^{2}},  \label{32}\end{aligned}$$where $\sigma =\left\langle \sigma \right\rangle ,$ $\omega =\left\langle
\omega^{0}\right\rangle ,$ and $\rho =\left\langle \rho ^{30}\right\rangle ,$ are the nonvanishing expectation values of meson fields in NS matter, $m_{B}^{\ast}=m_{B}+g_{\sigma B}\sigma $ is the effective mass of the baryon species $B$, and $k_{F}^{B}$ is the Fermi momentum.  At zero temperature the lepton chemical potentials are expressed by $$\mu _{l}=\sqrt{{k_{F}^{l}}^{2}+m_{l}^{2}}, ~~~~(\rm fm^{-1}) \label{33}$$ The charge neutrality condition is given by $$\sum_{B}q_{B}\rho_{B}-n_{e}-n_{\mu}=0,  \label{34}$$ where $\sum_{B}q_{B}=n_{B}$, and $q_{B}$ is the baryon electric charge.  We can solve the coupled equations self-consistently at a given baryon density.  Then we get the total energy density $\varepsilon$ and pressure $P$ $$\begin{aligned}
&&\varepsilon =\sum_{B}\frac{1}{\pi ^{2}}\int_{0}^{k_{F}^{B}}\sqrt{%
k^{2}+m_{B}^{\ast 2}}\ k^{2}dk+\frac{1}{2}m_{\sigma }^{2}\sigma ^{2}+\frac{1%
}{3}g_{2}\sigma ^{3}+\frac{1}{4}g_{3}\sigma^{4}  \nonumber \\
&&+\frac{1}{2}m_{\omega}^{2}\omega ^{2}+\frac{3}{4}c_{3}\omega ^{4}+\frac{1%
}{2}m_{\rho }^{2}\rho^{2}+\sum_{l}\frac{1}{\pi ^{2}}\int_{0}^{k_{F}^{l}}\sqrt{k^{2}+m_{l}^{2}}\
k^{2}dk,  \label{35}\end{aligned}$$$$\begin{aligned}
&& P=\frac{1}{3}\sum_{B}\frac{1}{\pi ^{2}}\int_{0}^{k_{F}^{B}}\frac{%
k^{4}\ dk}{\sqrt{k^{2}+m_{B}^{\ast 2}}}-\frac{1}{2}m_{\sigma }^{2}\sigma
^{2}-\frac{1}{3}g_{2}\sigma ^{3}-\frac{1}{4}g_{3}\sigma^{4}  \nonumber \\
&&+\frac{1}{2}m_{\omega }^{2}\omega ^{2}+\frac{1}{4}c_{3}\omega^{4}+\frac{1%
}{2}m_{\rho }^{2}\rho ^{2}+\frac{1}{3}\sum_{l}\frac{1}{\pi ^{2}}\int_{0}^{k_{F}^{l}}
\frac{k^{4}\ dk}{\sqrt{k^{2}+m_{l}^{2}}}.   \label{36}\end{aligned}$$

In the work of Dutra et al. ( 2014), the authors listed more than 130 RMF models for Type-2.  These models have been widely used because of several important aspects not always present in non-relativistic models (e.g., intrinsic Lorentz covariance, appropriate saturation mechanism for nuclear matter and etc).  Unfortunately, the authors didn’t present any information on the electron Fermi energy and electron fraction within these models, due to the restriction of space. 

In order to obtain better agreement for the behavior of EOS at high matter densities with that predicted by the relativistic Brueckner-Hartree-Fock theory, the parameter set TMA was developed, based on two other widely used parameter sets, TM1 and TM2[@Sugahara94].  The parameter set TMA has been one of the most successful modern parameter sets.  In this work, we select the parameter set TMA [@Geng05; @Singh12] for the mean-field Lagrangian density, and list the parameter values in Table 4. 

In addition, the properties of ground-state nuclear matter include: the saturation density $\rho_0$=0.147(fm)$^{-3}$, bulk binding energy/nucleon $(E/A)_\infty=-16.0$MeV, incompressibility $K=318.0$ MeV, bulk symmetry energy/nucleon $a_{sym}=30.68$MeV, and the effective mass ratio $m^{*}/m=0.635$[@Geng05; @Singh12]. 

Inserting the above parameters into Eq.(34) and Eq.(35), we get the relation of $\varepsilon$ and $P$ in Dutra et al.(2014) (Type-2), shown as in Fig.8. 

Here the relation of $c\hbar$=1 MeV$\times 5.43\times 10^{-3}$ fm$^{-1}$ is used.  From Fig.  8, it’s obvious that $P$ increases with $\varepsilon$ in the whole interior of a NS.  Inserting EoSs (Eq.(34) and Eq.(35)) into TOV equation $$\frac{dP}{dr}=-\frac{G}{r} \frac{\left(\varepsilon+P\right)\left(m+ 4\pi r^{2}P\right)}{r-2Gm},~~~~~
\frac{dm}{dr}= 4\pi r^{2}\varepsilon,  \label{36}$$ gives the one-to-one relation of star mass $m$ and radius $r$. Since the baron number density at the stellar center is determined by $n_{B}(c)=\frac{m}{m_{u}}/(\frac{4}{3}\pi r^{3})$, we obtain the relation of star mass $m$ and $n_{B}(c)$, as shown in Fig.9. 

From Fig.9, it’s obvious that $m$ increases with the baron number density at the stellar center $n_{B}(c)$, and the maximum stellar mass is about 1.9916$M_{Sun}$ ($M_{Sun}$ is the solar mass), corresponding to $n_{B}(c)\textbf{=0.9156}$ fm$^{-3}$ in Dutra et al. ( 2014)(Type-2) for RMF theory.  The maximum stellar mass of 1.9916$M_{Sun}$) is very close to the observational NS mass limit of $\sim 1.97M_{Sun}$ for PSR J1615-2230[@Demorest10], which indicates our parameter-set choice (TMA) is rather reliable and successful. 

We also calculate the values of $E_{\rm F}(e)$ and $Y_{e}$ in the whole density range in Dutra et al. ( 2014)(Type-2), as listed in Appendix B. Based on Tables 5-8 in Appendix B, we numerically fit the relations of $Y_e$ vs. $Log_{10}\rho$ and $E_{\rm F}(e)$ vs. $Log_{10}\rho$ in Dutra et al. ( 2014) (Type-2), as shown in Fig.10, and obtain a set of analytical expressions of $$\begin{aligned}
&&Y_{e}=-0.000012+1.213\times10^{-9}e^{\rm Log_{10}\rho}-2.51\times10^{-15}e^{2\rm Log_{10}\rho}
+8.19\times10^{-21}e^{3\rm Log_{10}\rho}, \nonumber\\
&&Y_{e}=0.0644-1.506\times10^{-7}e^{\rm Log_{10}\rho}+1.11\times10^{-13}e^{2\rm Log_{10}\rho}
+1.84\times10^{-20}e^{3Log_{10}\rho},        \nonumber\\
&&Y_{e}=-0.188+1.85\times10^{-7}e^{\rm Log_{10}\rho}-3.59\times10^{-14}e^{2\rm Log_{10}\rho}
+2.54\times10^{-21}e^{3\rm Log_{10}\rho},
\label{37}~\end{aligned}$$ for $\rho\sim 6.92\times 10^{11}-6.07\times 10^{13}$, $6.07\times 10^{13}-6.9\times 10^{14}$, and $6.9\times 10^{14}-2.56\times 10^{15}$ g cm$^{-3}$, respectively. 

Combining Eq.(37) with the special solution of Eq.(14), we plot the diagram of $E_{\rm F}(e)$ vs. $Log_{10}\rho$ (see the solid-line of Fig.10(b)), and compare our results with those in Dutra et al.(2014)(Type-2)(see the dotted-line of Fig.10(b)).  As shown in Fig.10(b), the fitted values of electron Fermi energies are well in agreement with their calculated values, which indicates that the pairs of $E_{\rm F}(e)$ and $Y_e$ in Tables 5-8 in Appendix B are suited for the special solution of Eq.(14).  In other words, the special solution of Eq.(14) is equally applicable to RMF models. 

We have found that both $Y_{e}$ and $E_{\rm F}(e)$ increase with matter density in Dutra et al. ( 2014)(Type-2).  Here, the maximum of central density is arbitrarily selected to be $\rho=$1.4 fm$^{-3}$, corresponding to $Y_{e}=0.15570$ and $E_{\rm F}(e)=367.40$ MeV. Like in classical models, the increase in $E_{\rm F}(e)$ in RMF theory is also caused by an increase in electron number density in the core of a NS. 

  ----- -----
        
   (a)   (b)
  ----- -----

Due to the restriction of space, the other six types in Dutra et al (2014) will no longer be considered. 

Comparisons and Discussions {#VI}
===========================

Relations of $Y_{e}$ and $\rho$ in different models. 
----------------------------------------------------

The numerical simulations above indicate that the relation of $Y_{e}$ and $\rho$ is model dependent.  In order to see the differences between relations of $Y_{e}$ and $\rho$ in several simple classical models (in this work) with those in RMF theory, we produce the diagrams of $Y_{e}$ vs. $\rm Log_{10}\rho$ in the interior of a NS, as shown in Fig.11.  In Fig.11 the black solid-line is obtained by fitting in Sec.4, and the red solid-line is fitted from data of Tables 5-8 in Appendix B in this work.  for Dutra et al. ( 2014)(Type-2).  By comparing, some classical models (e.g., BPS and BBP models) may be superior to RMF theory model in the low-density crustal region.  For example, $Y_{e}$ in Dutra et al. ( 2014)(Type-2) begins to appear at $\rho=6.92\times 10^{11}$ g cm$^{-3}$, and always increases with $\rho$ in the high-density range.  However, employing the TMA parameter set, Dutra et al. ( 2014)(Type-2) will be more excellent than the simple ideal $nep\mu$ and $nep\mu$ models when describing the relation of $Y_{e}$ and $\rho$ from EoSs, because nucleon-nucleon interaction potentials are replaced by meson fields in RMF theory, rather than be ignored.  It is interesting that $Y_{e}$ in Dutra et al. ( 2014)(Type-2) grows with $\rho$ more quickly than in ideal $npe$ and $npe\mu$ systems. 

In order to make a further comparison, in Fig.  11 we add one blue dot-line fitted from Shen 2002[@Shen02].  In Shen (2002), the author constructed the EoS in a wide NS density range using RMF theory.  At low densities, the Thomas-Fermi approximation was used to describe the nonuniform matter composed of a lattice of heavy nuclei; while at high densities, the $TM1$ parameter set was adopted.  Thus, $Y_{e}$ in Shen (2002) firstly increases with $\rho$, then decreases with $\rho$. However, since the inclusion of hyperons softens the EoS considerably at high densities, the maximum of the stellar mass in Shen (2002) is about 1.6$M_{Sun}$,(due to the depression of hyperons on Fermions), which deviates from the observational NS mass limit of $\sim 1.97~M_{Sun}$ for PSR J1615-2230[@Demorest10]. 

From the comparisons above, the differences of relations of $Y_{e}$ and $\rho$ between different models are obvious.  Despite these differences, we believe the simulations and comparisons presented in this work will be useful in studying $E_{\rm F}(e)$ and $Y_{e}$ of a NS in the future. 

 Relation of $E_{\rm F}(e)$ and $n_{e}$
---------------------------------------

Though both $E_{\rm F}(e)$ and $Y_{e}$ are definite functions of $\rho$. the value of $E_{\rm F}(e)$ is ultimately determined by only parameter $n_{e}$, $$\begin{aligned}
&&E_{\rm F}(e)= m_{e}c^{2}(1+ x_{e}^{2})^{1/2}\approx m_{e}c^{2}x_{e}
= m_{e}c^{2}(n_{e}3\pi^{2}\lambda_{e}^{3})^{1/3}\nonumber\\
 && =h c( \frac{3}{8\pi}n_{e})^{1/3}=\hbar c(3\pi^{2}n_{e})^{1/3}=6.12\times 10^{-11}n_{e}^{1/3}~({\rm MeV}), \label{38}\end{aligned}$$ where $\hbar= h/2\pi$ is the reduced Plank¡¯s constant.  Be note that this equation does not depend on one certain matter model, i.e., Eq.(38) is also a general expression.  Based on Eq.(38), we plot a schematic diagram of $E_{\rm F}(e)$ vs. $n_{e}$ for relativistic electrons in the whole interior of a common NS. 

From Fig.  12, it is easy to see that, the larger the electron number density, the bigger the electron Fermi energy become.  In Fig.12, the dotted line is fitted from data of Tables 5-7 in Dutra et al. ( 2014) (Type-2), while the solid line is obtained from Eq.(38).  These two lines are well in agreement with each other which indicates that our calculations of Dutra et al. ( 2014)(Type-2) and the model self are surely correct. 

Other Fermi parameters for electrons are also solely determined by $n_{e}$. For example, the electron Fermi velocity, $v_{\rm F}(e)=\hbar k_{\rm F}/m_{e}=
\hbar(3\pi^{2}n_{e})^{1/3}/m_{e}$, the electron Fermi momentum, $p_{\rm F}(e)
=\hbar k_{\rm F}= \hbar(3\pi^{2}n_{e})^{1/3}$, and the Fermi kinetic energy of relativistic electrons, $E_{K}^{\rm F}(e)\approx cp_{\rm F}(e)= c\hbar(3\pi^{2}
n_{e})^{1/3}$, due to $E_{K}^{\rm F}(e) \gg m_{e}c^2$), where $k_{\rm F}=
(3\pi^{2}n_{e})^{1/3}$ is the electron Fermi wave-vector.  However, the relations of $n_{e}$ and $\rho$ in different density regions of a NS are usually unknown, and the known relations of $n_{e}$ and $\rho$ depend on EoS in some specific matter models.  Our study on $E_{\rm F}(e)$ may provide some conveniences in investigating EoS of a NS. 

Relations of $E_{\rm F}(e)$, $Y_{e}$ and $B$ 
---------------------------------------------

In our previous studies, by introducing the Dirac $\delta$-function in superhigh magnetic fields ($B^{*}=B/B_{\rm cr}\gg 1$, $B_{\rm cr}=4.414\times 10^{13}$ G is the electron critical field), we investigated the effects of strong magnetic fields on EoS and braking of magnetars[@Gao14; @Gao16]. 

Since superhigh magnetic fields can cause an increase in $Y_e$ by modifying the electron phase space, the electron number density will increase with magnetic field strength $B$. From Table 1 of Gao et al.(2013)[@Gao13], we obtain the diagrams of $Y_{e}$ vs. $\rho$ in BPS model in different magnetic fields, shown as in Fig.  13. 

Then, the Fermi energy of electrons will increase with $B$. Very recently[@Gao15], by introducing Landau level stability coefficient, we obtain the relations of $E_{\rm F}(e)$, $Y_{e}$, $\rho$ (or $n_e$) and $B$, $$\begin{aligned}
&&E_{\rm F}(e)=67.6\times\left(\frac{Y_e}{0.005647}\frac{\rho}{\rho_0}\right)^{1/3} \left(\frac{B}{B_{\rm cr}}\right)^{1/6}~~\rm MeV \nonumber\\
&&=6.86\times10^{-11}(n^{'}_{e})^{1/3}=6.86\times10^{-11}\left(\frac{B}{B_{\rm cr}}\right)^{1/6}(n_{e})^{1/3}~~\rm MeV, \label{39}\end{aligned}$$ where $n^{'}_{e}$ is the number density of electrons in superhigh magnetic fields.  Numerically fitting the relations between $E_{\rm F}(e)$, $Y_{e}$ and $\rho$ in superhigh magnetic fields will be considered in our future work. 

Conclusions {#VII}
===========

In this paper we deduced a special solution to Fermi energy of relativistic electrons in a common NS.  By numerically simulating, we obtained several analytical formulae for $Y_e$ vs. $\rho$ within classical matter models and Dutra et al.(2014)(Type-2). 

As a representative model, BBP model is selected to test the validity of the specific solution to $E_{\rm F}(e)$. By comparing, our method of calculating $E_{\rm F}(e)$ is more simple and convenient than that in BBP model, as well as those in other matter models. 

Using the special solution to $E_{\rm F}(e)$, we can quickly and accurately calculate the value of Fermi energy for relativistic electrons in any given matter density.  The special solution can be universally suitable for relativistic electrons regions in the circumstances of common NSs. 

By numerically simulating, the special solution to $E_{\rm F}(e)$ has been proved to be not only suitable for simple classical matter models, but also for and RMF theory models), though Dutra et al.(2014)(Type-2) was only selected as a presented theory work.  Also, the special solution to $E_{\rm F}(e)$, as well as Eq.(38), could be very useful in indirectly testing whether one EoS of a NS is correct, because Eq.(38) is the source of the special solution of Eq.(14). 

As an important parameter in EoS of a NS, the electron Fermi energy is surely of very interest.  The special solution to $E_{\rm F}(e)$ introduced by this work will be very useful in the future study on EoS of NS¡¡matter under extreme conditions, though our methods of treating EoS when numerically fitting are indeed simple. 

Acknowledgments {#acknowledgments .unnumbered}
===============

We sincerely thank the anonymous referee for carefully reading the manuscript and providing valuable comments that improved this paper substantially.  This work is supported by Xinjiang Natural Science Foundation No.2013211A053. 

[99]{} R.X. Xu, [*Astrophys.  J. Lett.*]{} [** 570**]{} (2002) 65.  Y.J. Du, et al., [* Mon.  Not.  R. Astron.  Soc.*]{} [** 399**]{}(2009) 1587.  X.Y. Lai, C.Y. Gao and R.X. Xu, 2013,[*Mon.  Not.  R. Astron.  Soc.*]{} [** 431**]{} (2013) 3290.  D.G. Yakovlev, A.D. Kaminker, O.Y. Gnedin and et al. [* Phys.  Rep.*]{} [**354**]{}(2001) 1.  Z.F. Gao, N. Wang, J.P. Yuan and et al., [* Astrophys.  Space Sci.*]{} [** 333**]{}(2011a) 427.  Z.F. Gao, Q.H. Peng, N. Wang and et al., [* Astrophys.  Space Sci.*]{} [** 336**]{} (2011b) 427.  Z.F. Gao, Q.H. Peng, N. Wang and et al., [* Astrophys.  Space Sci.*]{} [** 342**]{}(2012a) 55.  K. Wang, Z.Q. Luo and Y.L. Li, [*Chin.  Phys.  Lett.*]{} [** 29**]{}(2012) 049701 .  J.J. Liu, [*Astrophys.  Space Sci.*]{} [** 347**]{} (2013), 117.  S. L. Shapiro and S. A. Teukolsky, [*Black Holes, White Drarfs, and Neutron Stars*]{}, (New York, Wiley-Interscience, 1983).  J.M. Lattimer and M.Prakash, [*Sceience*]{}, [**304**]{}(2004) 536.  Z.F. Gao, Q.H. Peng, N. Wang and et al., [* Chin.  Phys.  B*]{} [**21**]{}(2012b) 057109.  Z.F. Gao, N. Wang, Q.H. Peng and et al. ,[*Mod.  Phys.  Lett A.*]{} [**28(36)**]{} (2013) 1350138.  Z.F. Gao, N. Wang, D.L. Song and et al., [* Astrophys.  Space Sci.*]{} [** 334**]{} (2011c) 281.  M. Dutra, O. Lourenco, S.S. Avancini and et al. ,[*Phys.  Rev. C.*]{} [**90**]{} (2014), 055203.  C. J. Horowitz, et al. ,[*Phys.  Rev. C.*]{} [**69**]{} (2004), 045804.  B. J. Owen, [*Phys.  Rev. Lett.*]{} [** 95**]{} (2005) 21101.  A. W. Steiner, M. Prakash, J.M. Lattimer and et al. ,[*Phys.  Rep.*]{} [**410**]{} (2005) 325.  A. Burrows, S. Reddy and T. A. Thompson, [*Nucl.  Phys.  A.*]{} [**777**]{} (2006) 356.  G. Baym, C. Pethick and P. Sutherland, [*Astrophys.  J.*]{} [**170**]{}(1971) 299.  S.B. Ruster, M. Hempel and J. Schaffnet-Bielich, [*Phys. Rev. C.*]{} [**73**]{}, 035804 (2006).  S. Tsuruta, J. Sadino, A. akatsuka and et al., [* Astrophys.  J.*]{} [**691**]{} (2009) 621.  G. Baym, H.A. Bethe and C.J. Pethick, [*Nuclear Phys.  A.*]{} [**175**]{} (1971) 225.  V. Canuto, [*Ann.  Rev. Astron.  Astrophys.*]{} [** 12**]{} (1974) 167.  E.E. Salpeter, [*Astrophys.  J.*]{} [**134**]{} (1961) 669.  J. M. Lattimer and M. Prakash, [*Astrophys.  J.*]{} [**550**]{}, 426 (2001).  J. M. Lattimer and M. Prakash, [*Phys.  Rep.*]{}, [**442**]{}, 109 (2007).  L.W. Negele and D. Vautherin, [*Nucl.  Phys.  A.*]{} [**207**]{} (1973), 298 .  D. Atta and D.N. Basu,[*Phys.  Rev. C.*]{} [**90**]{}, 035802 (2014).  J.M. Lattimer, M. Prakash, C.J. Pethick and et al., [* Phys.  Rev. Lett.*]{} [** 66**]{} (1991), L2701.  P. Haensel, A.Y. Potekhin and D.G. Yakovlev, [*Neutron Stars I, Equation of State and Structure*]{}, (New York, Springer, 2007).  Y. Xu, G.Z. Liu, H.Y. Wang and et al., [* Chin.  Phys.  Lett.*]{} [** 29**]{}(2013a) 059701.  Y. Xu, G.Z. Liu, C.Z. Liu and et al., [* Chin.  Phys.  Lett.*]{} [** 30**]{} (2013b) 129501.  N. K. Glendenning, [*Astrophys.  J.*]{} [**293**]{} (1985) 470 J. Schaffner, C. B. Dover, A. Gal and et al., [* Phys Lett B.*]{}[**71**]{} (1993) 1328.  H. Shen [*Phys.  Rev. C.*]{} [**65**]{} (2002), 035802.  F. Yang, H. Shen, [*Phys.  Rev. C.*]{} [**77**]{} (2008), 025801.  M. Dutra [*Phys.  Rev. C.*]{} [**85**]{} (2012), 035201.  P. B. Demorest, et al. [* Nature (London)*]{} [**467**]{} (2010) 1081.  Y. Sugahara and H. Toki, [*Nucl.  Phys.  A.*]{} [**579**]{} (1994), 557.  L. Geng, et al. [* Progress of Theoretic Physics*]{} [**113**]{} (2005), 785.  D. Singh, et al.[*Int.  J. Mod.  Phys.  E.*]{} [**21**]{} (2012), 1250076.  J. Lattimer and Y. Lim, [*Astrophys.  J. Lett.*]{} [** 771**]{} (2013), 51.  Z.F. Gao, X.J. Zhao, D.L. Song and et al., [* Astron.  Nachr.*]{} [** 335, No.6/7**]{} (2014) 653.  Z.F. Gao, X.-D. Li, N. Wang, et al. [* Mon.  Not.  R. Astron.  Soc.*]{} [** 456**]{} (2016),55 Z.F. Gao,N. Wang, Y. Xu, et al., [* Astron.  Nachr.*]{}[**336, No.8/9**]{} (2015) 866.  H.A. Bethe, G. Borner and K. Sato, [*Astron.&  Astrophys.*]{} [** 7**]{}(1970) 279 .  J.R. Buchler and Z. Barkat, [*Astrophys.  J. Lett.*]{} [** 7**]{}(1971) L179 .  Z. Barkat, J. R. Buchler and J. C. Wheeler, [*Astrophys.  J.*]{} [**173**]{} (1972) 183.  D.G. Ravenhall, C.D. Bennett and C.J. Pethick, [*Phys.  Rev. Lett.*]{} [** 28**]{} (1972) L978. 

Other classical matter models for the crust of a NS
===================================================

Since BPS model was developed on the basis of the semi-empirical mass formula, it’s necessary to introduce the work of Bethe, Borner & Sato (1970)[@Bethe70](hereinafter¡°BBS model¡±) that is a typical semi-empirical-mass-formular model.  In BBS model, the energy per nucleon $E$ is given by $$E=-c_{1}A+c_{2}Z^{2}A^{\frac{-1}{3}}+ c_{3}\frac{(N-Z)^2}{A}+c_{4}A^{\frac{2}{3}},
\label{A1}$$ where $N$ is the neutron number, $Z$ is the proton number, and $A=N+Z$ is the nucleon number.  The first term, the second term, the third term and the fourth term on the right-hand side of Eq.(A1) denote the volume energy, Coulomb energy, symmetry energy and surface energy, respectively; the energy constants $c_1$=16 MeV, $c_2$=0.72 MeV, $c_3$=24 MeV, and $c_4$=18 MeV. The above equation fits the experimental data very well for $A\sim 4$ to 260 after correcting for shell effects and for Wigner term[@Bethe70].  After ignoring the small neutron-proton mass difference, the electron chemical potential $\mu_{\rm e}$ (i.e., the electron Fermi energy) becomes $$\mu_{\rm e}=\mu_{\rm n}-\mu_{\rm p}=\frac{\partial E}{\partial N}- \frac{\partial E}{\partial Z},
\label{A2}~$$ From Eq.(15) in BBS model[@Bethe70], we get the relation of $A$ and $x$, $$A= \frac{c_{4}}{2c_{2}}x^{-2}=12.5 x^{-2}~.~
\label{A3}$$ where $x=Z/A$. Thus, $Y_e$ is simply expressed as a function of $A$ $$~Y_{\rm e}\approx Z/A= (\frac{12.5}{A})^{1/2}~.
\label{A4}$$ Based on Eq.(A4) and Table 2 in Section 4.1, we plot a schematic diagram of $Y_e$ vs. $A$ for relativistic electrons in BBS model and BPS model, as shown in Fig.9(a).  Combining Eq.(A4) with Table 1 in BBS model[@Bethe70], we plot a schematic diagram of $E_{\rm F}(e)$ and $\rho$ in BBS model, as shown in Fig.9(b).  In this figure we add the fitting curve of $E_{\rm F}(e)$ vs. $Log_{10}(\rho)$ from BPS model[@BPS71]. 

  ----- -----
        
   (a)   (b)
  ----- -----

From Fig.  9, in BBS model the electron fraction $Y_e$ is solely determined by nucleon number $A$, i.e., $Y_e$ monotonously decreases with $A$; whereas in BPS model $Y_e$ is determined by equilibrium nuclei and composition from EoS. The difference of $E_{\rm F}(e)$ between these two models increases with matter density.  Since the semi-empirical mass formula will not fit the experimental data when $\rho>\rho_d$, we stop comparing these two models at the higher densities above $4.3\times 10^{13}$ g cm$^{-3}$. In addition, in BBS model the neutron drip density $\rho_d=2.8\times10^{11}$ g cm$^{-3}$, and the nuclei will disappear suddenly when $\rho=4.34\times10^{13}$ g cm$^{-3}$. Due to the introduction of lattice energy, BPS model is superior to all the semi-empirical mass-formula models including BBS model. 

Considering the limit of the semi-empirical mass formula, Buchler & Barkat (1971)[@Buchler71] (hereinafter ¡°BB model¡±) and Barkat, Buchler & Wheeler (1972)[@Barkat72] (hereinafter ¡°BBW model¡±) calculated the nuclear composition and EOS, and gave the relation of $Z$ and $A$ and the expression of the surface energy by using Thomas-Fermi method.  However, both of these models cannot give definite values of $A$ and $A$ for stable nuclei, and the differences of surface-energy form between BB, BBW and BBP models are very large.  Employing Hartree-Fock and Thomas-Fermi methods, Revenhall, Bennett & Pethick (1972)[@Ravenhall72](hereinafter ¡°RBP model¡±) modified the surface energy, calculated EoS, and gave the relation of $Z$ and $\rho$. However, the expression of $Z$ and $\rho$ in RBW model is similar to that of BB model, but is different from that of BBP model. 

Partial calculations in Dura model(Type$-$2)
============================================

[^1]: zhifugao@xao.ac.cn
