Learning Scientific Programming with Python (2nd edition)
P3.2.1: First order reaction kinetics
Question P3.2.1
A molecule, A, reacts to form either B or C with first-order rate constants $k_1$ and $k_2$ respectively. That is, $$ \frac{\mathrm{d[A]}}{\mathrm{d}t} = - (k_1 + k_2)\mathrm{[A]}, $$ and so $$ \mathrm{[A]} = \mathrm{[A]_0} \mathrm{e}^{-(k_1+k_2)t}, $$ where $\mathrm{[A]_0}$ is the initial concentration of A. The product concentrations (starting from 0), increase in the ratio $\mathrm{[B]/[C]} = k_1/k_2$ and conservation of matter requires $\mathrm{[B] + [C] = [A]_0 - [A]}$. Therefore, $$ \begin{align*} \mathrm{[B]} & = \frac{k_1}{k_1+k_2}\mathrm{[A]_0} \left(1 - \mathrm{e}^{-(k_1+k_2)t}\right),\\ \mathrm{[C]} & = \frac{k_2}{k_1+k_2}\mathrm{[A]_0} \left(1 - \mathrm{e}^{-(k_1+k_2)t}\right). \end{align*} $$
For a reaction with $k_1 = 300\;\mathrm{s^{-1}}$ and $k_2 = 100\;\mathrm{s^{-1}}$, plot the concentrations of A, B and C against time given an initial concentration of reactant, $\mathrm{[A]}_0 = 2.0\;\mathrm{mol\,dm^{-3}}$.