  We propose a new ray-tracing algorithm to measure the weak lensing shear and
convergence fields directly from N-body simulations. We calculate the
deflection of the light rays lensed by the 3-D mass density field or
gravitational potential along the line of sight on a grid-by-grid basis, rather
than using the projected 2-D lens planes. Our algorithm uses simple analytic
formulae instead of numerical integrations in the computation of the projected
density field along the line of sight, and so is computationally efficient,
accurate and straightforward to implement. This will prove valuable in the
interpretation of data from the next generation of surveys that will image many
thousands of square degrees of sky.
