Adsorption of CO2 and CH4 on a magnesium-based metal organic framework.