Encapsulation of monomers, homodimers and heterodimers of amides and carboxylic acids in three non-covalent assemblies