From: Axel Kohlmeyer (akohlmey_at_cmm.chem.upenn.edu)
Date: Mon Nov 12 2007 - 06:38:01 CST

On Mon, 12 Nov 2007, Philipp Schön wrote:

PS>
PS> Dear users,

dear philipp,

PS>
PS> using this command:
PS> "set wat [atomselect 2 "water and ((name \"OH2\") and (within 3.2 of name \"O40\"))"]"
PS> I try to get all oxygens (OH2) in water around all oxygens named O40. What I get is the water oxygens only with the O40's not included.
PS> However, the "within" command should include the selection itself by default. What do I miss here?

you require that both, "name OH2", and "within 3.2 of name O40"
are true. this excludes "name O40". please try:

set wat [atomselect 0 (name OH2 and within 3.2 of name O40) or name O40]

BTW no need for the additional quotes and backslashes
they are only needed to introduce perl-style regular expressions,
but you are using plain strings. also the "water and" should be
redundant.

cheers,
   axel.
 
PS>
PS> Cheers
PS> Philipp
PS> _______________________________________________________________________
PS> Jetzt neu! Schützen Sie Ihren PC mit McAfee und WEB.DE. 3 Monate
PS> kostenlos testen. http://www.pc-sicherheit.web.de/startseite/?mc=022220
PS>
PS>

-- 
=======================================================================
Axel Kohlmeyer   akohlmey_at_cmm.chem.upenn.edu   http://www.cmm.upenn.edu
   Center for Molecular Modeling   --   University of Pennsylvania
Department of Chemistry, 231 S.34th Street, Philadelphia, PA 19104-6323
tel: 1-215-898-1582,  fax: 1-215-573-6233,  office-tel: 1-215-898-5425
=======================================================================
If you make something idiot-proof, the universe creates a better idiot.