Pierce point minimization and optimal torch path determination in flame cutting