Consequences of unwittingly reinventing an idea
Ignorance is not plagiarism. If you write that "To the best of my knowledge" the algorithm is new, you imply that you researched the matter duly (I would suggest to consult some experts if you are kind of an outsider to the field) and found no prior publication. If such a publication exists, it will not be plagiarism. It may be embarrassing, but not a career killer by any means (see first comment to your question).
However, if you know that a suggestion exists for the one-dimensional case, you should state that: "This algorithm has been previously suggested for the one-dimensional case by XXXX." You can also qualify this statement to better highlight what your work adds: "...but no proof of convergence was offered." or "Here I generalize the algorithm to n dimensions and provide a proof of convergence."
It is the duty of reviewers (in fact, part of THE main duty is to see if the paper makes a original contribution). If you have made an honest effort to find previous work, talked to your colleagues and/or advisor ( if applicable), your job is done. Plus most good ideas are rediscovered ALL THE TIME, in different subfields, different context etc. However, don't be this guy: Rediscovery of calculus in 1994: what should have happened to that paper?