This paper presents the theoretical aspects of a new tomographic traveltime inversion algorithm that does not require ray tracing. I show that the major computational tasks that are involved in the nonlinear optimization process and that are conventionally done through ray tracing can be efficiently done by solving the first-order partial differential equations with finite difference methods. The new algorithm allows us to use arbitrary basis functions for expanding the slowness model, and ensures that the traveltimes of the first arrivals are properly used in the inversion process. Although the algorithm is described in two dimensions, it can be generalized to three dimensions without much difficulty. Because we can also compute the amplitudes of the first arrivals with the finite difference method (Vidale and Houston, 1990; Zhang, 1991a), we cau use the same approach to invert the absorption field of a medium.