• No results found

Chapter 2 Multi-Objective Self-Optimisation of Continuous Flow Reactors

2.1 Introduction

The majority of algorithms used for the self-optimisation of continuous flow reactors in the last decade were designed to minimise or maximise a single objective function. However, when developing a process it is important to consider multiple economic and environmental process metrics.58 Commonly employed process

metrics and their equations are displayed in Table 4.

The % yield [Eq (15)] is a ubiquitous metric used by chemists during reaction optimisation and is widely considered very useful for evaluating reaction efficiency. However, by itself the % yield fails to adequately account for productivity and downstream processing costs. For example, a high yield could be obtained by using a large excess of reagents over a prolonged period of time, thus resulting in a costly work-up procedure and low productivity respectively. Rather, the % yield, purity [Eq (16)] and space-time yield (STY) all need to be considered for a more complete economic analysis, where the STY [Eq (17)] is expressed as the mass of product produced per unit volume per unit of time.89 Nevertheless, none of these metrics by

themselves or in combination are sufficient for driving the development of sustainable processes.

Atom economy [Eq (18)] was introduced as an easily accessible metric for synthetic chemists to assess waste generation. This metric considers how much of the starting materials are incorporated into the desired product, but ignores key factors such as the molar excess of reactants and the use of solvents and reagents.90

Because of this, two other metrics were proposed to give better measures of environmental impact: E-factor (or mass intensity) and reaction mass efficiency (RME). The E-factor [Eq (19)] is the ratio of the total mass of waste to the mass of the desired product, where the total mass of waste includes everything used within the process such as reactants, reagents, solvents and catalysts.91 In contrast, the

RME [Eq (20)] is a combination of yield, atom economy and molar excess. An analysis of these metrics across 28 different chemistries led to the conclusion that the RME is probably the most useful metric for evaluating how β€˜green’ a process is.92

63

Table 4. Metrics for evaluating the economic and environmental impact of a

chemical process. m = mass, V = volume of reactor, tres = residence time, MW =

molecular weight, SM = starting material.

Process Metric Equation

% Yield π‘šπ‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘Γ— 100

𝐸π‘₯𝑝𝑒𝑐𝑑𝑒𝑑 π‘šπ‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘ (15)

% Purity π‘šπ‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘Γ— 100

π‘šπ‘šπ‘–π‘₯π‘‘π‘’π‘Ÿπ‘’ (16)

Space-time yield (STY) π‘šπ‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘

𝑉 Γ— π‘‘π‘Ÿπ‘’π‘  (17) Atom Economy π‘€π‘Šπ‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘ βˆ‘π‘› π‘€π‘Šπ‘†π‘€(𝑖) 𝑖=1 (18) E-Factor π‘šπ‘šπ‘€π‘Žπ‘ π‘‘π‘’ π‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘ (19)

Reaction Mass Efficiency (RME) π‘€π‘Šπ‘π‘Ÿπ‘œπ‘‘π‘’π‘π‘‘Γ— 𝑦𝑖𝑒𝑙𝑑

π‘€π‘Šπ‘†π‘€1+ (π‘€π‘Šπ‘†π‘€2Γ— π‘’π‘žπ‘’π‘–π‘£π‘†π‘€2) (20)

The process metrics outlined above are frequently conflicting, which means that the optimum for each metric is located in a different region of experimental space. One approach to this problem is to conduct multiple single objective optimisations to identify the optimum for each metric. This one-objective-at-a-time approach was used to optimise the yield, throughput and cost for a Heck-Matsuda reaction using a modified NMSIM algorithm (Scheme 6).65 Notably, optimising for

the different criteria gave significantly different values of performance with respect to % yield. However, this approach does not consider the objectives simultaneously, and therefore fails to identify a satisfactory compromise between the conflicting performance criteria.

64

In a separate study, a poor 42% conversion was observed for a Paal-Knorr reaction which had been optimised for productivity (Scheme 7a).57 In contrast to the

one-objective-at-a-time approach, a penalty function was introduced to penalise conversions of less than 85%. This method successfully identified a compromise between the objectives where the conversion increased to 81% at the cost of a 31% decrease in productivity. Nevertheless, the authors concluded that an a priori economic analysis of the process would be required to determine the desired weighting on the objectives before conducting a final optimisation. Similarly, Fitzpatrick et al. combined throughput, conversion and consumption into a single objective function [Eq (21)] during optimisation of an Appel reaction (Scheme 7b), where Ο„ = residence time, z = [2.08], p = [PPh3O], s = [2.07], x = CBr4 equiv. and y =

PPh3 equiv.66 However, the a priori determination of adequate weightings for each

term proved difficult, and initially led to skewed results. These examples highlight some major problems with the scalarisation of multiple objectives: (i) quantitative a priori knowledge is needed to adequately specify objective weightings, thus requiring additional experiments; (ii) minor changes to the weightings can result in significant changes to the solution achieved; (iii) only one optimal result is obtained, which is dependent on the chosen objective function and does not reveal the complete trade-off between conflicting performance criteria.

Scheme 7. Reactions optimised via the scalarisation of multiple objectives: (a)

Paal-Knorr reaction optimised for throughput and conversion using a penalty function; (b) Appel reaction optimised for throughput, conversion and consumption using a weighted function [Eq (21)].

65

(21)

The true solution to a multi-objective optimisation problem is a set of non-dominated solutions known as the Pareto front (Figure 20), where a non-dominated solution is one which cannot be improved without having a detrimental effect on the other. Hence, a multi-objective maximisation problem where variable vector x = {x1,…,xn} is formulated as follows. In objective space X, find

variable vector x* which maximises K objective functions z(x*) = {z1(x*),…,zK(x*)},

where objective space X is restricted by bounds on the variables. A feasible solution a dominates another feasible solution b (a ≻ b) when zi(a) β‰₯ zi(b) for i = 1,…,K and

zj(a) > zj(b) for at least one objective j.93 In contrast to scalarisation, the

identification of a set of solutions and presentation of a front enables a posteriori decisions to be made regarding the desired optimum based on knowledge of the complete trade-off.

Figure 20. An example of a system with two conflicting maximisation performance

criteria z1 and z2. It is infeasible to find the utopian point where both z1 and z2 are at

their optimal values. The points on the Pareto front are non-dominated solutions, as z1 or z2 cannot be improved without having a detrimental effect on the other.

66

The genetic algorithms discussed in Chapter 1 can readily be modified to handle multi-objective optimisation problems, the most widely used of which is the fast non-dominated-sort genetic algorithm (NSGA-II).94 NSGA ranks the population

using Pareto dominance, where solutions on local fronts closer to the Pareto front are ranked better i.e. lower. Notably, NSGA-II penalises solutions near dense sections of the Pareto front to ensure a diverse Pareto front is obtained (rank = number of dominating solutions + 1). For example, in Figure 21a solution i is dominated by solutions c, d and e so is given a rank of 4, whereas solutions f, g and h are only dominated by one solution so are given a rank of 2. Furthermore, NSGA-II is an elitist algorithm, which means it will always select solutions with the better ranks for crossover and mutation to create the next generation. If two solutions have the same rank, then diversity is prioritised and the solution with the higher crowding distance is selected. The crowding distance is calculated by averaging the side length of a cuboid with a perimeter defined by the solutions nearest non-dominated neighbours as vertices (Figure 21b).

a b c d e f g h i z1 z2 z1 z2 1 1 1 1 1 4 2 2 2 i i+1 i-1 cuboid (a) (b)

Figure 21. Graphical representations of adaptations to the NSGA algorithm to

ensure a diverse front is identified: (a) ranking system; (b) crowding distance. Most problems of interest in chemistry represent expensive-to-evaluate functions, particularly in the pharmaceutical industry where the focus is on low-volume, high-value products. Although NSGA-II is capable of solving multi-objective problems, the population size, and therefore total number of evaluations required, are too large to be practical for self-optimisation. Hence, a machine learning algorithm called multi-objective active learner (MOAL) was designed for expensive-to-evaluate multi-target optimisation tasks.95 The algorithm

67

with 14 input variables, simultaneously targeting a conversion of β‰₯99% and particle diameter of 100 Β± 1 nm.63 Similarly, the Thompson sampling efficient

multi-objective optimisation (TSEMO) algorithm was recently reported to converge on the Pareto front within a small budget of evaluations, and compared favourably against other Bayesian multi-objective optimisers for in silico test problems.96