  Magnetic fields have been found to have an inherent capability of acting
against gravity. An important question posed in the literature is whether
presence of a magnetic field can alter the dynamics of a gravitational collapse
and prevent the final formation of a singularity. Inhomogeneous models of
collapse have not been explored significantly in this context. In the present
work we investigate the role of magnetic fields in the evolution of
inhomogeneous cylindrically symmetric models. We use an approach based on the
Raychaudhuri equation for such an analysis. We show that it is quite possible
for the magnetic field to avert the gravitational collapse in these models.
