N-Dimensional Fast Marching Method