Hydrothermal reactions of organic compounds in the presence of minerals: a study of carboxylic acids