# Appendix D: Input-Output Analysis

## Overview

Tools for tracing production-network linkages with Leontief methods and BEA input-output tables, supporting sectoral propagation analysis in [Chapter 7](/textbooks/part-ii-sectoral-analysis/ch07_investment.md), [Chapter 18](/textbooks/part-v-dynamics/ch18_businesscycles.md), and [Chapter 21](/textbooks/part-v-dynamics/ch21_innovation_system.md).

***

## D.1 Conceptual Framework

### What Input-Output Tables Measure

Every industry in an economy both buys from and sells to other industries. A steel mill buys electricity, iron ore, and coal; it sells steel to automakers, construction firms, and appliance manufacturers. Input-output (I-O) tables record these inter-industry flows — the full web of who supplies whom.

The Bureau of Economic Analysis publishes I-O tables as part of the US national accounts. These tables come in two forms:

* **Make tables:** What each industry produces. Rows are industries, columns are commodities. Each cell records how much of commodity j industry i produces.
* **Use tables:** What each industry consumes. Rows are commodities, columns are industries. Each cell records how much of commodity i industry j uses as an intermediate input.

Together, make and use tables provide a complete picture of the production structure: what goes in, what comes out, and where it flows next.

### Why This Matters for Macroeconomics

Standard macro models often treat the economy as producing a single aggregate good. Input-output analysis disaggregates production into its actual industrial structure. This disaggregation turns out to matter enormously for understanding how shocks propagate — a disruption in semiconductor manufacturing does not affect all sectors equally, and the I-O table tells you exactly which sectors bear the brunt.

***

### A Simplified Example

Consider a three-industry economy: Agriculture, Manufacturing, and Services.

**Inter-industry flow table ($ billions):**

| From \ To     | Agriculture | Manufacturing | Services | Final Demand | Total Output |
| ------------- | ----------- | ------------- | -------- | ------------ | ------------ |
| Agriculture   | 5           | 20            | 5        | 70           | 100          |
| Manufacturing | 10          | 30            | 20       | 140          | 200          |
| Services      | 5           | 20            | 10       | 115          | 150          |
| Value Added   | 80          | 130           | 115      |              |              |
| Total Input   | 100         | 200           | 150      |              |              |

Reading across a row tells you where that industry's output goes. Agriculture produces $100 billion total: $5 billion goes back to agriculture itself, $20 billion to manufacturing, $5 billion to services, and $70 billion to final demand (households, government, exports). Reading down a column tells you what inputs that industry uses.

***

## D.2 The Leontief Model

### Technical Coefficients

Wassily Leontief's foundational insight was this: if we know the technical coefficients — how much of each input an industry needs per dollar of output — we can trace the full chain of production requirements that any change in final demand sets off.

Define the **technical coefficients matrix** A, where each element:

$$a\_{ij} = \frac{z\_{ij}}{x\_j}$$

is the dollar value of input from industry i needed per dollar of output from industry j. Here $$z\_{ij}$$ is the flow from industry i to industry j, and $$x\_j$$ is total output of industry j.

From the example above:

|               | Agriculture | Manufacturing | Services |
| ------------- | ----------- | ------------- | -------- |
| Agriculture   | 0.05        | 0.10          | 0.033    |
| Manufacturing | 0.10        | 0.15          | 0.133    |
| Services      | 0.05        | 0.10          | 0.067    |

Each column sums to the share of gross output absorbed by intermediate inputs. The remainder is value added — wages, profits, taxes.

### The Basic Equation

Total output for each industry must equal what other industries use as intermediate inputs plus what goes to final demand:

$$\mathbf{x} = A\mathbf{x} + \mathbf{d}$$

where **x** is the vector of total outputs and **d** is the vector of final demands.

Rearranging:

$$\mathbf{x} - A\mathbf{x} = \mathbf{d}$$

$$(I - A)\mathbf{x} = \mathbf{d}$$

$$\mathbf{x} = (I - A)^{-1}\mathbf{d}$$

***

### The Leontief Inverse

The matrix $$(I - A)^{-1}$$ is the **Leontief inverse**, sometimes called the **total requirements matrix**. Each element $$(I - A)^{-1}\_{ij}$$ tells you the total output required from industry i — both directly and through all indirect channels — per dollar of final demand for industry j.

Why "total"? Because a dollar of final demand for automobiles requires steel directly, but it also requires the electricity used to make that steel, the coal used to generate that electricity, and so on down the chain. The Leontief inverse captures the entire cascade of requirements.

### Output Multipliers

The **column sum** of the Leontief inverse for industry j gives the output multiplier: the total dollar increase in economy-wide output per dollar increase in final demand for industry j.

$$m\_j = \sum\_i (I - A)^{-1}\_{ij}$$

Industries with long, complex supply chains have high multipliers. Industries that rely mainly on their own labor and capital have low multipliers. In the US economy, manufacturing sectors typically show multipliers between 2.0 and 3.0, while many service sectors fall between 1.3 and 1.8.

***

## D.3 Working with BEA Data

### Available Tables

The BEA publishes input-output accounts at three levels of detail:

| Version              | Industries       | Best For                                 |
| -------------------- | ---------------- | ---------------------------------------- |
| Summary              | 15 sectors       | Teaching, quick analysis                 |
| Standard             | 71 industries    | Most research applications               |
| Detailed (benchmark) | \~400 industries | Supply chain analysis, fine-grained work |

Benchmark tables appear every five years, tied to the Economic Census. Annual tables at the summary and standard levels fill the gaps between benchmarks.

### Where to Find the Data

BEA makes I-O tables available at [bea.gov/industry/input-output-accounts-data](https://www.bea.gov/industry/input-output-accounts-data). The site provides:

* Make tables (industry-by-commodity production)
* Use tables (commodity-by-industry consumption)
* Direct requirements tables (the A matrix)
* Total requirements tables (the Leontief inverse)
* Separate tables for domestic production and imports

### Constructing the A Matrix

The BEA publishes the direct requirements table, but it is instructive to construct it yourself. Starting from the use table:

1. Download the use table (commodities by industries)
2. Extract the inter-industry flows (exclude final demand columns and value-added rows)
3. Divide each column by the industry's total output
4. The result is the technical coefficients matrix A

***

### Handling Imports

A subtlety that matters in practice: the standard use table includes imported intermediates alongside domestic ones. For many applications — especially supply chain analysis — you need the **domestic requirements table**, which strips out imports. The BEA publishes both versions.

The distinction matters because a dollar of final demand for cars generates domestic production requirements only insofar as the inputs are domestically sourced. If tires are imported, the tire-making requirement does not appear as domestic output.

***

## D.4 Applications

### Supply Chain Multipliers and Shock Propagation

Input-output tables provide a natural framework for studying how sector-specific shocks propagate through the economy. Acemoglu, Carvalho, Ozdaglar, and Tahbaz-Salehi (2012) showed that the structure of production networks determines whether idiosyncratic shocks to individual sectors wash out in the aggregate or amplify into macroeconomic fluctuations.

The key insight: when some sectors serve as hubs — supplying inputs to many other industries — shocks to those sectors do not average out. The economy's production network has a "fat-tailed" structure, with a few highly connected sectors whose disruptions cascade broadly.

The Leontief inverse makes this concrete. The row sums of $$(I - A)^{-1}$$ measure each industry's "forward linkages" — how much its output feeds into the rest of the economy. Industries with high forward linkages are the ones whose disruptions matter most.

### Import Content of Final Demand

By comparing the total requirements matrix using the full (domestic + imported) A matrix against the domestic-only version, you can decompose any category of final demand into its domestic and imported content. This calculation reveals, for example, that roughly 15-20% of US personal consumption expenditure represents imported content when you trace through all intermediate stages.

***

### Employment Multipliers

Combine I-O analysis with employment data to calculate employment multipliers: how many jobs (direct plus indirect) each million dollars of spending in a given sector supports.

Define the employment coefficients vector **e**, where $$e\_i$$ is employment per dollar of output in industry i. The total employment requirements per dollar of final demand are:

$$\mathbf{e}' (I - A)^{-1}$$

These multipliers vary substantially. A million dollars of construction spending supports roughly 10-12 jobs (direct and indirect), while a million dollars of software spending supports fewer — but with higher average wages.

### Environmental Accounting

The same framework extends to environmental analysis. Replace the employment vector with a carbon emissions vector (tons of CO2 per dollar of output), and the Leontief inverse delivers the total embodied carbon in each category of final demand. This "carbon footprinting" approach reveals that the emissions attributable to a consumer product extend far beyond its final assembly.

### COVID-19 and Supply Chain Analysis

The pandemic exposed the fragility of extended supply chains. I-O analysis helped quantify which sectors faced the greatest disruption risk. When Chinese manufacturing shut down in early 2020, the I-O table could identify which US industries depended most heavily (directly and indirectly) on Chinese intermediate inputs. The analysis required international I-O tables — the World Input-Output Database (WIOD) links national I-O tables into a global production network.

***

## D.5 Hulten's Theorem and Domar Weights

### The Question

How much does a productivity improvement in one sector matter for aggregate output? Hulten (1978) provided an elegant answer.

### Domar Weights

Define the **Domar weight** of sector i as:

$$\lambda\_i = \frac{p\_i y\_i}{GDP}$$

where $$p\_i y\_i$$ is sector i's total sales (including intermediate sales) and GDP is aggregate value added. Domar weights sum to more than one because they count intermediate transactions.

### Hulten's Result

In a competitive economy with constant returns to scale, a 1% improvement in sector i's total factor productivity raises aggregate TFP by approximately $$\lambda\_i$$ percent.

This is a first-order result — it holds as an approximation for small shocks. Its power lies in its simplicity: you do not need to solve a general equilibrium model. You just need the Domar weights, which are directly observable from I-O data.

### Example

In the US, manufacturing accounts for roughly 11% of GDP but its Domar weight (including intermediate sales) is approximately 0.30. A 1% productivity gain in manufacturing therefore raises aggregate TFP by approximately 0.30% — nearly three times what the GDP share alone would suggest. The gap reflects manufacturing's extensive role as a supplier of intermediate inputs to other sectors.

***

### Limitations of Hulten's Theorem

Hulten's result is a first-order approximation. It breaks down for:

* **Large shocks:** When a sector shuts down entirely (as opposed to a marginal productivity change), nonlinearities dominate. Baqaee and Farhi (2019) extend the framework to handle larger shocks and non-competitive settings.
* **Non-competitive markets:** With markups, the welfare effects of sectoral shocks differ from the Domar weight approximation.
* **Complementarities:** If inputs are complements rather than substitutes, shocks to bottleneck sectors amplify more than the Domar weight implies.

***

## D.6 Limitations

### Fixed Coefficients

The Leontief model assumes fixed technical coefficients — each industry uses inputs in fixed proportions regardless of relative prices. In reality, firms substitute between inputs as prices change. Over short horizons, this assumption is reasonable (you cannot quickly redesign a car to use less steel). Over decades, substitution can be substantial.

### Static Framework

The standard model is static: it describes an economy in a single period, with no dynamics, no inventories, no capital accumulation. Extensions exist (dynamic I-O models), but they are rarely used in practice because the data demands become prohibitive.

### Aggregation Sensitivity

Results depend on the level of industry detail. Two industries that appear weakly linked at the 15-sector level may turn out to be tightly connected when you drill down to 400 industries. Research on shock propagation should use the most detailed tables available.

### Import Treatment

As discussed in D.3, how you handle imports matters for the results. The domestic requirements table and the total requirements table can give substantially different multipliers, especially for industries with heavy import dependence.

### No Behavioral Content

The Leontief model is an accounting framework, not a behavioral model. It tells you what production is required to meet given final demand, but it does not explain how final demand is determined, how prices adjust, or how agents respond to shocks. It is a tool for measurement, not a theory of the economy — which is precisely what makes it useful in an institutionalist framework.

***

## D.7 Python Implementation

### Loading and Processing BEA I-O Data

```python
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt

# -----------------------------------------------------------
# Step 1: Load the BEA use table (15-sector summary level)
# Download from: bea.gov/industry/input-output-accounts-data
# -----------------------------------------------------------

# For illustration, construct a simplified A matrix
# Based on BEA 2022 summary tables (15 sectors, rounded)

industries = [
    'Agriculture', 'Mining', 'Utilities', 'Construction',
    'Manufacturing', 'Wholesale', 'Retail', 'Transport',
    'Information', 'Finance', 'Prof Services', 'Education/Health',
    'Arts/Entertain', 'Other Services', 'Government'
]

# Technical coefficients matrix (simplified, illustrative)
# Each column j shows the share of industry j's output
# purchased from industry i as intermediate input
n = len(industries)
np.random.seed(42)

# In practice, load from BEA Excel files:
# use_table = pd.read_excel('Use_Tables.xlsx', sheet_name='2022')
# Then divide each column by total industry output.
```

### Computing the Leontief Inverse

```python
def compute_leontief_inverse(A):
    """
    Compute the Leontief inverse (I - A)^{-1}.

    Parameters
    ----------
    A : np.ndarray
        Technical coefficients matrix (n x n).
        Each element a_ij = intermediate purchases from i
        per dollar of output in j.

    Returns
    -------
    L : np.ndarray
        Leontief inverse matrix.
    """
    n = A.shape[0]
    I = np.eye(n)
    L = np.linalg.inv(I - A)
    return L


def output_multipliers(L):
    """
    Compute output multipliers (column sums of Leontief inverse).
    """
    return L.sum(axis=0)


def employment_requirements(L, emp_coeffs):
    """
    Compute total employment requirements per dollar of final demand.

    Parameters
    ----------
    L : np.ndarray
        Leontief inverse.
    emp_coeffs : np.ndarray
        Employment per dollar of output in each industry.

    Returns
    -------
    np.ndarray
        Total employment per dollar of final demand, by industry.
    """
    return emp_coeffs @ L
```

### Worked Example with Illustrative Data

```python
# Construct a realistic 5-sector A matrix for demonstration
sectors = ['Agriculture', 'Manufacturing', 'Energy',
           'Services', 'Transport']

A = np.array([
    [0.05, 0.08, 0.01, 0.01, 0.02],   # Agriculture
    [0.10, 0.20, 0.05, 0.03, 0.08],   # Manufacturing
    [0.04, 0.06, 0.10, 0.03, 0.12],   # Energy
    [0.03, 0.05, 0.04, 0.08, 0.05],   # Services
    [0.05, 0.04, 0.03, 0.02, 0.05],   # Transport
])

# Compute Leontief inverse
L = compute_leontief_inverse(A)

# Display
L_df = pd.DataFrame(L, index=sectors, columns=sectors)
print("Leontief Inverse Matrix:")
print(L_df.round(4))
print()

# Output multipliers
multipliers = output_multipliers(L)
for s, m in zip(sectors, multipliers):
    print(f"  {s}: {m:.3f}")
```

***

### Plotting the Leontief Inverse as a Heatmap

```python
def plot_leontief_heatmap(L, labels, title='Leontief Inverse Matrix'):
    """
    Heatmap of the Leontief inverse.

    Darker cells indicate stronger total (direct + indirect)
    production linkages between industries.
    """
    fig, ax = plt.subplots(figsize=(8, 6))

    im = ax.imshow(L, cmap='Blues', aspect='auto')
    cbar = plt.colorbar(im, ax=ax, fraction=0.046, pad=0.04)
    cbar.set_label('Total requirement ($ per $ final demand)',
                   fontsize=10)

    ax.set_xticks(range(len(labels)))
    ax.set_yticks(range(len(labels)))
    ax.set_xticklabels(labels, rotation=45, ha='right', fontsize=9)
    ax.set_yticklabels(labels, fontsize=9)

    # Annotate cells
    for i in range(len(labels)):
        for j in range(len(labels)):
            color = 'white' if L[i, j] > L.max() * 0.6 else 'black'
            ax.text(j, i, f'{L[i, j]:.3f}', ha='center', va='center',
                    fontsize=8, color=color)

    ax.set_title(title, fontsize=12, fontweight='bold')
    ax.set_xlabel('Industry of final demand', fontsize=10)
    ax.set_ylabel('Industry of production', fontsize=10)
    plt.tight_layout()
    return fig, ax


# Generate the heatmap
fig, ax = plot_leontief_heatmap(L, sectors)
plt.savefig('leontief_heatmap.png', dpi=300, bbox_inches='tight')
plt.show()
```

### Plotting Output Multipliers

```python
def plot_multipliers(multipliers, labels):
    """Bar chart of output multipliers by sector."""
    fig, ax = plt.subplots(figsize=(8, 5))

    colors = ['#1f77b4', '#ff7f0e', '#2ca02c', '#d62728', '#9467bd']
    bars = ax.bar(labels, multipliers, color=colors[:len(labels)],
                  edgecolor='black', linewidth=0.5)

    ax.set_ylabel('Output multiplier\n($ total output per $ final demand)',
                  fontsize=10)
    ax.set_title('Sectoral Output Multipliers', fontsize=12,
                 fontweight='bold')
    ax.axhline(y=1.0, color='gray', linestyle='--', linewidth=0.8,
               label='No indirect effects')

    # Label bars
    for bar, val in zip(bars, multipliers):
        ax.text(bar.get_x() + bar.get_width() / 2, bar.get_height() + 0.02,
                f'{val:.2f}', ha='center', va='bottom', fontsize=10)

    ax.spines['top'].set_visible(False)
    ax.spines['right'].set_visible(False)
    ax.legend(fontsize=9)
    plt.tight_layout()
    return fig, ax


fig, ax = plot_multipliers(multipliers, sectors)
plt.savefig('output_multipliers.png', dpi=300, bbox_inches='tight')
plt.show()
```

***

### Shock Propagation Analysis

```python
def propagate_demand_shock(A, d_baseline, d_shocked, labels):
    """
    Compute the effect of a change in final demand on all sectors.

    Parameters
    ----------
    A : np.ndarray
        Technical coefficients matrix.
    d_baseline : np.ndarray
        Baseline final demand vector.
    d_shocked : np.ndarray
        Shocked final demand vector.
    labels : list
        Industry names.

    Returns
    -------
    pd.DataFrame with baseline output, shocked output, and change.
    """
    L = compute_leontief_inverse(A)
    x_base = L @ d_baseline
    x_shock = L @ d_shocked

    results = pd.DataFrame({
        'Baseline Output': x_base,
        'Shocked Output': x_shock,
        'Change': x_shock - x_base,
        'Pct Change': (x_shock - x_base) / x_base * 100
    }, index=labels)
    return results


# Example: 10% drop in manufacturing final demand
d_base = np.array([50, 200, 80, 300, 60])
d_shock = d_base.copy()
d_shock[1] = d_shock[1] * 0.90  # 10% drop in manufacturing

results = propagate_demand_shock(A, d_base, d_shock, sectors)
print("Effect of 10% drop in manufacturing final demand:")
print(results.round(2))
```

***

## D.8 Exercises

1. **Build the A matrix.** Download the BEA's 15-sector summary use table for the most recent year from [bea.gov/industry/input-output-accounts-data](https://www.bea.gov/industry/input-output-accounts-data). Construct the technical coefficients matrix A by dividing each column of inter-industry flows by the corresponding industry's total output. Which sector has the highest ratio of intermediate inputs to total output? Which relies most heavily on its own output as an input?
2. **Compute and interpret multipliers.** Using the A matrix from Exercise 1, compute the Leontief inverse and the output multipliers (column sums). Rank the 15 sectors by multiplier size. How do manufacturing multipliers compare to service-sector multipliers? Relate your findings to the distinction between goods-producing and service-producing sectors in Chapter 2.
3. **Shock propagation.** Suppose final demand for the "Information" sector falls by $50 billion (roughly a 5% decline). Using the Leontief inverse, calculate the total output loss for each of the 15 sectors. Which sectors experience the largest indirect effects? Does the pattern match your intuition about the information sector's supply chain?
4. **Employment multipliers.** Obtain employment-by-industry data from the BLS Quarterly Census of Employment and Wages (QCEW). Compute employment-per-dollar-of-output coefficients for each of the 15 sectors. Multiply through the Leontief inverse to calculate total employment multipliers. How does a million dollars of construction spending compare to a million dollars of finance spending in total jobs supported?
5. **Domestic vs. total requirements.** Download both the "domestic requirements" and "total requirements" tables from the BEA. For three sectors of your choice, compare the domestic output multiplier to the total (domestic + imported) output multiplier. What does the gap tell you about import dependence in each sector? Connect your findings to the discussion of trade in Chapter 22.

***

## D.9 Further Reading

* Leontief, Wassily (1936), "Quantitative Input-Output Relations in the Economic System of the United States." *Review of Economics and Statistics*. The original formulation of input-output analysis as a practical tool for studying production interdependence.
* Miller, Ronald E. and Peter D. Blair (2009), *Input-Output Analysis: Foundations and Extensions*, 2nd ed., Cambridge University Press. The standard reference — comprehensive treatment of I-O methods, extensions, and applications, accessible to graduate students with linear algebra.
* Acemoglu, Daron, Vasco M. Carvalho, Asuman Ozdaglar, and Alireza Tahbaz-Salehi (2012), "The Network Origins of Aggregate Fluctuations." *Econometrica*. Shows how the structure of production networks determines whether idiosyncratic shocks aggregate or dissipate; the paper that brought I-O thinking into mainstream macro theory.
* Hulten, Charles R. (1978), "Growth Accounting with Intermediate Inputs." *Review of Economic Studies*. Establishes that a sector's contribution to aggregate productivity equals its Domar weight — a result that connects I-O accounting directly to growth theory.
* Bureau of Economic Analysis (2009), "Concepts and Methods of the U.S. Input-Output Accounts." BEA technical documentation describing how the tables are constructed, what the make/use distinction means, and how imports are treated.
* Timmer, Marcel P., Erik Dietzenbacher, Bart Los, Robert Stehrer, and Gaaitzen J. de Vries (2015), "An Illustrated User Guide to the World Input-Output Database." *Review of International Economics*. Guide to the WIOD, which links national I-O tables into a global framework — essential for studying international supply chains and trade in value added.
* Baqaee, David R. and Emmanuel Farhi (2019), "The Macroeconomic Impact of Microeconomic Shocks: Beyond Hulten's Theorem." *Econometrica*. Extends Hulten's first-order result to handle large shocks, nonlinearities, and non-competitive markets — the modern frontier of production network theory.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://laurence-wilse-samson.gitbook.io/textbooks/technical-appendices/appendix_d_inputoutput.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
