A method for automatic particle tracking in a three-dimensional flow field