ABSTRACT: A series of ab initio (density functional) calculations were carried out on side chains of a set of amino acids, plus water, from the (intracellular) gating region of the KcsA K(+) channel. Their atomic coordinates, except hydrogen, are known from X-ray structures [D.A. Doyle, J.M. Cabral, R.A. Pfuetzner, A. Kuo, J.M. Gulbis, S.L. Cohen, B.T. Chait, R. MacKinnon, The structure of the potassium channel: molecular basis of K(+) conduction and selectivity, Science 280 (1998) 69-77; R. MacKinnon, S.L. Cohen, A. Kuo, A. Lee, B.T. Chait, Structural conservation in prokaryotic and eukaryotic potassium channels, Science 280 (1998) 106-109; Y. Jiang, A. Lee, J. Chen, M. Cadene, B.T. Chait, R. MacKinnon, The open pore conformation of potassium channels. Nature 417 (2001) 523-526], as are the coordinates of some water oxygen atoms. The 1k4c structure is used for the starting coordinates. Quantum mechanical optimization, in spite of the starting configuration, places the atoms in positions much closer to the 1j95, more tightly closed, configuration. This state shows four water molecules forming a "basket" under the Q119 side chains, blocking the channel. When a hydrated K(+) approaches this "basket", the optimized system shows a strong set of hydrogen bonds with the K(+) at defined positions, preventing further approach of the K(+) to the basket. This optimized structure with hydrated K(+) added shows an ice-like 12 molecule nanocrystal of water. If the water molecules exchange, unless they do it as a group, the channel will remain blocked. The "basket" itself appears to be very stable, although it is possible that the K(+) with its hydrating water molecules may be more mobile, capable of withdrawing from the gate. It is also not surprising that water essentially freezes, or forms a kind of glue, in a nanometer space; this agrees with experimental results on a rather different, but similarly sized (nm dimensions) system [K.B. Jinesh, J.W.M. Frenken, Capillary condensation in atomic scale friction: how water acts like a glue, Phys. Rev. Lett. 96 (2006) 166103/1-4]. It also agrees qualitatively with simulations on channels [A. Anishkin, S. Sukharev, Water dynamics and dewetting transitions in the small mechanosensitive channel MscS, Biophys. J. 86 (2004) 2883-2895; O. Beckstein, M.S.P. Sansom, Liquid-vapor oscillations of water in hydrophobic nanopores, Proc. Natl Acad. Sci. U. S. A. 100 (2003) 7063-7068] and on featureless channel-like systems [J. Lu, M.E. Green, Simulation of water in a pore with charges: application to a gating mechanism for ion channels, Prog. Colloid Polym. Sci. 103 (1997) 121-129], in that it forms a boundary on water that is not obvious from the liquid state. The idea that a structure is stable, even if individual molecules exchange, is well known, for example from the hydration shell of ions. We show that when charges are added in the form of protons to the domains (one proton per domain), the optimized structure is open. No stable water hydrogen bonds hold it together; an opening of 11.0 A appears, measured diagonally between non-neighboring domains as glutamine 119 carbonyl O-O distance. This is comparable to the opening in the MthK potassium channel structure that is generally agreed to be open. The appearance of the opening is in rather good agreement with that found by Perozo and coworkers. In contrast, in the uncharged structure this diagonal distance is 6.5 A, and the water "basket" constricts the uncharged opening still further, with the ice-like structure that couples the K(+) ion to the gating region freezing the entrance to the channel. Comparison with our earlier model for voltage gated channels suggests that a similar mechanism may apply in those channels.