1 Introduction

The Einstein-Maxwell field equations play a significant role in several different applications in relativistic astrophysics. The study of Bonnor (1965) showed that the electric field is essential in describing the equilibrium of compact bodies, and charge may even halt gravitational collapse. The necessary requirement in relativistic astrophysics is to build stable equilibrium solutions of the Einstein-Maxwell system, and to generate models of different astrophysical objects with strong gravitational fields by choosing appropriate matter distributions. Models built in this way maybe useful in describing the physical characteristics of compact stellar objects such as gravastars, neutron stars, quark stars, etc. Glendening (2000) has observed that all macroscopic bodies are charge neutral or they may possess a small amount of charge, so that the structure of the stellar body is not much affected in the latter stages of its evolution. Nevertheless, note that there are early phases in the evolution of a compact star, in which immediate charge neutrality is not possible, but it is attained in later stages. This situation arises, for example, at the birth of a compact star from the core collapse supernova. In this case the electromagnetic field substantially affects the structure of the star. A large charge distribution can disrupt the structure of the stellar body. Ray et al. (2003) showed from the balance of forces and the strength of their coupling, that such huge charge disrupting the stellar structure, has very little effect in the equation of state of the content. Taking the protons as the carrier of the charge in the stellar body, they demonstrated that one extra proton in a sea of 1018 baryons, can generate a total charge that will modify the stars structure. It is important to point out, that there has been considerable recent improvements in observations relating to compact stellar bodies. The mass of many compact stellar bodies have been found with a fair degree of precision; the main challenge is to accurately determine the radius of the star. Some recent studies have developed improved techniques which give the accurate mass and the radius of some compact stellar objects. This improved observational information about such compact objects has generated much interest about the internal matter content and consequently the spacetime geometry.

Solutions of the Einstein-Maxwell system with an equation of state are desirable in the description of realistic astrophysical objects. The importance of an equation of state in a stellar model has been comprehensively investigated by Varela et al. (2010). Studies in quark stars involve physics at high densities described by a linear equation of state. Various aspects of the phenomenological MIT Bag model with linear quark equation of state have been considered by Witten (1984), Chodos et al. (1974) and Weber (2005). There have been some attempts made recently to find exact analytic solutions of the Einstein-Maxwell system for bound matter configurations with a linear equation of state. These include the treatments of Ivanov (2002), Sharma and Maharaj (2007a), Thirukkanesh and Maharaj (2008), Mafa Takisa and Maharaj (2013) and Thirukkanesh and Ragel (2013). Models with a quadratic equation of state are rare because of the increased nonlinearity in the field equations. The models of Feroze and Siddiqui (2011) and Maharaj and Mafa Takisa (2012) are recent examples that satisfy a quadratic equation of state.

The study of the structure of compact stars requires understanding of the equation of state describing the stellar matter under extreme conditions. High mass compact stars, reported recently in the literature, provide strong constraints on the properties of ultradense matter beyond the saturation nuclear density. Even for the 1.44 M mass or so compact stars, we can still debate over the nature of the star, whether it is composed of nuclear matter, or quark matter or a hybrid of the both. For the hybrid scenario, the core is made of quark matter which has a softer equation of state, and the outside is a stiffer nuclear matter equation of state. In nuclear physics or particle physics, it is often quite challenging to find a single equation of state of matter that smoothly matches the quark matter core with the outer nuclear matter. In this context, it is also worth mentioning that Cottam et al. (2002) and Özel (2006) showed that most of the current equations of state describing quark matter are too soft and so are unable to explain the existence and stability of massive neutron stars. Rodrigues et al. (2006) pointed out that only stiff equations of state describing normal nuclear matter at high densities would be capable of explaining the stability of high compact star masses with M∼2 M. Consequently a lot of work has been carried out in hybrid stars with modification to the equation of state in the past years in order to address this issue. In our work, we have chosen a quadratic equation of state, which is softer at low densities and stiffer at higher densities, thus accommodating for a hybrid scenario, as we are more interested in finding the exact solution in general relativity.

In this paper we utilise the quadratic equation of state in a class of exact models found by Maharaj and Mafa Takisa (2012) to study physical features. This enables us to consider deviations from the linear case and the changes to observable quantities such as the mass of the star.

We use an exact solution of the Einstein-Maxwell system found earlier by Maharaj and Mafa Takisa (2012) to study physical features and show that this model is consistent with observed objects. We intend to study the effects on a compact object arising from nonlinearities in a quadratic equation of state. In Sect. 2, the Einstein-Maxwell field equations are considered and the Maharaj and Mafa Takisa (2012) model is presented. Some recent observations are reviewed in Sect. 3. In Sect. 4, masses and radii are generated for particular parameter values in the absence of charge. These are presented in Table 1. In Tables 24 in Sect. 5, we generate masses, radii and central densities for charged and uncharged bodies. The connection to the astrophysical object PSR J1614-2230 is made. Graphical plots of the physical quantities are made in Sect. 6, and we discuss the significance of the quadratic term in the equation of state.

Table 1 Variation of mass, radius and central density in term of γ in the absence of charge. The parameter γ is variable and α is fixed
Table 2 Different masses and radii for PSR J1614-2230 for the uncharged case. The parameters γ and α are variable

2 The model

The line element for a static spherically symmetric interior matter distribution has the form

$$ ds^{2} = -e^{2\nu} dt^{2} + e^{2\lambda} dr^{2} + r^{2}\bigl(d\theta^{2} + \sin^{2}{\theta} d\phi^{2}\bigr), $$
(1)

where ν=ν(r) and λ=λ(r) are the potentials. The energy momentum tensor for an anisotropic charged imperfect fluid sphere is of the form

$$ T^{ab}=\operatorname{diag} \biggl(-\rho-\frac{1}{2}E^2, p_r-\frac{1}{2}E^2, p_t + \frac{1}{2}E^2, p_t+ \frac{1}{2}E^2 \biggr), $$
(2)

which describes a distribution with anisotropy and charge. The quantities ρ, p r , p t and E are the density, radial pressure, tangential pressure and electric field intensity respectively. For a physically reasonable star we require that the matter distribution satisfies a barotropic equation of state p r =p r (ρ); the quadratic form is given by

$$ p_r = \gamma\rho^{2}+\alpha\rho-\beta, $$
(3)

where β, α and γ are constants. When γ=0 then we regain a linear equation of state. The constants γ and α constrain the density via the sound speed causality condition (\(\rho\leq\frac{1+\alpha}{2\gamma}\)). The gravitational interactions on the matter distribution and the electromagnetic field are determined by the Einstein-Maxwell system

$$\begin{aligned}& G^{ab} = kT^{ab}, \end{aligned}$$
(4)
$$\begin{aligned}& F_{ab;c}+F_{bc;a}+F_{ca;b} = 0, \end{aligned}$$
(5)
$$\begin{aligned}& F^{ab}_{;b} = 4\pi J^{a}, \end{aligned}$$
(6)

where we have set k=8π (G=c=1) in geometrised units. The system (4)–(6) is highly nonlinear and governs the behaviour of the relativistic star in the presence of the charge.

For the line element (1), the Einstein-Maxwell field equations (4)–(6) become

$$\begin{aligned}& 8\pi\rho+ \frac{1}{2}E^{2}=\frac{1}{r^{2}} \bigl[ r\bigl(1-e^{-2\lambda}\bigr) \bigr]', \end{aligned}$$
(7)
$$\begin{aligned}& 8\pi p_r -\frac{1}{2}E^{2}=- \frac{1}{r^{2}} \bigl( 1-e^{-2\lambda} \bigr) + \frac{2\nu'}{r}e^{-2\lambda}, \end{aligned}$$
(8)
$$\begin{aligned}& 8\pi p_t + \frac{1}{2}E^{2}=e^{-2\lambda} \biggl( \nu'' + \nu'^{2}+ \frac{\nu'}{r}\lambda' -\frac{\lambda'}{r} -\nu\biggr), \end{aligned}$$
(9)
$$\begin{aligned}& \sigma = \frac{1}{4\pi r^{2}} e^{-\lambda} \bigl(r^{2}E\bigr)', \end{aligned}$$
(10)

where σ=σ(r) is named the proper charge density and primes indicate differentiation with respect to r. In the presence of charge the gravitational mass is defined by

$$ M(r)=4\pi\int^{r}_{0} \biggl( \rho(\omega)_{\mathit{unch}}+\frac{E^{2}}{8\pi} \biggr)\omega^2 d\omega, $$
(11)

where ρ(ω) unch is the uncharged energy density (E=0). We remark that Eqs. (7)–(10) imply the generalised Tolman-Oppenheimer equation

$$ \frac{dp_{r}}{dr}=\frac{2}{r}(p_{t}-p_{r})-r( \rho+p_{r})\nu^{\prime}+\frac{E}{4\pi r^{2}} \bigl( r^{2}E \bigr)^{\prime}, $$
(12)

showing that the gradient \(\frac{dp_{r}}{dr}\) is influenced by the anisotropy and charge. The above equation is known as the Bianchi identity representing hydrostatic equilibrium of the charged anisotropic matter. These quantities can drastically change physical quantities such as the surface tension as shown by Sharma and Maharaj (2007b) and Horvat et al. (1984).

In this paper, we extend the linear treatment of Mafa Takisa et al. (2014) by investigating the Maharaj and Mafa Takisa (2012) model, and we include the effect of the quadratic term on the structure of observed objects. On using the quadratic equation of state (3), an exact solution to the Einstein-Maxwell system (7)–(10) has the form

$$\begin{aligned}& e^{2\lambda} = \frac{1+ar^2}{1+br^2}, \end{aligned}$$
(13)
$$\begin{aligned}& e^{2\nu} = A^{2}D^{2} \bigl(1+ar^2 \bigr)^{2m}\bigl[1+br^2 \bigr]^{2n} \\& \hphantom{e^{2\nu} =}{}\times\exp\bigl[2F(r)\bigr], \end{aligned}$$
(14)
$$\begin{aligned}& \rho= \frac{(2a-2b)(3+ar^2)-sa^{2}r^{4}}{16\pi(1+ar^2)^{2}}, \end{aligned}$$
(15)
$$\begin{aligned}& p_{r} = \gamma\rho^{2}+\alpha\rho-\beta, \end{aligned}$$
(16)
$$\begin{aligned}& p_{t} = p_{r}+\Delta, \end{aligned}$$
(17)
$$\begin{aligned}& 8\pi\Delta= \frac{4r^2(1+br^2)}{1+ar^2} \biggl[\frac {m(m-1)a^{2}}{(1+ar^2)^{2}} \\& \hphantom{8\pi\Delta=}{}+\frac{2mnab}{(1+ar^2)(1+br^2)} + \frac{ma{F}'(r)}{r(1+ar^2)} \\& \hphantom{8\pi\Delta=}{} +\frac{b^{2}n(n-1)}{(1+br^2)^{2}} + \frac{nbF'(r)}{r(1+br^2)} \\& \hphantom{8\pi\Delta=}{} + \frac{F''(r)}{2r^2}-\frac{F' (r)}{2r^3}+\frac{F'(r)^{2}}{4r^2}\biggr] \\& \hphantom{8\pi\Delta=}{} + \biggl[-\frac{2(a-b)r^2}{(1+ar^2)^{2}}+\frac {4(1+br^2)}{(1+ar^2)} \biggr] \\& \hphantom{8\pi\Delta=}{} \times\biggl[\frac{am}{1+ar^2}+ \frac{bn}{1+br^2} + \frac{F'(r)}{2r} \biggr] \\& \hphantom{8\pi\Delta=}{} -\frac{\gamma}{32 \pi} \biggl[\frac {(a-b)(3+ar^2)-sa^{2}r^{4}}{2(1+ar^2)^{2}} \biggr]^{2} \\& \hphantom{8\pi\Delta=}{} -\frac{1}{2(1+ar^2)^{2}}\bigl[2(a-b)+sa^{2}r^{4} \\& \hphantom{8\pi\Delta=}{}-16 \pi\beta\bigl(1+ar^2\bigr)^{2}\bigr] \\& \hphantom{8\pi\Delta=}{} -\alpha\biggl[\frac{2(a-b)(3+ar^2)-sa^{2}r^{4}}{2(1+ar^2)^{2}} \biggr], \end{aligned}$$
(18)
$$\begin{aligned}& E^{2}= \frac{sa^{2}r^{4}}{(1+ar^2)^{2}}, \end{aligned}$$
(19)
$$\begin{aligned}& \sigma^{2} = \frac{4sa^2(1+br^2)(2+ar^2)^{2}}{\pi(1+ar^2)^{5}}. \end{aligned}$$
(20)

The mass function is

$$\begin{aligned} M(r) =& \frac{1}{8} \biggl[\frac{4(a-b)r^3}{(1+ar^2)} \\ & {} +\frac{sr(-15-10ar^2+2a^{2}r^{4})}{3a(1+ar^2)} \\ & {} +\frac{5s\arctan(\sqrt{ar^2})}{a^{3/2}} \biggr]. \end{aligned}$$
(21)

In the above A, a, b, and s are constants. The quantities F(r) and the constants m and n are given by

$$\begin{aligned}& F(r) = \gamma\biggl[\frac{2(2b-a)(1+ar^2)+(b-a)}{2(1+ar^2)^{2}} \biggr] \\ & \hphantom{F(r) =}{} -s\gamma\biggl[ \frac{(a-b)^{2}(ar^2+2)}{4(a-b)(1+ar^2)^{2}} -\frac{a(2a+s)(1+ar^2)}{4(a-b)(1+ar^2)^{2}} \biggr] \\ & \hphantom{F(r) =}{} -s\gamma\biggl[\frac{s(a-b)+3sb(1+ar^2)}{32(a-b)^{2}(1+ar^2)^{2}} \biggr] \\ & \hphantom{F(r) =}{} +\frac{ar^2}{16b}\bigl[s^{2}\gamma-2s(1+\alpha)-4\beta \bigr], \\ & m = -\frac{s(1+\alpha)}{8(b-a)}+\frac{\alpha}{2} \\ & \hphantom{m =}{} +\gamma\bigl[2(a-b)\bigr]^{2} \biggl[\frac{b^{2}}{(b-a)^{3}}+ \frac{b}{(b-a)^{2}}+ \frac{1}{4} \biggr] \\ & \hphantom{m =}{} +\frac{s\gamma}{8(a-b)^{3}} \bigl[(a-b)\bigl[2s(a-b)+a+b\bigr] \\ & \hphantom{m =}{} -6ab^{2}+2b^{3}(2a-1) \bigr], \\ & n = \frac{(1+\alpha)(a-b)}{4b}-\frac{2\alpha(a-b)}{4(b-a)} + \frac {\beta(a-b)}{4b^{2}} \\ & \hphantom{n =}{} +\gamma\bigl[2(a-b)\bigr]^{2} \biggl[\frac{b^{2}}{(b-a)^{3}}+ \frac{b}{(b-a)^{2}}+ \frac{1}{4} \biggr] \\ & \hphantom{n =}{} +\frac{s\gamma}{16b^{2}(b-a)^{3}} \bigl[a^{4}(s+4b) \\ & \hphantom{n =}{} +2b\bigl(6a^{2}b^{2}-2a^{3}b\bigr) \bigr] +\frac{sa^{2}(1+\alpha)}{8b^{2}(b-a)}. \end{aligned}$$

The exact solution (13)–(20) of the Einstein-Maxwell system is expressed in terms of elementary functions, which helps in the physical analysis.

We observe that the parameters a, b, s, have the dimension of length−2. This suggests that in numerical calculations we should utilise the following transformations:

$$\tilde{a}=a \mathcal{L}^{2},\qquad\tilde{b}=b\mathcal{L}^{2},\qquad \tilde{s}=s \mathcal{L}^{2}, $$

where \(\mathcal{L}\) is a parameter with dimension of length. The requirements for a physically relevant star, in the absence of charge, are given by Delgaty and Lake (1998); the conditions for a charged star were considered by Fatema and Murad (2013) and Murad and Fatema (2013).

The values of \(\tilde{a}\), \(\tilde{b}\), \(\tilde{s}\) should be chosen in the way that the charged, anisotropic star is well behaved. The energy density ρ should be positive inside the stellar object. The radial pressure p r should vanish at the boundary of the sphere where p r (ε)=0 and ε is the boundary. The tangential pressure p t should be positive in the interior of the stellar object. The gradient of pressure \(\frac{dp_{r}}{dr}<0\) in the interior of the stellar object. The speed of sound should respect the condition \(v^{2}=\frac{dp_{r}}{d\rho}\leq1\). At the centre the radial pressure and the tangential pressure should be equal (p r (0)=p t (0)) and the measure of anisotropy should vanish (Δ(0)=0). The metric functions e2λ, e2ν and the electric field intensity E should remain positive and regular in the interior of the stellar object. At the centre the ρ(0)=ρ c must be finite and positive. The energy condition ρp r −2p t >0 should be satisfied within the interior of the stellar object. At the boundary r=ε we require

$$\begin{aligned}& e^{2\nu(\varepsilon)}=1-\frac{2{\mathcal{M}}}{\varepsilon}+\frac {Q^{2}}{\varepsilon^{2}}, \\& e^{2\lambda(\varepsilon)}= \biggl(1-\frac{2{\mathcal {M}}}{\varepsilon}+ \frac{Q^{2}}{\varepsilon^{2}} \biggr)^{-1}, \\& M(\varepsilon)=\mathcal{M}, \end{aligned}$$

for continuity of the potentials.

The interior spacetime is described by the Reissner-Nordström metric

$$\begin{aligned} ds^{2} =& - \biggl(1-\frac{2\mathcal{M}}{r}+ \frac{Q}{r^2} \biggr) dt^{2} \\ &{}+ \biggl(1-\frac{2\mathcal{M}}{r}+\frac{Q}{r^2} \biggr)^{-1} dr^{2} \\ &{} + r^{2}\bigl(d\theta^{2} + \sin^{2}{\theta} d \phi^{2}\bigr). \end{aligned}$$
(22)

The spacetime (1) and (22) must match smoothly at the stellar boundary r=ε. Then from the above we obtain the conditions

$$\begin{aligned}& 1-\frac{2{\mathcal{M}}}{\varepsilon}+\frac {Q^{2}}{\varepsilon^{2}}= \frac{1+a\varepsilon^2}{1+b\varepsilon^2}, \end{aligned}$$
(23)
$$\begin{aligned}& \biggl(1-\frac{2{\mathcal{M}}}{\varepsilon}+\frac {Q^{2}}{\varepsilon^{2}} \biggr)^{-1} = A^{2}D^{2} \bigl(1+ar^2 \bigr)^{2m} \bigl[1+br^2\bigr]^{2n} \\& \hphantom{\biggl(1-\frac{2{\mathcal{M}}}{\varepsilon}+\frac {Q^{2}}{\varepsilon^{2}} \biggr)^{-1} =}{}\times\exp\bigl[2F(r)\bigr]. \end{aligned}$$
(24)

This is a system of two equations in the parameters a, b, s, A, D, m, n, α, β and γ for a specified radial distance ε. There is sufficient freedom in the parameters to ensure that (23)–(24) is always satisfied.

3 Recent observations

Jacoby et al. (2005) and Verbiest et al. (2008) utilised the detection of the general relativistic Shapiro delay to calculate the masses of both the neutron star and its companion in a binary system. This was done to a high degree of precision. Demorest et al. (2010) followed this approach to make radio timing observations of the binary millisecond pulsar PSR J1614-2230, which displayed a strong Shapiro delay signature. They implied that the pulsar mass 1.97±0.08 M is the highest mass measured to date with accurate precision. Freire et al. (2011) utilised the Arecibo and Green Bank radio timing observations to make a very precise measurement of the apsidal motion, and found new constraints on the orbital orientation of the binary system. This was done in the content of a full determination of the relativistic Shapiro delay. With the help of a comprehensive analysis, they found new restrictions on the mass of the pulsar PSR J1903+0327 and its companion and presented it’s accurate mass as 1.667±0.02 M. Recently Rawls et al. (2011) presented an improved method for determining the mass of neutron stars in eclipsing X-ray pulsar binaries. They used a numerical code based on Roche geometry which they supplemented with new spectroscopic and photometric data for 4U 1538-52. This allowed for more accurate modelling of the eclipse duration leading to improved values for the neutron star masses: 1.77±0.08 M for Vela X-1, 1.29±0.05 M for LMC X-4 and 1.29±0.08 M for Cen X-3.

There have been similar observations for other stars. However for this investigation, we restrict ourselves to pulsar PSR J1614-2230, a binary millisecond large pulsar.

4 Stellar masses

In this section, we use the analytical solutions (13)–(21), with the quadratic equation of state (16), to study the effect of the quadratic term γ on the model. We wish to compare the outputs to the recent results of Mafa Takisa et al. (2014) who considered the linear case. We choose γ such that the causality condition \(v^{2}=\frac{dp_{r}}{d\rho}\leq1\) is satisfied and take the parameter values: \(\tilde{a}=53.34\), \(\mathcal{L}=43.245\mbox{ km}\), α=0.33, β=0.5α×1015 g cm−3 and \(\tilde{s}=0.0\). We are concerned here with uncharged bodies. The parameter α has the fixed value \(\alpha=\frac{1}{3}\) but the quadratic parameter γ is allowed to vary. We obtain different masses, radii and central densities for different parameter values. The results are given in Table 1. We note that the compactification factor is in the range of \(\frac{M}{R}\) \(\sim\frac {1}{10}\) to \(\frac{1}{4}\); this corresponds to neutron stars and ultra-compact stars as pointed out by Mafa Takisa and Maharaj (2013). We find that a variety of stellar masses are generated which correspond to acceptable values of the central density ρ c and the \(\frac{M}{R}\) ratio. Of particular interest are the values γ=0.140, α=0.33, R=10.30, \(\frac{M}{R}=0.191\) and ρ c =3.45×1015 g cm−3 which give the corresponding mass of the PSR J1614-2230. These values are underlined in Table 1. Therefore this astronomical object is consistent with a quadratic equation of state. Note that the same mass is contained in the analysis of Mafa Takisa et al. (2014) with a linear equation of state.

5 The pulsar J1614-2230

The analysis of Mafa Takisa et al. (2014) was shown to be consistent with observational objects such as Vela X-1, SMC X-1, Cen X-3, PSR J1903+327 and PSR J1614-2230. Our intention in this treatment is to focus on the particular object PSR J1614-2230 (1.97±0.08 M), since this mass is so far the highest yet measured with accurate precision. We have shown in Sect. 4 that PSR J1614-2230 is consistent with a nonlinear equation of state. Our analysis can be similarly applied to other pulsar objects. We compute the quantities M, \(\frac{M}{R}\), R and ρ c by allowing the parameters γ and α to be variable. The relevant values are contained in Tables 24. The masses in Table 2 are uncharged whilst the masses in Tables 3 and 4 are charged. The underlined values in these tables represent the corresponding values that we expect for the object PSR J1614-2230 when γ=0.

Table 3 Different masses of PSR J1614-2230 and radius for the charged case. The parameters γ and α are variable
Table 4 Different masses and radii for PSR J1614-2230 for the charged case. The parameters γ and α are variable

Tables 24 have been generated with the objective of regaining a central density of ρ c =3.45 which is associated with PSR J1614-2230. In Table 2 the quantities M, \(\frac{M}{R}\) and R have been found in the absence of charge. Different values of the parameters γ and α produce uncharged massive objects which are physically reasonable. In Table 3 we similarly generate stellar structures which are reasonable in the presence of charge \(\tilde {s}=7.5\). The values in Table 4 are also consistent with observations but with a higher value for the charge \(\tilde{s}=14.5\). The presence of charge in Tables 3 and 4 also produces physically reasonable charged objects for different values of the parameters γ and α. The presence of charge has an effect on the mass and the radius of the object.

6 Discussion

This physical analysis is completely new, extending the Mafa Takisa et al. (2014) result and showing interesting features that arise when the quadratic term is present in the equation of state. To illustrate the effect of the quadratic term of the equation of state with γ≠0 in the interior of PSR J1614-2230, we have plotted the energy density ρ, radial pressure p r , tangential pressure p t , the measure of anisotropy Δ, speed of sound \(v^{2}=\frac {dp_{r}}{d\rho}\), and the quantity ρp r −2p t in Figs. 16 respectively. The presence of γ has only a slight effect on the radial pressure, the tangential pressure and the measure of anisotropy profiles. The profiles in the presence of charge and non-zero γ are similar to the Mafa Takisa et al. (2014) analysis with a linear equation of state. The speed of sound is positive and decreasing throughout the star and the causality condition is maintained in Fig. 5. The variation ρp r −2p t is positive within the star in Fig. 6 and the energy condition is satisfied. For E=0 and γ=0.200, we point out a small of increase for the radius and the mass of 4 % and 4.5 % respectively. The corresponding results for the charged (E≠0) case are given in Tables 3 and 4. For the maximum value of γ=0.200, we note the increase of 8 % for the radius and 9 % for the mass with E=7.5. It is clear that the quadratic term γ leads to an increase of 11 % in the mass of a stellar object for the maximum value of E=14.5. We observe that for both cases E=0 and E≠0, the quadratic term γ has the effect of increasing the compactification factor \(\frac{M}{R}\) slightly. We have shown the relevance of the quadratic equation of state to relativistic objects, in particular to the observed object PSR J1614-2230.

Fig. 1
figure 1

Energy density ρ(r) versus radius

Fig. 2
figure 2

Radial pressure p r versus radius

Fig. 3
figure 3

Tangential pressure p t versus radius

Fig. 4
figure 4

Anisotropy Δ versus radius

Fig. 5
figure 5

Speed of sound dp r / versus radius

Fig. 6
figure 6

Variation of ρp r −2p t versus radius