One would think that initial configuration should not significantly impact the final optimized geometry. Starting with two moieties, the final "optimized" geometry is not unique and depends highly on how they are placed initially. Is there a way to avoid this? Otherwise one could never be sure that they have ended up with the global minimum.
Starting with two moieties, the final "optimized" geometry is not unique and depends highly on how they are placed initially. Is there a way to avoid this?
Yes and no. No, because, as OP anticipated, starting from an input geometry the optimisation algorithm will indeed find the closest (from the algorihtm point of view) local minimum and not necessarily the global one. And yes, because by performing an extensive conformational analysis, one in principle can find structures that correspond to all possible local minima and then identify the global one.
It is not possible to derive an algorithm that finds the global optimum independent of the initial structure. This is a general fact of non-convex optimization. The potential energy surfaces of stable compounds are not globally convex because the "dissociation" energy of any two components is finite at infinite separation.
Although there are so-called "global" optimization methods, no method that does not search every point of the search space can in general guarantee to have found the global optimum (i.e., there is always a function for which the algorithm fails to find the global optimum or visits every point in the domain).
That said, global optimization methods putatively reduce the sensitivity of the result to the initial point. There are a large number of these, some of which are deterministic (lists definitely not exhaustive since it's missing my favorite level-filling method :-).
Finally I would like to point out that the specific formulation of your problem influences how well your algorithm works, e.g., the chosen coordinate system or how any constraints are enforced. The lack of global optimization is actually useful if a certain bonding topology is supposed to be maintained; otherwise, t-butane would always optimize to n-butane, for instance.