Elimination of nitrogen from coal in pyrolysis and hydropyrolysis: a study of coal and model chars