Docking is the process by which two or several molecules form a complex. Docking involves the geometry of the molecular surfaces, as well as chemical and energetical considerations. In the mid-eighties, Connolly proposed a docking algorithm matching surface knobs with surface depressions. Knobs and depressions refer to the extrema of the Connolly function, which is defined as follows. Given a surface M bounding a three-dimensional domain X, and a sphere S centered at a point p of M, the Connolly function is equal to the solid angle of the portion of S containing within X. We recast the notions of knobs and depressions in the framework of Morse theory for functions defined over twodimensional manifolds. First, we study the critical points of the Connolly function for smooth surfaces. Second, we provide an efficient algorithm for computing the Connolly function over a triangulated surface. Third, we introduce a Morse-Smale decomposition based on Forman’s discrete Morse theory, and p...