Two techniques to solve ODEs in Python are Euler's method and with an integrator such as Scipy.integrate ODEINT. Euler's method uses a loop to repeat the concentration calculation for a specified number of cycles as it steps forward in time. The selectivity is calculated to determine the fraction of desirable product. Both solutions are shown on a plot. The initial concentration of B is adjusted to maximize the selectivity of C.
Course Material: https://apmonitor.com/che263/index.ph...
Github Repository (see HW05.ipynb): https://github.com/APMonitor/learn_py...
Schedule: https://apmonitor.com/che263/index.ph...
Solution Videos: https://apmonitor.com/che263/index.ph...