Calculation of the free energy of association of nucleic acid bases in vacuo and water solution