Efficient computation of environmentally extended input–output scenario and circular economy modeling

Industrial ecology tools are increasingly being used in ways that require high computational times. In the policy arena, this becomes problematic when practitioners want to live‐test various alternatives in a responsive and web‐based platform. In research, computational times come into play when analyzing large systems with multiple interventions or when requiring many runs for, for example, Monte Carlo simulations. We demonstrate how the computational time of a number of commonly used industrial ecology tools can be reduced significantly, potentially by multiple orders of magnitude. Our case study was the optimization of scenario calculations in Environmentally Extended Input–Output Analysis (EEIOA). Instead of recalculating the Leontief inverse after individual changes to the interindustry relations, as is done traditionally in EEIOA scenario analysis, we give formulations to find the total value of the change in the environmental indicators in one calculation step. We illustrate these novel formulations both for a simple hypothetical system and for the full EXIOBASE EEIO model. The use of explicit formulas decreases the computational time to the degree that it becomes possible to carry out these analyses in live or web‐based environments. For our case study, we find an improvement of up to four orders of magnitude.

High computational complexity, thus computational time, makes it nearly impossible to simulate many scenarios with many users, combined scenarios, CE interventions, or perform Monte Carlo simulations. This is because currently, circular interventions are often modeled by using wellestablished methods of element-wise updates in the technical coefficient matrix (A) in the EEIO tables (Miller & Blair, 2009;Rose, 1984), followed by the recalculation of the Leontief inverse (L). The computational demands can increase exponentially, because, in order to solve the IO system, the Leontief inverse matrix is computed (Boulding & Leontief, 1942). The operation of inverting a matrix becomes challenging with an increasing system size (Chen, Gu, Zhang, & Mittra, 2018), making the analysis of many scenarios computationally expensive. 1 In this paper, we demonstrate that significant reductions in computational time can be achieved by applying to EEIOA a theorem first proved by Woodbury in 1950(Woodbury, 1950. Other authors have investigated the use of matrix partitioning and the Sherman-Morrison formula (a special case of the Woodbury formula for a single row or column update) for various applications (Chen et al., 2018;Lai & Vemuri, 1997;Saberi Najafi & Shams Solary, 2006), including Miller and Blair (Miller & Blair, 2009). However, the focus of the former works is not applicable because of their specificity to other scientific fields, while the latter concerns the study of effects of single changes or error in the data, and does not include formulas for multiple changes or errors.
To the best of our knowledge, this paper is the first to use the Woodbury formula in the context of industrial ecology, and to provide explicit formulas for the changes in the environmental indicators under CE interventions in EEIOA. We note that the optimization presented in this paper are applicable to LCA and IOA related matrix inversions, where reduced computational times are also of interest. 2 The remainder of this paper is as follows. In Section 2, we briefly review the fundamentals of EEIOA and introduce notations. In Section 3, we present the direct calculation of a generalized CE intervention that occurs as changes in the interindustry relations. The proposed formulations are based on pre-intervened IO tables, thereby avoiding calculation of new Leontief inverses. Section 4 illustrates the use of the formulas for both a simplified example case, and for the full EXIOBASE model. Finally, Section 5 concludes the paper. The Supporting Information provides additional details on how the proposed formulation compares to other methods. The MATLAB codes supplementary to this study are located in a permanent repository on Zenodo. 3

BACKGROUND: FUNDAMENTALS OF ENVIRONMENTALLY EXTENDED INPUT-OUTPUT ANALYSIS
The Leontief model for IOA depicts interindustry relationships within an economy and shows how output from one industrial sector becomes input to another sector (Boulding & Leontief, 1942). Matrix A contains the multipliers for the interindustry inputs required to supply one unit of sector output. A certain total economic output is also required to satisfy a given level of final demand y. In order to produce 1 unit of good, sector j uses a ij units from sector i. Furthermore, sector i sells some of its output to final consumers (final demand), y i . In the following equations, we assume that the economy is subdivided into n products and n sectors. Additionally, throughout this paper, matrices and vectors are written in bold: matrices in uppercase and vectors in lowercase. The total output x i of sector i ∈ {1, … , n} is given by or in matrix terms which after solving for x where L = (I − A) −1 is the Leontief inverse.
EEIOA is used to analyze how production and consumption are related to environmental impacts (Leontief, 1970). For an environmental indicator, the total impact of production r (sometimes called the environmental footprint) is calculated as where b is the vector of the environmental indicator per unit of output. Without the loss of generality, b is assumed to have size n × 1 to allocate our focus to the impact on a single environmental indicator.
In order to consider variations in production structures across different economies or regions, national IO tables are combined to form multiregional IO (mrIO) tables (Miller & Blair, 2009) and multiregional Environmentally Extended IO (mrEEIO). In mrIO and mrEEIO tables, size n of the technical coefficient matrix A (thus the Leontief inverse matrix L, final demand y and the extensions b vectors) is n = n s × n c where n s is the number of the sectors and n c is the number of the regions in the mrEEIO table. The equations presented in this work represent generalized EEIO methods, thus, they are also applicable to the mrEEIO system.

TECHNOLOGICAL CHANGES AND THEIR ENVIRONMENTAL IMPACTS IN AN EEIOA FRAMEWORK
Circular economy (CE) aims to both avoid consumption of resources and minimize waste, the latter through recovery strategies at multiple economic and industrial levels (Kirchherr, Reike, & Hekkert, 2017). In EEIOA terms, CE interventions can affect both the interindustry relations and final demand by consumers.
In this part, we derive formulas for the impact of CE interventions on environmental indicators. We limit ourselves to changes in the interindustry relations, as the computational challenge arise from the alterations in the technical coefficient matrix. Our hypothetical intervention comes in the form of shifts of input from one sector (or sectors) to another sector. An example can be steel sector which can increase its inputs of raw materials from the recycling sector at the expense of the mining sector.
The ratio of interindustry relations in the Leontief model are represented by A (technical coefficient matrix). Thus, every time an intervention affects the economic structure, the technical coefficient matrix A needs to be updated to reflect those changes. Let A be the change in the interindustry relations, then the modified technical coefficient matrix A + is defined as If the interindustry relations change in one sector, this will have economy-wide effects. Changes in even a few values of A will affect almost all values in Leontief inverse matrix L. In order to recalculate the IO system according to these changes, we need to obtain the new Leontief inverse matrix L + under the scenarios The final total impact r + on the environmental indicator after the CE intervention is If the selected environmental indicator is related to emissions, a negative value of Δr indicates a successful intervention (e.g., the environmental pressure decreases after the intervention).
In order to determine the output of the updated environmental indicator r + in Equation (7), the new Leontief inverse must be calculated, which becomes computationally challenging as the the size of the technical coefficient matrix A increases. In the following section, we propose two different approaches that can significantly simplify and speed up scenario modeling operations presented in Equation (4) by speeding up the calculation of the new Leontief inverse. In addition, the calculation of an updated Leontief inverse with only minor losses in computation speed is also useful for contribution analyses, L× diag (y).
Typically, after updating input-output tables, the RAS procedure (Boulding & Leontief, 1942;Stone, 1962) can be also applied with appropriate multipliers, until the given totals of the input-output tables for intermediate input requirements are met. However, in projections and scenario analysis, this procedure becomes challenging and can introduce further unknowns (Polenske, 1997). Computing a Leontief inverse from an unbalanced A can still be useful for rough estimations of impact changes, provided that the scenario does not include aggressive structural changes.
Therefore, the RAS procedure is out of the focus of this paper.

Optimization of changes in a single sector
Interventions in single sectors are commonly performed to assess how large-scale deployment of a new technology ripples through the wider economy, or to explore what happens if you start substituting one input for another.
In our hypothetical single-sector CE intervention example, a single sector k is modified so that input from sector j to sector k is shifted to input from i to sector k. Specifically, the intervention results in the reduction of input in sector j to sector k, which we will write as Δa jk . This reduction in the input to sector k can be compensated by additional input from sector i affecting the related technical coefficient by Δa ik . The amount of the changes Δa ik and Δa jk are dependent on how the particular CE intervention is modeled.
The change A in the technical coefficient matrix after the modification of the inputs to a given sector k is a rank-one update (the kth column of the matrix A is updated) and can be expressed in the form of and e m is the basic vector with the mth component equal to 1, else 0.
We apply the Sherman-Morrison formula (Sherman & Morrison, 1950) for the modified Leontief inverse L + = ((I − A) − A) −1 , which gives us Inserting Equation (10) into Equation (4), the total product output x + after the circular economy intervention becomes where x = Ly is the initial value of total product output. Thus, the change Δx = x + − x is the total product output resulting from the CE intervention The direct formula 4 in Equation (12) only requires the previous (and known) entries of the Leontief inverse L. Therefore, an extra calculation for the new Leontief inverse L + after the CE intervention in (6) is avoided, which leads to significantly decreased computational time. In its general form, the time required to calculate the Equation (12)

Optimization of changes in multiple sectors
Interventions in multiple sectors are commonly performed economy-wide analyses, and in particular for CE interventions. We assume that multiple interventions take place in the inputs of in total different sectors under the circular economy scenarios. The goal of the analysis is to find the overall impact of all the interventions on the environmental indicators compared to the base-line values. The changes (rank-update) in the technical coefficient matrix A can be written as

Basic iron and steel and of ferro-alloys and first products thereof in all regions Construction work in all regions −40%
Aluminium and aluminium products in all regions Construction work in all regions −45%

Construction work in all regions Construction work in all regions +11%
where matrices U, and V have sizes n × . The tth column vector u t of the matrix U and the tth column vector v t of the matrix V contain the information of the tth CE intervention in the inputs of the given sector k (as in Section 3.1): In Equation (13) Δa jk e j and v t = e k . We can then apply the Woodbury formula (Woodbury, 1950) to find the modified Leontief inverse L + = ((I − A) − A) −1 under all interventions: where the identity matrix has the inverse I −1 = I. The final value of the total product output x + after the CE interventions becomes where x = Ly is the initial (baseline) total product output. The change Δx in total product output due to the CE intervention is The formula in Equation (16)

RESULTS
This section demonstrates the performance improvements when applying the optimizations derived in Section 3. First, a relatively simple analysis on a small test case is demonstrated. Next, the analysis is applied to the multiregional EEIO (mrEEIO) database EXIOBASE (Wood et al., 2015) in the year 2011.

Demonstration on a small example system
Using a hypothetical input-output table with size n = 6, we assume that a set of interventions, given in Table 1  ) .
The CE intervention itself, where sector k shifts its input from sector (s) j to sector (s) i, is described in Table 1. We can express the change in the Finally, the change Δr in the environmental indicator is calculated using Equation (16) as The sign and the value of the change in the final environmental indicator gives information about whether and how successful the CE intervention can be. In this case, the CE intervention reduced the impact by 0.0015 units.

Demonstration using the mrEEIO database EXIOBASE
Our main demonstration is the application of a Reuse intervention to all (49) regions of the mrEEIO database EXIOBASE V3 for the year 2011. In particular, we apply the reuse scenario published in (Donati et al., 2020) (which is based on Allwood & Cullen, 2015). This intervention explores the effects of increasing steel and aluminium reuse in the construction sector by 40% and 45%, respectively. This means that the construction sector receives reduced steel and aluminium inflows, while increasing the inflow of construction services. The latter is a result of the increased labour intensity associated with reuse. The quantitative changes in the mrEEIO system are summarized in Table 2.
We modify the mrEEIO system as described in Section 3.2, where = 49 is the number of sectors whose inputs are affected by the CE interventions. In other words, in total 49 construction sectors from all (49)   While the classical formulation in EEIOA involves matrix inversion, it also suffices to solve a system of linear equations. In MATLAB, the backslash operator can work more efficiently than a full matrix inversion (Heijungs, de Koning, & Sleeswijk, 2015). Therefore, in order to further evaluate the performance of the proposed calculations, we also compared our computational time with the backslash operator in MATLAB, which solves for x instead of calculating the new Leontief inverse. This method solved the system in 5.627 s, approximately 3 times faster than the traditional method.
It is nevertheless 25 times slower than our proposed formulation in Equation (16). More details on the comparison between the backlash operator and the proposed formulations can be found in the Supporting Information.

Further exploration of performance scaling
In order to further compare the computational times of the proposed formulas with traditional calculations, we run performance tests for both (i) increasing size of the Leontief inverse matrix n (related to increasing number of sectors, number of regions, or both), and (ii) increasing the number of sectors (see Section 3.2) whose input structure is modified under the CE scenario. Figure 1 shows the improvement that can be attained by using Equation (12), for increasing sizes of the Leontief inverse, n. As an example, for EXIOBASE which has n = 9, 800, we find that the tested CE intervention in a single sector is calculated nearly 22,700 times faster with the proposed formula in (12  Figure 2 shows the ratio of the traditional calculation and the calculation according to the Equation (16) for different number of sectors whose input structure is modified in an EEIO system with size n. Although the relative speed improvement decreases when the number of intervened-sectors increases for a given size n, the improvement in absolute terms is still significant, up to two orders of magnitude in our case study.

DISCUSSIONS AND CONCLUSIONS
Industrial ecology tools are becoming more computationally expensive, which leads to problems for both policy and research. In the policy arena, practitioners can suffer from high computational times when they want to live-test various alternatives in a responsive and web-based platform.
In research, computational times come into play when analyzing large systems with multiple interventions, as in circular economy scenarios, or requiring many runs, for example, Monte Carlo simulations.
In this paper, we demonstrated how computational time of commonly used industrial ecology tools can be reduced significantly, potentially by multiple orders of magnitude. Our case study was optimization of scenario calculations in EEIOA, but the underlying method is also applicable to IOA and LCA. We took a previously published EEIOA analysis of reuse as a circular economy policy. However, instead of calculating the Leontief inverse after individual changes to the interindustry relations, we gave direct formulations for the total value of the change in the environmental indicators. The use of explicit formulas decreases the computational time to the degree that it becomes possible to carry out these analyses in live or web-based environments.