How to recognize (and SUM) also chemical formulas which have more occurrences of elements such as AsH2(C4H9) = where you have H on two places or in CH2COOH where actually only one of the "same" elements will be counted??
It is good explained on these threads below, but it isn't included when you have compounds with repetitive elements, where is necessary to SUM it properly, otherwise, one element is always omitted.
So those threads are only for counting elements and simply calculate of compounds, but not for compounds with brackets, and repetitive elements.
How to count up elements in excel
Calculating Molecular Weight Using Excel
And is it possible to do it without VBA coding?
This is coding that I have been using.
=E$2*MAX(IFERROR(IF(FIND(E$1&ROW($1:$99);$A3);ROW($1:$99);0);0);IFERROR(IF(FIND(E$1&CHAR(ROW($65:$90));$A3&"Z");1;0);0))
I included the data set example, in red you can see problematic actually. It is "matching" all the elements without brackets and this is not what I want. In column B is only sum of all the components from right side.