extraction of magnesium from its ore