  We present structure calculations of neutral and singly ionized Mg clusters
of up to 30 atoms, as well as Na clusters of up to 10 atoms. The calculations
have been performed using density functional theory (DFT) within the local
(spin-)density approximation, ion cores are described by pseudopotentials. We
have utilized a new algorithm for solving the Kohn-Sham equations that is
formulated entirely in coordinate space and, thus, permits straightforward
control of the spatial resolution. Our numerical method is particularly
suitable for modern parallel computer architectures; we have thus been able to
combine an unrestricted simulated annealing procedure with electronic structure
calculations of high spatial resolution, corresponding to a plane-wave cutoff
of 954eV for Mg. We report the geometric structures of the resulting
ground-state configurations and a few low-lying isomers. The energetics and
HOMO-LUMO gaps of the ground-state configurations are carefully examined and
related to their stability properties. No evidence for a non-metal to metal
transition in neutral and positively charged Mg clusters is found in the regime
of ion numbers examined here.
