Mg3MNi2 (M = Al, Ti, Mn) ternary intermetallic compounds with cubic structure are a new type of potential hydrogen storage alloys. Using ab initio density functional theory (DFT) calculations, the energetics and electronic structures of Mg3MNi2 (M = Al, Ti, Mn) compounds are systematically investigated. The optimized structural parameters including lattice constants and internal atomic positions are close to experimental data determined from X-ray powder diffraction. The calculated results of formation enthalpy ΔHform show that the stabilities...