# How to obtain product ratio from energy differences via Boltzmann statistics

I am currently calculating some reactions and I would like to express the ratio of the products in per cents. I am using the Boltzmann statistic in the following way:

1. The probability $p_j$ of a particle $j$ to be in a state with the energy $\varepsilon_j$ is given as $\text{(1a,a')}$. The statement $\text{(1b)}$ must therefore hold, whereas $\text{(1c)}$ also follows. \begin{align} \text{(a)} && p_j &= \frac{N_j}{N}\\ \text{(a')} && \%P_j &= \frac{N_j}{N}\cdot100\%\\ \text{(b)} && 1 &= \sum_j p_j\\ \text{(c)} && N &= \sum_j N_j\\\tag1 \end{align}

2. For any system with $k$ particles, that are in thermal equilibrium, the probability to find particle $j$ can be expressed via the Boltzmann statistics $(2)$, where $Z$ is the canonical partition function, the inverse temperature is $\beta = (\mathcal{k}_\mathrm{B}\cdot T)^{-1}$ and the degeneracy coefficient is $g_j$. $$p_j=g_j\cdot \frac1Z\cdot \exp\left\{-\beta\varepsilon_j\right\}\tag2$$

3. I can assume that a state with the energy $\varepsilon_0$ is the ground state, therefore no other state can have lower energy. I can therefore assign the ground state as the baseline and switch to relative energies, as demonstrated in in $(3)$. \begin{align} \text{def.}&& \varepsilon_0 &= 0.0\\ && \varepsilon_j &= \varepsilon_0 + \Delta\varepsilon_j' \\ \therefore && \varepsilon_j &= \Delta\varepsilon_j'\\\tag3 \end{align}

4. As a consequence I can express the canonical partition function in terms of the ground state probability. \begin{align} && p_0 &= g_0\cdot \frac1Z\cdot \exp\left\{-\beta\varepsilon_0\right\}\\ \therefore && p_0 &= g_0\cdot \frac1Z\\ \equiv && Z &= \frac{g_0}{p_0}\\\tag4 \end{align} The canonical partition function is also defined in $(5)$, but I am quite sure this one would not lead me to my desired goal. $$Z = \sum_l^\infty g_l\cdot\exp\left\{-\beta\varepsilon_l\right\}\tag5$$

5. I can express any probability in terms of the ground state probability following from $(2-4)$. \begin{align} && p_j &= \frac{g_j}{g_0}\cdot p_0\cdot \exp\left\{-\beta\Delta\varepsilon_j'\right\}\\\tag6 \end{align}

6. As a last step I will switch to macroscopic numbers, as my quantum chemical calculations give me $\Delta{}G$ values. \begin{align} \text{def.} && \Delta{}G_j &= \mathcal{N}_\mathrm{A}\cdot \Delta\varepsilon_j'\\ && p_j &= \frac{g_j}{g_0}\cdot p_0\cdot \exp\left\{-\frac{\Delta{}G_j}{\mathcal{R}\cdot{}T}\right\}\\\tag7 \end{align}

# Finally the questions:

• How do I obtain $p_0$ in a way, that I can use it in spreadsheet software like libreOffice calc, so that I satisfy $\text{(1b)}$? If I insert this equation, I would have to solve it iteratively, as I have the variable to solve for on both sides. I could then go ahead and use $Z$ directly. \begin{align} p_0 &= 1 - p_j -\sum_{i\neq0,j} p_i\\ \color{\red}{p_j} &= \frac{g_j}{g_0}\cdot \left(1 - \color{\red}{p_j} -\sum_{i\neq0,j} p_i\right)\cdot \exp\left\{-\frac{\Delta{}G_j}{\mathcal{R}\cdot{}T}\right\}\\ \end{align}
• Am I making correct assumptions along the way?
• Could the following work? Assign an arbitrary probability to $p_0$, to obtain an arbitrary value for $[p_j]^\ddagger$. What would be reasonable? I picked $0.25$ as an example. Can I then normalize to get the total percentages? \begin{align} \text{def.} && p_0 &= [p_0]^\ddagger\ =\ 0.25\\ && [p_j]^\ddagger &= \frac{g_j}{g_0}\cdot \color{\green}{0.25}\cdot \exp\left\{-\frac{\Delta{}G_j}{\mathcal{R}\cdot{}T}\right\}\\ \text{Norm.} && \%P_j &= \frac{[p_j]^\ddagger}{\sum_i [p_i]^\ddagger}\cdot 100\% \end{align} This would maybe break down the iterative procedure to a two step process. Is this procedure really equivalent to $\text{(1a')}$?

• Is the number of states finite or infinite? And why do you think (5) will not work? Also, are there degeneracies? – Silvio Levy Jul 25 '14 at 6:34
• It seems to me that (5) -- with the replacement of $l$ by $j$ of course -- is saying the same thing as the procedure you outlined in your last bullet point, but taking out the initial "guess" for $p_0$ (or if you prefer, think of it as taking the initial guess to be 1 instead of $0.25$, then finding the factor by which you must divide it, which is $Z$). – Silvio Levy Jul 25 '14 at 6:49
• @SilvioLevy In theory the number of states to be considered can be infinite. In praxis, I would not consider any state that is like 25 kJ higher in energy that the reference state, i.e. I would truncate the sum in (5). However, this number can still become quite large, depending on the system size and I am not very good at handling quite large spreadsheets. I do not understand your second comment, how would that change the sum to be infinite. (also there was a small typo) – Martin - マーチン Jul 25 '14 at 6:56
• @SilvioLevy I did not see the edit before it was too late to edit my comment. Thank you for this statement, which I now understand. I am however not sure if it would solve the two step process or the iterative solving of the equations. – Martin - マーチン Jul 25 '14 at 7:03
• My second comment is unrelated to the finite/infinite question. All I'm saying is that I think your approach in the last bullet point is 100% correct, and that it is also 100% equivalent to computing the partition function in (5) -- or an approximation of it, if the number of states is infinite. The fraction in your last equation, $[p_j]^\ddagger/\sum_i[p_i]^\ddagger$, is $1/Z$ in the case $j=0$, the ground state. Unless I'm missing some subtlety. [Likewise I didn't see your 2nd reply before writing this; but since it's a clarification, I'm leaving it.] – Silvio Levy Jul 25 '14 at 7:06

There are two aspects to the problem: theory and practice. In theory you have a complete answer in the form of the partition function (5). If you know all the energy levels and their degeneracies, you can at least in principle carry out the sum, and you've solved the problem. One case where this is practical is where you have a (small) number $n$ of particles with spin $\frac12$ interacting with each other; there are $2^n$ configurations, each with potentially a different energy, but you can still carry out an explicit sum.

That example probably does not help in your case; in chemistry you usually have infinitely many energy levels. As you point out in the comments, you can cut off the sum at some point. This may still not give you a practical solution, either because the sum up to the cutoff is still too hard to calculate, or because the cutoff error is unacceptably high (say, if levels are closely spaced and the sum in (5) converges very slowly).

But assuming there is a reasonable cutoff, the method may very well be practical.

With this in mind here are the answers to your questions at the end:

How do I obtain $p_0$ in a way, that I can use it in spreadsheet software like libreOffice calc, so that I satisfy (1b) ? If I insert this equation, I would have to solve it iteratively, as I have the variable to solve for on both sides.

The "iterative" aspect is a red herring and the difficulty of having $p_0$ on both sides is illusory, since the $p_i$ are all proportional to $p_0$, and the proportionality factors are known and independent of $p_0$. You can simply factor out $p_0$, which gives $p_0$ multiplied by the inverse of the partition function; then you equate this expression to 1 and (if you can calculate the partition function) you are done.

Am I making correct assumptions along the way?

Yes, I think you've stated the theory and the assumptions quite accurately.

Could the following work? Assign an arbitrary probability to $p_0$, to obtain an arbitrary value for $[p_j]^\ddagger$. What would be reasonable? I picked 0.25 as an example. Can I then normalize to get the total percentages?

Yes, that would work; the formulas you wrote under this item are correct. You can save yourself the trouble of choosing a number like 0.25, as this number cancels out of the fraction $\frac{[p_j]^\ddagger}{\sum_i [p_i]^\ddagger}$ -- notice that it appears as a factor in the numerator and also in each summand in the denominator, where it can be factored out.

One last remark: if you have access to symbolic algebra software like Matlab, Maple or Mathematica, you may be able to do the calculation more conveniently than with libreOffice calc. If you're very lucky, you may even find the exact solution to your infinite sum! (Not all sums can be solved exactly, of course; still it might be worth a try, and you can sometimes guide the software. It helps to be familiar with generating functions and summation techniques as explained for example in the book Concrete Mathematics, by Graham, Knuth and Patashnik.)

Good luck!