How to get the previous atom_idx from the two fragments that match with the considered atoms in parent? #3669
-
Hello! I am trying to find the atom or atom index in the two fragments that match with the considered atoms in parent after I broke the bond between them. The below is the source code:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
@IchiruTake: I'm not 100% sure what you want to do, but a relatively easy way to get the environment around an atom after breaking a bond from it is to use Here's a gist demonstrating how that works: Does that help? |
Beta Was this translation helpful? Give feedback.
@IchiruTake: I'm not 100% sure what you want to do, but a relatively easy way to get the environment around an atom after breaking a bond from it is to use
Chem.FragmentOnBonds()
to break the bond(s) you want without changing the atom indices.Here's a gist demonstrating how that works:
https://gist.github.com/greglandrum/93a209c0155d82f0fde07d14b4a14fbe
Does that help?