We present a largely improved version of CRASH, a 3-D radiative transfer code
that treats the effects of ionizing radiation propagating through a given
inhomogeneous H/He cosmological density field, on the physical conditions of
the gas. The code, based on a Monte Carlo technique, self-consistently
calculates the time evolution of gas temperature and ionization fractions due
to an arbitrary number of point/extended sources and/or diffuse background
radiation with given spectra. In addition, the effects of diffuse ionizing
radiation following recombinations of ionized atoms have been included. After a
complete description of the numerical scheme, to demonstrate the performances,
accuracy, convergency and robustness of the code we present four different test
cases designed to investigate specific aspects of radiative transfer: (i) pure
hydrogen isothermal Stromgren sphere; (ii) realistic Stromgren spheres; (iii)
multiple overlapping point sources, and (iv) shadowing of background radiation
by an intervening optically thick layer. When possible, detailed quantitative
comparison of the results against either analytical solutions or 1-D standard
photoionization codes has been made showing a good level of agreement. For more
complicated tests the code yields physically plausible results, which could be
eventually checked only by comparison with other similar codes. Finally, we
briefly discuss future possible developments and cosmological applications of
the code.Comment: 17 pages, 14 figures, accepted for pubblication in MNRAS, high res
figures available at
http://www.arcetri.astro.it/science/cosmology/IGM/radtrans.htm