is an option for MoleculeMatchQ that determines whether stereochemistry should be ignored for pattern matching.
IgnoreStereochemistry
is an option for MoleculeMatchQ that determines whether stereochemistry should be ignored for pattern matching.
Details
- With the default setting IgnoreStereochemistryFalse, molecules will only match each other if they have the same stereochemistry.
Examples
Basic Examples (3)
With IgnoreStereochemistryTrue, enantiomers will match:
MoleculeMatchQ[
Molecule["(S)lactic acid"],
Molecule["(R)lactic acid"],
IgnoreStereochemistry -> True
]Use IgnoreStereochemistryFalse to discriminate different stereoisomers:
MoleculeMatchQ[
Molecule["(S)lactic acid"],
Molecule["(R)lactic acid"],
IgnoreStereochemistry -> False
]With IgnoreStereochemistryTrue, cis–trans isomers will match:
MoleculeMatchQ[
Molecule["cis-2-butene"],
Molecule["trans-2-butene"],
IgnoreStereochemistry -> True
]Use IgnoreStereochemistryFalse to discriminate different stereoisomers:
MoleculeMatchQ[
Molecule["cis-2-butene"],
Molecule["trans-2-butene"],
IgnoreStereochemistry -> False
]A molecule object with undefined stereochemistry will not match one with defined stereo:
mol1 = Molecule["(S)lactic acid"];
mol2 = Molecule["lactic acid"];
MoleculeMatchQ[mol1, mol2]When stereochemistry is ignored, the molecules match:
MoleculeMatchQ[mol1, mol2, IgnoreStereochemistry -> True]See Also
History
Text
Wolfram Research (2021), IgnoreStereochemistry, Wolfram Language function, https://reference.wolfram.com/language/ref/IgnoreStereochemistry.html.
CMS
Wolfram Language. 2021. "IgnoreStereochemistry." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/IgnoreStereochemistry.html.
APA
Wolfram Language. (2021). IgnoreStereochemistry. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/IgnoreStereochemistry.html
BibTeX
@misc{reference.wolfram_2026_ignorestereochemistry, author="Wolfram Research", title="{IgnoreStereochemistry}", year="2021", howpublished="\url{https://reference.wolfram.com/language/ref/IgnoreStereochemistry.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_ignorestereochemistry, organization={Wolfram Research}, title={IgnoreStereochemistry}, year={2021}, url={https://reference.wolfram.com/language/ref/IgnoreStereochemistry.html}, note=[Accessed: 12-June-2026]}