  Neutron stars are one of the most exotic objects in the universe and a unique
laboratory to study the nuclear matter above the nuclear saturation density. In
this work, we study the equation of state of the nuclear matter within a
relativistic model subjected to a strong magnetic field. We then apply this EoS
to study and describe some of the physical characteristics of neutron star,
especially the mass-radius relation and chemical compositions. To study the
influence of a the magnetic field and the hyperons in the stellar interior, we
consider altogether four solutions: two different values of magnetic field to
obtain a weak and a strong influence, and two configurations: a family of
neutron stars formed only by protons, electrons and neutrons and a family
formed by protons, electrons, neutrons, muons and hyperons. The limit and the
validity of the results found are discussed with some care. In all cases the
particles that constitute the neutron star are in $\beta$ equilibrium and zero
total net charge. Our work indicates that the effect of a strong magnetic field
has to be taken into account in the description of magnetars, mainly if we
believe that there are hyperons in their interior, in which case, the influence
of the magnetic field can increase the mass by more than 10%. We have also seen
that although a magnetar can reach 2.48$M_{\odot}$, a natural explanation of
why we do not know pulsars with masses above 2.0$M_{\odot}$ arises. We also
discuss how the magnetic field affects the strangeness fraction in some
standard neutron star masses and, to conclude our paper, we revisit the direct
URCA process related to the cooling of the neutron stars and show how it is
affected by the hyperons and the magnetic field.
