  Synchrotron radiation x-ray absorption and emission spectroscopy techniques,
complemented by high-resolution transmission electron microscopy methods and
density functional theory calculations are employed to investigate the effect
of Mn in Al$_{x}$Ga$_{1-x}$N:Mn samples with an Al content up to 100%. The
atomic and electronic structure of Mn is established together with its local
environment and valence state. A dilute alloy without precipitation is obtained
for Al$_{x}$Ga$_{1-x}$N:Mn with Al concentrations up to 82%, and the surfactant
role of Mn in the epitaxial process is confirmed.
