How to write a program that will provide me all possible products of a chemical reaction?

3 visualizaciones (últimos 30 días)
Hello,
I need to write a program that will generate possible products from a defined starting material.
The problem is more complex, but let’s start with the following:
If there is this structure component in a molecule:
R1-CH=CH-CH2-CH=CH-R2
it will always get oxidized to the peroxide:
R1-CH=CH-CH(OOH)-CH=CH-R2
No matter what R1 and R2 are.
So from CH3-CH=CH-CH2-CH=CH-CH3 I want to get CH3-CH=CH-CH(OOH)-CH=CH-CH3, but I want to be able to provide any starting material and get a proper product.
Thank you!
  2 comentarios
Stephen23
Stephen23 el 11 de En. de 2017
A universal solution to this is would be incredibly complex. People employ huge supercomputers to try and predict what molecules do:
"The best material model of a cat is another, or preferably the same, cat" Norbert Wiener
Maggie
Maggie el 11 de En. de 2017
I work on oxidation of unsaturated lipids. It gives a few general rules how they can be oxidized (let’s say around 10 chemical reactions). For the easiest compounds with just 2 double bonds I can obtain around 70 different products. For the most difficult cases with 6 double bonds I expect to have around 500 products. I believe it’s a lot to write all the structures on paper, but not too much for a computer. Unfortunately (of fortunately, but not today) I’m an organic chemist and I don’t have much knowledge about Matlab and programming (I am trying to learn it fast now). As an output from the program I need just simple structures and molecular formulas to use it for my MS analysis. I don’t need absolute configuration, minimal energy or anything like this.
Simple example:
Let’s say I oxidize alcohols. I’m telling the program I have following rules for oxidation:
1) R1-CH2-OH -> R1-CH=O (to aldehyd)
2) R1-CH=O -> R1-COOH (to carboxylic acid)
So then I say to the program I have ethanol and it gives me two structures and their molecular formulas: CH3CHO (C2H4O) and CH3COOH (C2H4O2). That’s all I need.
I would really appreciate any tips about how to start writing a program like this.

Iniciar sesión para comentar.

Respuesta aceptada

Walter Roberson
Walter Roberson el 11 de En. de 2017
It appears to me that you have enough carbon and hydrogen and oxygen there that among the possible outcomes, given multiple input molecules, are the plastics. They might not be favored in most conditions, but you asked for possible rather than likely. Plastics can grow indefinitely. Therefore you could only potentially list all of the possible outcomes if you restricted the number of input molecules, and the solution would involve all of the possible arrangement of atoms that satisfied bonding criteria together with whatever maximum charge you were willing to accept.
With the hydrogen and oxygen there, water molecules is one outcome. Remember to allow for all of the arrangements of water molecules polar covalently bound, because in a sense each arrangement is a different substance.
  1 comentario
Walter Roberson
Walter Roberson el 11 de En. de 2017
If you have transformation rules, that This arrangement is allowed to produce This and That products, then whether a particular output can be produced from the inputs is something that can be examined in terms of a topic known in computing ad Formal Grammers (a topic very closely related to Parsing). This is the same category as the study of analyzing sentences in terms of "adjective phrase" and "comma apposition" and so on: given a set of rules, and an input, can you recognize the input through the rules, which might require rewriting in other forms according to the rules?
Once a complete set of analysis and transformation rules is built up, the analysis system can be "run in reverse" to "generate" all of the possible valid "sentences".
For you, this would mean that if you had the transformation rules and a description of the inputs (some states cannot be reached with small numbers of input molecules) then you could generate all of the possible products.
It can help in such a system to have a well defined ordering of components so that you do not get lost in endless permutations of the possibilities, but that is not necessarily strictly required.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Chemistry en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by