Fix Lee distance calculation