{* xplor_to_iupac Convert XPLOR to IUPAC nomenclature for amino acids, including the following: methylene proton index (2,1) to (2,3) {ASN,GLN}-NH2 proton index (2,1) to (1,2) methyl proton index to clockwise (1,2,3) G. Gippert, 1997, Physical Chemistry 2, Lund University garry@bor.fkem2.lth.se Severely modified from the original source. Probably topology file dependent. Instructions for use: Copy this file to "xplor_to_iupac" and insert a line "@xplor_to_iupac" somewhere after the "segment" command, and before the "write structure" command in the XPLOR "generate protein structure file" input script. See http://www.fkem2.lth.se/~garry/local_info.html (click on "XPLOR Atom nomenclature" for more details. *} ! vector do (name="H") (name HN) for $id in id (tag) loop iupac {* alpha methylenes *} vector ident (store1) (byres(id $id) and name ha%) if ($select = 2) then vector do (name = " HA2") (store1 and name ha2) vector do (name = " HA3") (store1 and name ha1) end if {* beta methylenes *} vector ident (store1) (byres(id $id) and name hb%) if ($select = 2) then vector do (name = " HB2") (store1 and name hb2) vector do (name = " HB3") (store1 and name hb1) end if {* gamma methylenes *} vector ident (store1) (byres(id $id) and name hg%) if ($select = 2) then vector do (name = " HG2") (store1 and name hg2) vector do (name = " HG3") (store1 and name hg1) end if vector ident (store1) (byres(id $id) and name hg1%) if ($select = 2) then vector do (name = "HG12") (store1 and name hg12) vector do (name = "HG13") (store1 and name hg11) end if {* delta methylenes and NH2s *} vector ident (store1) (byres(id $id) and not resname phe and not resname tyr and not resname trp and not resname his and name hd%) if ($select = 2) then vector do (name = " HD2") (store1 and name hd2) vector do (name = " HD3") (store1 and name hd1) end if vector ident (store1) (byres(id $id) and resname asn and name hd2%) if ($select = 2) then vector do (name = "DDDD") (store1 and name hd21) vector do (name = "HD21") (store1 and name hd22) vector do (name = "HD22") (store1 and name DDDD) end if {* epsilon methylenes and NH2s *} vector ident (store1) (byres(id $id) and not resname phe and not resname tyr and not resname trp and not resname his and name he%) if ($select = 2) then vector do (name = " HE2") (store1 and name he2) vector do (name = " HE3") (store1 and name he1) end if vector ident (store1) (byres(id $id) and resname gln and name he2%) if ($select = 2) then vector do (name = "EEEE") (store1 and name he21) vector do (name = "HE21") (store1 and name he22) vector do (name = "HE22") (store1 and name EEEE) end if {* the methyl section is included for completeness *} vector ident (store1) (byres(id $id) and name hb%) if ($select = 3) then vector do (name = " HB1") (store1 and name hb2) vector do (name = " HB2") (store1 and name hb1) end if vector ident (store1) (byres(id $id) and name hg1%) if ($select = 3) then vector do (name = "GGGG") (store1 and name hg11) vector do (name = "HG11") (store1 and name hg12) vector do (name = "HG12") (store1 and name GGGG) end if vector ident (store1) (byres(id $id) and name hg2%) if ($select = 3) then vector do (name = "GGGG") (store1 and name hg21) vector do (name = "HG21") (store1 and name hg22) vector do (name = "HG22") (store1 and name GGGG) end if vector ident (store1) (byres(id $id) and name hd1%) if ($select = 3) then vector do (name = "DDDD") (store1 and name hd11) vector do (name = "HD11") (store1 and name hd12) vector do (name = "HD12") (store1 and name DDDD) end if vector ident (store1) (byres(id $id) and name hd2%) if ($select = 3) then vector do (name = "DDDD") (store1 and name hd21) vector do (name = "HD21") (store1 and name hd22) vector do (name = "HD22") (store1 and name DDDD) end if vector ident (store1) (byres(id $id) and name he%) if ($select = 3) then vector do (name = " HE1") (store1 and name he2) vector do (name = " HE2") (store1 and name he1) end if vector ident (store1) (byres(id $id) and name hz%) if ($select = 3) then vector do (name = " HZ1") (store1 and name hz2) vector do (name = " HZ2") (store1 and name hz1) end if end loop iupac