One of the possible potential candidates for describing the universe's rapid
expansion is modified gravity. In the framework of the modified theory of
gravity f(R,G), the present work features the materialization of anisotropic
matter, such as compact stars. Specifically, to learn more about the physical
behavior of compact stars, the radial, and tangential pressures as well as the
energy density of six stars namely HerXβ1, SAXJ1808.4β3658, 4U1820β30,
PSRJ16142230, VELAXβ1, and CenXβ3 are calculated. Herein, the
modified theory of gravity f(R,G) is disintegrated into two parts i.e. the
tanh hyperbolic f(R) model and the three different f(G) model. The study
focuses on graphical analysis of compact stars wherein the stability aspects,
energy conditions, and anisotropic measurements are mainly addressed. Our
calculation revealed that, for the positive value of parameter n of the model
f(G), all the six stars behave normally.Comment: Some changes have been made. " To appear in International Journal of
Geometric Methods in Modern Physics