A computer-implemented of quantifying binding affinity between a ligand and a receptor molecule, the method comprising: identifying a ring structure within the ligand, the ring structure being either an entire ring, a fused ring or a portion of a ring or of a fused ring; classifying the ring structure based on the spatial relationship of the ring structure to its ambient surroundings when the ligand is bound to the receptor molecule, in which the number of close contacts at different distances between receptor atoms and the two ring faces are determined, an initial classification of the ring is made based on the numbers of these contacts, and this initial classification is then followed by calculation of a scoring function, dependent upon other parameters, which enables the final classification as buried, solvent exposed, or solvent exposed on one surface, wherein the scoring function enabling classification of the ring structure as buried, solvent exposed, or solvent exposed on one surface, includes the use of a parameter corresponding to a hydrophobic interaction of the ring structure or part thereof with the receptor molecule; and quantifying the binding affinity between the ligand and the receptor molecule based on the classification of the ring structure, in which quantifying the binding affinity includes a step that scores hydrophobic interactions between one or more ligand atoms and one or more receptor atoms by awarding a bonus for the presence of hydrophobic enclosure of one or more atoms of said ligand by the receptor molecule, said bonus being indicative of enhanced binding affinity between said ligand and said receptor molecule. identifying a ring structure within the ligand, the ring structure being either an entire ring, a fused ring or a portion of a ring or of a fused ring; classifying the ring structure based on the spatial relationship of the ring structure to its ambient surroundings when the ligand is bound to the receptor molecule, in which the number of close contacts at different distances between receptor atoms and the two ring faces are determined, an initial classification of the ring is made based on the numbers of these contacts, and this initial classification is then followed by calculation of a scoring function, dependent upon other parameters, which enables the final classification as buried, solvent exposed, or solvent exposed on one surface, wherein the scoring function enabling classification of the ring structure as buried, solvent exposed, or solvent exposed on one surface, includes the use of a parameter corresponding to a hydrophobic interaction of the ring structure or part thereof with the receptor molecule; and quantifying the binding affinity between the ligand and the receptor molecule based on the classification of the ring structure, in which quantifying the binding affinity includes a step that scores hydrophobic interactions between one or more ligand atoms and one or more receptor atoms by awarding a bonus for the presence of hydrophobic enclosure of one or more atoms of said ligand by the receptor molecule, said bonus being indicative of enhanced binding affinity between said ligand and said receptor molecule.