The influence of Mg on the C adsorption on Ni( 100): A DFT study