214 41 47MB
English Pages 266 [265] Year 2024

Economic Networks
It has become increasingly clear that economies can fruitfully be viewed as networks, consisting of millions of nodes (households, firms, banks, etc.) connected by business, social, and legal relationships. These relationships shape many outcomes that economists measure. Over the past few years, research on economic networks has flourished, as economists try to understand supply-side dynamics, default cascades, aggregate fluctuations, and many other phenomena. Economic Networks provides a brisk introduction to network analysis that is self-contained, rigorous, and illustrated with many figures, diagrams and listings with computer code. Network methods are put to work analyzing production networks, financial networks, and other related topics (including optimal transport, another highly active research field). Visualizations using recent data bring key ideas to life. Thomas J. Sargent is a Nobel Prize–winning economist and Professor of Economics at New York University. He has held positions at Stanford, Minnesota, Chicago, and Princeton, and served as President of the Econometric Society and of the American Economic Association. He is renowned for his influential research on macroeconomics, rational expectations, and policy analysis. John Stachurski is a professor at the Australian National University who has made influential contributions to the study of Markov models and dynamic optimization. He is an economist specializing in mathematical and computational economics and is also a co-founder of QuantEcon, a popular platform for open-source economic modeling.
Published online by Cambridge University Press
Structural Analysis in the Social Sciences Edited by Mark Granovetter The series Structural Analysis in the Social Sciences presents studies that analyze social behavior and institutions by reference to relations among such concrete social entities as persons, organizations, and nations. Relational analysis contrasts on the one hand with reductionist methodological individualism and on the other with macro-level determinism, whether based on technology, material conditions, economic conflict, adaptive evolution, or functional imperatives. In this more intellectually flexible, structural middle ground, analysts situate actors and their relations in a variety of contexts. Since the series began in 1987, its authors have variously focused on small groups, history, culture, politics, kinship, aesthetics, economics, and complex organizations, creatively theorizing how these shape and in turn are shaped by social relations. Their style and methods have ranged widely, from intense, long-term ethnographic observation to highly abstract mathematical models. Their disciplinary affiliations have included history, anthropology, sociology, political science, business, economics, mathematics, and computer science. Some have made explicit use of social network analysis, including many of the cuttingedge and standard works of that approach, whereas others have kept formal analysis in the background and used “networks” as a fruitful orienting metaphor. All have in common a sophisticated and revealing approach that forcefully illuminates our complex social world. Recent Books in the Series John Stachurski and Thomas J. Sargent, Economic Networks: Theory and Computation David A. McFarland, Jeffrey A. Smith, and James Moody, Network Analysis: Integrating Social Network Theory, Method, and Application with R Mario L. Small, Brea L. Perry, Bernice A. Pescosolido, and Edward B. Smith, Personal Networks: Classic Readings and New Directions in Egocentric Analysis David Knoke, Mario Diani, and Dimitris Christopolous, and James Holloway, Multimodal Political Networks Claire Bidart, Alain Degenne, and Michel Grossetti, Living in Networks: The Dynamics of Social Relations William Sims Bainbridge, The Social Structure of Online Communities Michael Kenney, The Islamic State in Britain: Radicalization and Resilience in an Activist Network Wouter De Nooy, Andrej Mrvar, and Vladimir Batagelj, Exploratory Social Network Analysis with Pajek: Revised and Expanded Edition for Updated Software Sean F. Everton, Networks and Religion: Ties that Bind, Loose, Build-up and Tear Down Darius Mehri, Iran Auto Navid Hassanpour, Leading from the Periphery and Network Collective Action Cheol-Sung Lee, When Solidarity Works Benjamin Cornwell, Social Sequence Analysis Mariela Szwarcberg, Mobilizing Poor Voters Luke M. Gerdes, ed., Illuminating Dark Networks Silvia Domínguez and Betina Hollstein, eds., Mixed Methods in Studying Social Networks
Published online by Cambridge University Press
Dean Lusher, Johan Koskinen, and Garry Robins, eds., Exponential Random Graph Models for Social Networks: Theory, Methods, and Applications Sean F. Everton, Disrupting Dark Networks Wouter de Nooy, Andrej Mrvar, and Vladimir Batagelj, Exploratory Social Network Analysis with Pajek Noah E. Friedkin and Eugene C. Johnsen, Social Influence Network Theory Zeev Maoz, The Networks of Nations: The Evolution and Structure of International Networks, 1816–2001 Martin Kilduff and David Krackhardt, Interpersonal Networks in Organizations Ari Adut, On Scandal: Moral Disturbances in Society, Politics, and Art Robert C. Feenstra and Gary G. Hamilton, Emergent Economies, Divergent Paths Eiko Ikegami, Bonds of Civility: Aesthetic Networks and the Political Origins of Japanese Culture Peter Carrington, John Scott, and Stanley Wasserman, Models and Methods in Social Network Analysis Patrick Doreian, Vladimir Batagelj, and Anujka Ferligoj, Generalized Blockmodeling James Lincoln and Michael Gerlach, Japan’s Network Economy Robert Franzosi, From Words to Numbers Sean O’Riain, The Politics of High-Tech Growth Philippe Bourgois, In Search of Respect: Selling Crack in El Barrio (Second Edition) Isabella Alcañiz, Environmental and Nuclear Networks in the Global South
Published online by Cambridge University Press
Published online by Cambridge University Press
Economic Networks Theory and Computation THOMAS J. SARGENT New York University
J O H N S TA C H U R S K I Australian National University
Published online by Cambridge University Press
Shaftesbury Road, Cambridge CB2 8EA, United Kingdom One Liberty Plaza, 20th Floor, New York, NY 10006, USA 477 Williamstown Road, Port Melbourne, VIC 3207, Australia 314–321, 3rd Floor, Plot 3, Splendor Forum, Jasola District Centre, New Delhi – 110025, India 103 Penang Road, #05–06/07, Visioncrest Commercial, Singapore 238467 Cambridge University Press is part of Cambridge University Press & Assessment, a department of the University of Cambridge. We share the University’s mission to contribute to society through the pursuit of education, learning and research at the highest international levels of excellence. www.cambridge.org Information on this title: www.cambridge.org/9781009456357 DOI: 10.1017/9781009456340 © Thomas J. Sargent and John Stachurski 2024 This publication is in copyright. Subject to statutory exception and to the provisions of relevant collective licensing agreements, no reproduction of any part may take place without the written permission of Cambridge University Press & Assessment. First published 2024 A catalogue record for this publication is available from the British Library Library of Congress Cataloging-in-Publication Data Names: Stachurski, John, 1969- author. | Sargent, Thomas J, author. Title: Economic networks : theory and computation : Quantecon Book I / Thomas J Sargent and John Stachurski. Description: 1 edition. | New York : Cambridge University Press, [2024] | Includes bibliographical references and index. Identifiers: LCCN 2023045874 | ISBN 9781009456357 (hardback) | ISBN 9781009456364 (paperback) Subjects: LCSH: Business networks. | Social networks–Economic aspects. | Economics–Sociological aspects. | Economics–Mathematical models. Classification: LCC HD69.S8 S713 2024 | DDC 302.4–dc23/eng/20231201 LC record available at https://lccn.loc.gov/2023045874 ISBN 978-1-009-45635-7 Hardback ISBN 978-1-009-45636-4 Paperback Cambridge University Press & Assessment has no responsibility for the persistence or accuracy of URLs for external or third-party Internet websites referred to in this publication and does not guarantee that any content on such websites is, or will remain, accurate or appropriate.
Published online by Cambridge University Press
To Nina and Finn
Published online by Cambridge University Press
Published online by Cambridge University Press
Contents
List of Figures List of Tables Preface Common Symbols
page xiii xvi xvii xix
1
Introduction 1.1 Motivation 1.2 Spectral Theory 1.2.1 Eigendecompositions 1.2.2 The Neumann Series Lemma 1.2.3 The Perron–Frobenius Theorem 1.3 Probability 1.3.1 Discrete Probability 1.3.2 Power Laws 1.4 Graph Theory 1.4.1 Unweighted Directed Graphs 1.4.2 Weighted Digraphs 1.4.3 Network Centrality 1.4.4 Scale-Free Networks 1.5 Chapter Notes
1 1 5 5 11 12 15 15 18 24 24 30 38 45 49
2
Production 2.1 Multisector Models 2.1.1 Production Networks 2.1.2 Equilibrium 2.1.3 Demand Shocks 2.1.4 Forward Linkages 2.2 General Equilibrium 2.2.1 Supply and Demand 2.2.2 The Granular Hypothesis 2.2.3 Network Structure and Shock Propagation
51 51 51 54 59 64 68 68 70 74
Published online by Cambridge University Press
x
Contents
2.3 More Spectral Theory 2.3.1 Vector Norms 2.3.2 Matrix Norms 2.3.3 Iteration in Matrix Space 2.3.4 Exact Stability Conditions 2.4 Chapter Notes
78 78 80 83 85 88
3
Optimal Flows 3.1 Shortest Paths 3.1.1 Definition and Examples 3.1.2 Bellman’s Method 3.1.3 Betweenness Centrality 3.2 Linear Programming and Duality 3.2.1 Linear Assignment 3.2.2 Linear Programming 3.3 Optimal Transport 3.3.1 The Monge–Kantorovich Problem 3.3.2 Kantorovich Duality 3.3.3 Optimal Transport and Competitive Equilibria 3.3.4 The General Flow Problem 3.4 Chapter Notes
89 89 89 92 97 98 99 101 107 108 118 119 122 127
4
Markov Chains and Networks 4.1 Markov Chains as Digraphs 4.1.1 Markov Models 4.1.2 Distribution Dynamics 4.1.3 Stationarity 4.2 Asymptotics 4.2.1 Ergodicity 4.2.2 Aperiodicity and Stability 4.2.3 The Markov–Dobrushin Coefficient 4.2.4 Information and Social Networks 4.3 Chapter Notes
129 129 129 136 138 142 142 147 150 155 158
5
Nonlinear Interactions 5.1 Fixed Point Theory 5.1.1 Contraction Mappings 5.1.2 Shortest Paths Revisited 5.1.3 Supply Constraints 5.1.4 Fixed Points and Monotonicity
160 160 161 164 165 166
Published online by Cambridge University Press
Contents
Appendix A
xi
5.2 Financial Networks 5.2.1 Contagion 5.2.2 Default Cascades 5.2.3 Equity Cross-Holdings 5.3 Chapter Notes
169 169 170 175 177
Math Review A.1 Sets and Functions A.1.1 Sets A.1.2 Equivalence Classes A.1.3 Functions A.1.4 Inverse Functions A.1.5 Real-Valued Functions A.1.6 Fixed Points A.1.7 Vectors A.1.8 Complex Numbers A.2 Order A.2.1 Partial Orders A.2.2 Pointwise Operations on Vectors A.2.3 Monotonicity A.3 Convergence A.3.1 Metric Properties of the Real Line A.3.2 Metric Properties of Euclidean Space A.3.3 Topology A.3.4 Continuity in Vector Space A.4 Linear Algebra A.4.1 Subspaces and Independence A.4.2 Basis Vectors and Dimension A.4.3 Linear Maps Are Matrices A.4.4 Linear Hyperplanes A.4.5 Nonsingular Linear Systems A.4.6 Orthogonality A.5 Convexity and Concavity A.5.1 Convexity and Polyhedra A.5.2 Convex and Concave Functions A.6 Optimization A.6.1 Definitions and Existence A.6.2 Convexity and Extrema A.6.3 Multivariate Quadratic Objectives
180 180 180 181 181 182 183 185 186 186 188 188 189 189 190 191 192 193 193 194 194 197 198 199 200 201 203 203 204 206 206 207 208
Published online by Cambridge University Press
xii
Contents
A.7 Lagrangian Duality A.7.1 Theory A.7.2 Saddle Points and Duality A.7.3 Karush, Kuhn, and Tucker Appendix B
Solutions to Selected Exercises References Index
Published online by Cambridge University Press
208 208 210 211 213 234 242
Figures
1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 1.10 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.18 1.19 1.20 1.21 1.22 1.23 1.24 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8
International trade in crude oil 2021 International trade in commercial aircraft during 2019 Worker transition dynamics If S = {1,2,3}, then 𝒟(S) is the unit simplex in R3 Independent draws from Student’s t- and normal distributions ccdf plots for the Pareto and exponential distributions Empirical ccdf plots for largest firms (Forbes) Zeta and Pareto distributions A digraph of classes An alternative edge list NetworkX digraph plot Strongly connected components of a digraph (rectangles) A periodic digraph International private credit flows by country A weighted digraph A network of credit flows across institutions The transpose: a network of liabilities Failure of strong connectivity Hub vs. authority Centrality measures for the credit network A network with a source and a sink Degree distribution for international aircraft trade An instance of an Erdos–Renyi random graph An instance of a preferential attachment random graph Backward linkages for 15 US sectors in 2021 Network for 71 US sectors in 2021 A simple production network The Leontief inverse L (hotter colors indicate larger values) Propagation of demand shocks via backward linkages Eigenvector centrality across US industrial sectors Network for 114 Australian industry sectors in 2020 Output multipliers across 15 US industrial sectors
Published online by Cambridge University Press
page 2 3 8 16 20 22 22 23 24 25 26 27 28 31 32 34 35 37 39 41 43 46 48 49 53 55 57 60 61 62 63 65
xiv
List of Figures
2.9 2.10 2.11 2.12 2.13 2.14 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 3.15 3.16 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 4.10 4.11 4.12 4.13 5.1 A.1 A.2 A.3 A.4 A.5
Forward linkages and upstreamness over US industrial sectors Relative upstreamness of US industrial sectors GDP growth rates and std. deviations (in parentheses) for 10 countries Star network with single hub Symmetric and asymmetric networks Hub-based Katz centrality across 15 US industrial sectors Graph for the shortest path problem Solution 1 Solution 2 The cost-to-go function, with q ∗ (x) indicated by red digits at each x Addition of a self loop to the destination Shortest path Bellman iteration Betweenness centrality (by color and node size) for Florentine families One possible assignment (i.e., permutation of [40]) Revenue maximizing quantities Transforming distribution ϕ into distribution ψ A Monge map transporting ϕ to ψ Kantorovich relaxation of the Monge problem An optimal transport problem solved by linear programming The Silk Road (Source: Wikimedia Commons) A simple network flow problem Reducing minimum cost optimal flow to optimal transport Cross-country GDP dynamics as a digraph Cross-country GDP dynamics as a digraph, updated data Contour plot of transition matrix PB Wealth percentile over time Predicted vs. realized cross-country income distributions for 2019 A trajectory from ψ0 = (0,0,1) A trajectory from ψ0 = (0,1/2,1/2) Distribution projections from PB A poverty trap Convergence of the empirical distribution to ψ∗ A digraph with walk of length 2 from any node to 1 A digraph with walk of length 2 from any node to 1 Two social networks Waves of bankruptcies in a financial network Different types of functions on (0,1) Some functions are bijections and some are not Functions f ∨ g and f ∧ g when defined on a subset of R Graph and fixed points of G : x 7→ 2.125/(1 + x −4 ) The complex number (a,b) = r ei ϕ
Published online by Cambridge University Press
66 67 73 76 77 77 90 90 90 91 92 97 98 99 102 108 110 111 116 123 125 126 130 131 132 134 137 138 139 139 144 147 153 154 156 178 182 182 184 185 187
List of Figures
A.6 A.7 A.8 A.9 A.10
Convergence of a sequence to the origin in R3 The span of vectors u,v,w in R3 Equivalence of the onto and one-to-one properties A polyhedron P represented as intersecting halfspaces A saddle point (x ∗,θ∗ ) of the function L
Published online by Cambridge University Press
xv
192 195 199 204 210
Tables
1.1 2.1 2.2
Codes for the 16-country financial network Sector codes for the 15-good case Sector codes for the 71-good case
Published online by Cambridge University Press
page 31 54 56
Preface
The development and use of network science has grown exponentially since the beginning of the twenty-first century. The ideas and techniques found in this field are already core tools for analyzing a vast range of phenomena, from epidemics and disinformation campaigns to chemical reactions and brain function. In economics, network theory is typically taught as a specialized subfield, available to students as one of many elective courses toward the end of their program. However, we are rapidly approaching the stage where every aspiring scientist – including social scientists and economists – wants to know the foundations of this field. It is arguably the case that, just as every well-trained economist learns the basics of convex optimization, maximum likelihood, and linear regression, so too should every graduate student in economics learn the fundamental ideas of network theory. This book is an introduction to economic networks, intended for students and researchers in the fields of economics and applied mathematics. The book emphasizes quantitative modeling, with the main underlying tools being graph theory, linear algebra, fixed-point theory, and programming. Most mathematical tools are covered from first principles, with two main technical results – the Neumann series lemma and the Perron–Frobenius theorem – playing a central role. The book is suitable for a one-semester course, taught either to advanced undergraduate students who are comfortable with linear algebra or to beginning graduate students. (For example, although we define eigenvalues, an ideal student would already know what eigenvalues and eigenvectors are, so that concepts like “eigenvector centrality” or results like the Neumann series lemma are readily absorbed.) The text will also suit students from mathematics, engineering, computer science, and other related fields who wish to learn about the connection between economics and networks. Several excellent books on network theory in economics and social science already exist, including Easley et al. (2010), Jackson (2010), Borgatti et al. (2018), and Goyal (2023), as well as the handbook by Bramoullé et al. (2016). These texts have broad scope and treat many useful applications. In contrast, our book is narrower and more technical. It provides the mathematical, computational, and graph-theoretic foundations that are required to understand and apply network theory, along with a treatment of some of the most important network applications in economics, finance, and
https://doi.org/10.1017/9781009456340.001 Published online by Cambridge University Press
xviii
Preface
operations research. It can be used as a complementary resource or as a preliminary course that facilitates understanding of the alternative texts listed above, as well as research papers in the area. Our book contains a mix of Python and Julia code. The majority is in Python because the libraries are more stable at the time of writing, although Julia also has strong graph manipulation and optimization libraries. Code for the figures is available from the authors. There are many solved exercises, ranging from simple to quite hard. At the end of each chapter, we provide notes, informal comments, and references. We are greatly indebted to Jim Savage and Schmidt Futures for generous financial support, as well as to Shu Hu and Chien Yeh for their outstanding research assistance. QuantEcon research fellow Matthew McKay generously lent us his time and expertise in data analysis, networks, and visualization. QuantEcon research assistant Mark Dawkins turned an unstructured collection of code files into an elegant companion Jupyter Book. Qianbin Dou has prepared a Chinese translation of this book, with assistance from his colleagues Meilu Sun and Ling Hu. In the process, Qianbin raised many important points that greatly enhanced the quality of all chapters. We thank Qianbin and his colleagues for their extremely valuable help. For many additional fixes, comments, and suggestions, we thank Quentin Batista, Rolf Campos, Fernando Cirelli, Rebekah Dix, Saya Ikegawa, Fazeleh Kazemian, Dawie van Lill, Simon Mishricky, Pietro Monticone, Flint O’Neil, Akshay Shanker, Zejin Shi, Arnav Sood, Natasha Watkins, Chao Wei, and Zhuoying Ye. Finally, Chase Coleman, Alfred Galichon, Spencer Lyon, Daisuke Oyama, and Jesse Perla are collaborators at QuantEcon, and almost everything we write has benefited from their input. This text is no exception.
https://doi.org/10.1017/9781009456340.001 Published online by Cambridge University Press
Common Symbols
P H⇒ Q
P implies Q
P ⇐⇒ Q
P H⇒ Q and Q H⇒ P the set {1, . . . ,n}
[n] α := 1
α is defined as equal to 1
f ≡1
function f is everywhere equal to 1
℘(A)
the power set of A; that is, the collection of all subsets of set A
N, Z, and R C
the natural numbers, integers, and real numbers respectively the set of complex numbers (see Section A.1.8)
Z+ , R+ , etc. Mn×k
the nonnegative elements of Z, R, etc. all n × k matrices
diag(a1, . . . ,an )
the diagonal matrix with a1, . . . an on the principal diagonal
|x|
the absolute value of x ∈ R
|B|
the cardinality of (number of elements in) set B
f: A→B
f is a function from set A to set B x is mapped to y (under some given function)
x 7→ y RS
the set of all functions from S to R
Rn
all n-tuples of real numbers P the `1 norm i |xi | (see Section 2.3.1.1)
kxk1
the `∞ norm maxi |xi | (see Section 2.3.1.1)
kxk∞ kAk when A ∈
Mn×k
the operator norm of A (see Section 2.3.2.3)
ha,bi
the inner product of a and b
a∨b
the maximum of a and b (pointwise if they are vectors)
a∧b
the minimum of a and b (pointwise if they are vectors)
gh
function (or vector) g is everwhere strictly less than h
https://doi.org/10.1017/9781009456340.002 Published online by Cambridge University Press
xx
Common Symbols
1
vector of ones or function everywhere equal to one
1{P}
indicator, equal to 1 if statement P is true and 0 otherwise
i d (v)
in-degree of node v
od (v)
out-degree of node v
ℐ(v)
set of direct predecessors of node v
𝒪(v)
set of direct successors of node v
u→v
node v is accessible from node u
iid
independent and identically distributed
iff
if and only if
∀
for all
∃
there exist(s)
δx
the probability distribution concentrated on point x
𝒟(S) d
the set of distributions on S
X =Y
X and Y have the same distribution
X∼F
X has distribution F
5(ϕ,ψ) f ◦g
the set of all couplings of (ϕ,ψ) the composition of functions f and g
https://doi.org/10.1017/9781009456340.002 Published online by Cambridge University Press
1
Introduction
Relations are the fundamental fabric of reality. (Michele Coscia)
1.1
Motivation Alongside the exponential growth of computer networks over the last few decades, we have witnessed concurrent and equally rapid growth in a field called network science. Once computer networks brought network structure into clearer focus, scientists began to recognize networks almost everywhere, even in phenomena that had already received centuries of attention using other methods, and to apply network theory to organize and expand knowledge right throughout the sciences, in every field and discipline. The set of possible examples is vast, and sources mentioning or treating hundreds of different applications of network methods and graph theory are listed in the reading notes at the end of the chapter. In computer science and machine learning alone, we see computational graphs, graphical networks, neural networks, and deep learning. In operations research, network analysis focuses on minimum cost flow, traveling salesman, shortest path, and assignment problems. In biology, networks are a standard way to represent interactions between bioentities. In this book, our interest lies in economic and social phenomena. Here, too, networks are pervasive. Important examples include financial networks, production networks, trade networks, transport networks, and social networks. For example, social and information networks affect trends in sentiments and opinions, consumer decisions, and a range of peer effects. The topology of financial networks helps to determine the relative fragility of the financial system, while the structure of production networks affects trade, innovation, and the propagation of local shocks. Figures 1.1 and 1.2 show two examples of trade networks. Figure 1.1 is called a Sankey diagram, which is a kind of figure used to represent flows. Oil flows from left to right. The countries on the left and below are the top 10 exporters of crude oil, while the countries on the right are the top 20 consumers. The figure relates to one of our
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
2
Introduction Belarus Japan Thailand China India Rest of World Korea, Republic of
Kuwait
Netherlands
United Arab Emirates
Singapore Greece
Russian Federation
Poland Italy
Saudi Arabia
Indonesia France
Iraq
United Kingdom
Brazil
Germany
Spain
Nigeria Norway
Belgium United States of America
Figure 1.1 International trade in crude oil 2021
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
Canada
Sweden
Panama
3
1.1 Motivation
TJK TKM
EST
BGD
MLI
FJI
GEO
MAC BGR
AZE
CHN
UZB
RUS
SAU
LVA
GRC
IND LTU
NOR SRB MNG
IRL
CZE
GBR
HKG
NPL
POL IDN
MUS
ZAF
CYP
CHE
MLT SGP
USA
ESP
ARE
SWE
MEX
PHL
VNM MAR
LUX
NZL
NCL BEL
AUS
ITA
DEU BMU PAK
ISR COL CHL KHM
SLV FRO SYC
MYS
ZMB
MRT
OMN
UKR LBN
PAN HUN
BOL GRD
VGB
TWN
TUN
FIN
QAT JPN
ISL KEN
NGA
MMR
FRA
TUR PRT
KAZ
CAN
SEN
BWA
DNK NLD
KOR
EGY AUT
BRA THA
TZA
BHR
BLR
KWT
ETH
UGA
Figure 1.2 International trade in commercial aircraft during 2019
core topics: optimal (and equilibrium) flows across networks. We treat optimal flows at length in Chapter 3.1 Figure 1.2 shows international trade in large commercial aircraft in 2019.2 Node size is proportional to total exports, and link width is proportional to exports to the target country. The USA, France, and Germany are revealed as major export hubs. While some readers viewing Figures 1.1 and 1.2 might at first suspect that the network perspective adds little more than an attractive technique for visualizing data, it actually adds much more. For example, in Figure 1.2, node colors are based on a ranking of “importance” in the network called eigenvector centrality, which we introduce in §1.4.3.4. Such rankings and centrality measures are an active area of 1 This figure was constructed by QuantEcon research fellow Matthew McKay, using International Trade
Data (SITC, Rev 2) collected by The Growth Lab at Harvard University. 2 This figure was also constructed by Matthew McKay, using data 2019 International Trade Data SITC
Revision 2, code 7924. The data pertain to trade in commercial aircraft weighing at least 15,000 kg. It was sourced from CID Dataverse.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
4
Introduction
research among network scientists. Eigenvector and other forms of centrality feature throughout the text. For example, we will see that these concepts are closely connected to – and shed new light on – fundamental ideas first developed many years ago by researchers in the field of input–output economics. In addition, in production networks, it turns out that the nature of shock propagation is heavily dependent on the underlying structure of the network. For example, for a few highly connected nodes, shocks occurring within one firm or sector can have an outsized influence on aggregate-level fluctuations. Economists are currently racing to understand these relationships, their interactions with various centrality measures, and other closely related phenomena. To understand this line of work, as well as other applications of network methods to economics and finance, some technical foundations are required. For example, to define eigenvector centrality, we need to be familiar with eigenvectors, spectral decompositions, and the Perron–Frobenius theorem. To work with Katz centrality, which also features regularly in network science and economics, we require a sound understanding of the Neumann series lemma. The Perron–Frobenius theorem and the Neumann series lemma form much of the technical foundation of this textbook. We review them in detail in §1.2 and develop extensions throughout the remaining chapters. One reason that analysis of networks is challenging is high dimensionality. To see why, consider implementing a model with n economic agents. This requires n times more data than one representative agent in a setting where agents are atomistic or coordinated by a fixed number of prices. For example, Carvalho and Grassi (2019) model the dynamics of n = 6 × 106 firms, all of which need to be tracked when running a simulation. However, if we wish to model interactions between each pair i, j (supply linkages, liabilities, etc.), then, absent sparsity conditions, the data processing requirement grows like O(n 2 ).3 In the Carvalho and Grassi (2019) example, n 2 is 3.6 × 1013 , which is very large even for modern computers. One lesson is that network models can be hard to solve, even with powerful computers, unless we think carefully about algorithms. In general, to obtain a good grasp on the workings of economic networks, we will need computational skills plus a firm understanding of linear algebra, probability, and a field of discrete mathematics called graph theory. The rest of this chapter provides relevant background in these topics. Before tackling this background, we recommend that readers skim the list of common symbols on page xix, as well the mathematical topics in the appendix, which starts on page 180. (The appendix is not intended for sequential reading but rather as a source of definitions and fundamental results to be drawn on in what follows.)
3 See §A.3 for a discussion of big O notation.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.2 Spectral Theory
1.2
5
Spectral Theory In this section we review some linear algebra needed for the study of graphs and networks. Highlights include the spectral decomposition of diagonalizable matrices, the Neumann series lemma, and the theorem of Perron and Frobenius.
1.2.1
Eigendecompositions Our first task is to cover spectral decompositions and the spectral theorem. We begin with a brief review of eigenvalues and their properties. (If you are not familiar with eigenvalues and eigenvectors, please consult an elementary treatment first. See, for example, Cohen (2021).)
1.2.1.1
Eigenvalues Fix A in Mn×n . A scalar λ ∈ C is called an eigenvalue of A if there exists a nonzero complex vector e ∈ Cn such that Ae = λe. A vector e satisfying this equality is called an eigenvector corresponding to the eigenvalue λ. (Notice that eigenvalues and eigenvectors are allowed to be complex, even though we restrict elements of A to be real.) The set of all eigenvalues of A is called the spectrum of A and written as σ(A). As we show below, A has at most n distinct eigenvalues. In Julia, we can check for the eigenvalues of a given square matrix A via eigvals(A). Here is one example using LinearAlgebra A = [0 -1; 1 0] eigenvals = eigvals(A) Running this code in a Jupyter cell (with Julia kernel) produces 2-element Vector{ComplexF64}: 0.0 - 1.0im 0.0 + 1.0im Here im stands for i, the imaginary unit (i.e., i 2 = −1). Exercise 1.2.1. Using pencil and paper, confirm that Julia’s output is correct. In particular, show that ! 0 −1 A= H⇒ σ(A) = {i, − i}, 1 0 with corresponding eigenvectors (−1,i)> and (−1, − i)> . If λ ∈ σ(A) and e is an eigenvector for λ, then (λ,e) is called an eigenpair.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
6
Introduction
Exercise 1.2.2. Prove: if (λ,e) is an eigenpair of A and α is a nonzero scalar, then (λ,αe) is also an eigenpair of A. lemma 1.2.1
λ ∈ C is an eigenvalue of A if and only if det(A − λ I ) = 0.
Proof If λ ∈ R, then Lemma 1.2.1 follows directly from Theorem A.4.8 on page 201, since det(A − λ I ) = 0 is equivalent to the existence of a nonzero vector e such that (A − λ I )e = 0, which in turn says that λ is an eigenvalue of A. The same arguments extend to the case λ ∈ C because the statements in Theorem A.4.8 are also valid for complex-valued matrices (see, e.g., Jänich (1994)). It can be shown that p(λ) := det(A − λ I ) is a polynomial of degree n.4 This polynomial is called the characteristic polynomial of A. By the fundamental theorem of algebra, there are n roots (i.e., solutions in C to the equation p(λ) = 0), although some may be repeated as in the complete factorization of p(λ). By Lemma 1.2.1, (i) each of these roots is an eigenvalue, and (ii) no other eigenvalues exist besides these n roots. If λ ∈ σ(A) appears k times in the factorization of the polynomial p(λ), then λ is said to have algebraic multiplicity k. An eigenvalue with algebraic multiplicity one is called simple. A simple eigenvalue λ has the property that its eigenvector is unique up to a scalar multiple, in the sense of Exercise 1.2.2. In other words, the linear span of {e ∈ Cn : (λ,e) is an eigenpair} (called the eigenspace of λ) is one-dimensional. Exercise 1.2.3. For A ∈ Mn×n , show that λ ∈ σ(A) iff τλ ∈ σ(τ A) for all τ > 0. Exercise 1.2.4. A useful fact concerning eigenvectors is that if the characteristic polynomial p(λ) := det(A − λ I ) has n distinct roots, then the n corresponding eigenvectors form a basis of Cn . Prove this for the case where all eigenvectors are real – that is, show that the n (real) eigenvectors form a basis of Rn . (Bases are defined in §A.4.2. Proving this for n = 2 is also a good exercise.)
1.2.1.2
The Eigendecomposition What are the easiest matrices to work with? An obvious answer to this question is: diagonal matrices. For example, when D = diag(λi ) with i ∈ [n], • the linear system Dx = b reduces to n completely independent scalar equations; t t • the t-th power D is just diag(λi ); and −1 −1 • the inverse D is just diag(λi ), assuming all λi ’s are nonzero. While most matrices are not diagonal, there is a way that “almost any” matrix can be viewed as a diagonal matrix, after translation of the usual coordinates in Rn via an alternative basis. This can be extremely useful. The key ideas are described below. 4 See, for example, Jänich (1994), chapter 6.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.2 Spectral Theory
7
A ∈ Mn×n is called diagonalizable if A = P D P −1 for some D = diag(λ 1, . . . ,λ n ) and nonsingular matrix P. We allow both D and P to contain complex values. The representation P D P −1 is called the eigendecomposition or the spectral decomposition of A. One way to think about diagonalization is in terms of maps, as in Rn
A
Rn
D
Cn
P −1
Cn
P
Either we can map directly with A or, alternatively, we can shift to Cn via P −1 , apply the diagonal matrix D, and then shift back to Rn via P. The equality A = P D P −1 can also be written as A P = P D. Decomposed across column vectors, this equation says that each column of P is an eigenvector of A, and each element along the principal diagonal of D is an eigenvalue. Exercise 1.2.5. Confirm this. Why are column vectors taken from P nonzero, as required by the definition of eigenvalues? Exercise 1.2.6. The trace of a matrix is equal to the sum of its eigenvalues, and the determinant is their product. Prove this fact in the case where A is diagonalizable. Exercise 1.2.7. The asymptotic properties of the map m 7→ Am are determined by the eigenvalues of A. This is clearest in the diagonalizable case, where A = P diag(λi )P −1 . To illustrate, use induction to show that A = P diag(λi )P −1 H⇒ Am = P diag(λim )P −1 for all m ∈ N.
(1.1)
When does diagonalizability hold? While diagonalizability is not universal, the set of matrices in Mn×n that fail to be diagonalizable has “Lebesgue measure zero” in Mn×n . (Loosely speaking, only special or carefully constructed examples will fail to be diagonalizable.) The next results provide conditions for the property. theorem 1.2.2 A matrix A ∈ Mn×n is diagonalizable if and only if its eigenvectors form a basis of Cn . This result is intuitive: for A = P D P −1 to hold, we need P to be invertible, which requires that its n columns are linearly independent. Since Cn is n-dimensional, this means that the columns form a basis of Cn . corollary 1.2.3 If A ∈ Mn×n has n distinct eigenvalues, then A is diagonalizable. Proof See Exercise 1.2.4.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
8
Introduction
Exercise 1.2.8. Give a counterexample to the statement that the condition in Corollary 1.2.3 is necessary as well as sufficient. There is another way that we can establish diagonalizability, based on symmetry. Symmetry also lends the diagonalization certain properties that turn out to be very useful in applications. We are referring to the following celebrated theorem. theorem 1.2.4 (Spectral theorem) If A ∈ Mn×n is symmetric, then there exists a real orthonormal n × n matrix U such that A = U DU >
with
λi ∈ R+ for all i, where D = diag(λ1, . . . ,λ n ).
Since, for the orthonormal matrix U , we have U > = U −1 (see Lemma A.4.9), one consequence of the spectral theorem is that A is diagonalizable. For obvious reasons, we often say that A is orthogonally diagonalizable.
1.2.1.3
Worker Dynamics Let’s study a small application of eigendecomposition. Suppose that, each month, workers are hired at rate α and fired at rate β. Their two states are unemployment (state 1) and employment (state 2). Figure 1.3 shows the transition probabilities for a given worker in each of these two states. We translate these dynamics into the matrix ! 1−α α Pw = , where 0 6 α,β 6 1. (1.2) β 1−β • Row 1 of Pw gives probabilities for unemployment and employment, respectively, when currently unemployed. • Row 2 of Pw gives probabilities for unemployment and employment, respectively, when currently employed.
1−α
α unemployed
employed β
1−β Figure 1.3 Worker transition dynamics
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
9
1.2 Spectral Theory
Exercise 1.2.9. Using Lemma 1.2.1, show that the two eigenvalues of Pw are λ1 := 1 and λ 2 := 1 − α − β. Show that, when min{α,β} > 0, ! ! 1 −α e1 := and e2 := 1 β are two corresponding eigenvectors and that λ 1 and λ2 are simple. Exercise 1.2.10. Show that, when α = β = 0, the eigenvalue λ 1 is not simple. Below we demonstrate that the m-th power of Pw provides m-step transition probabilities for workers. Anticipating this discussion, we now seek an expression for Pwm at arbitrary m ∈ N. This problem is simplified if we use diagonalization. Exercise 1.2.11. Assume that min{α,β} > 0. (When α = β = 0, computing the powers of Pw is trivial.) Show that ! ! 1 0 1 −α −1 Pw = E D E when D = and E = . 0 λ2 1 β Using (1.1), prove that Pwm
1 = α+β
β + α(1 − α − β)m β(1 − (1 − α − β)m )
! α(1 − (1 − α − β)m ) α + β(1 − α − β)m
(1.3)
for every m ∈ N.
1.2.1.4
Left Eigenvectors A vector ε ∈ Cn is called a left eigenvector of A ∈ Mn×n if ε is an eigenvector of A> . In other words, ε is nonzero, and there exists a λ ∈ C such that A> ε = λε. We can alternatively write the expression as ε> A = λε> , which is where the name “left” eigenvector originates. Left eigenvectors will play important roles in what follows, including that of stochastic steady states for dynamic models under a Markov assumption. To help distinguish between ordinary and left eigenvectors, we will at times call (ordinary) eigenvectors of A right eigenvectors of A. If A is diagonalizable, then so is A> . To show this, let A = P D P −1 with D = diag(λi ). We know from earlier discussion that the columns of P are the (right) eigenvectors of A. Exercise 1.2.12. Let Q = (P > )−1 . Prove that Q > P = I and A> = Q D Q −1 . The results of the last exercise show that, when A = P D P −1 , the columns of coincide with the left eigenvectors of A. (Why?) Equivalently, A = P D Q > , where Q = (ε1, . . . ,εn ) is the n × n matrix with i-th column equal to the i-th left eigenvector of A. (P > )−1
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
10
Introduction
n n Exercise 1.2.13. Let (ei )i=1 be right eigenvectors of A, and let (εi )i=1 be the left eigenvectors. Prove that
εi ,e j = 1{i = j} (i, j ∈ [n]). (1.4)
[Hint: Use the results of Exercise 1.2.12.] Exercise 1.2.14. Continuing with the notation defined above and continuing to assume that A is diagonalizable, prove that A=
n X
λi ei εi>
and
i=1
Am =
n X
λim ei εi>
(1.5)
i=1
for all m ∈ N. The expression for A on the left-hand side of (1.5) is called the spectral representation of A. Exercise 1.2.15. Prove that each n × n matrix λi ei εi> in the sum rank 1.
1.2.1.5
Pn
i=1
λi ei εi> is
Similar Matrices Diagonalizability is a special case of a more general concept: A ∈ Mn×n is called similar to B ∈ Mn×n if there exists an invertible matrix P such that A = P B P −1 . In this terminology, A is diagonalizable if and only if it is similar to a diagonal matrix. Exercise 1.2.16. Prove that similarity between matrices is an equivalence relation (see §A.1.2) on Mn×n . Exercise 1.2.17. The fact that similarity is an equivalence relation on Mn×n implies that this relation partitions Mn×n into disjoint equivalence classes, elements of which are all similar. Prove that all matrices in each equivalence class share the same eigenvalues. Exercise 1.2.18. Prove: If A is similar to B, then Am is similar to B m . In particular A = P B P −1 H⇒ Am = P B m P −1 for all m ∈ N. The last result is a generalization of (1.1). When A is large, calculating the powers Ak can be computationally expensive or infeasible. If, however, A is similar to some simpler matrix B, then we can take powers of B instead, and then transition back to A using the similarity relation.5
5 The only concern with this shift process is that P can be ill-conditioned, implying that the inverse is
numerically unstable.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.2 Spectral Theory
1.2.2
11
The Neumann Series Lemma Most high school students learn that, if a is a number with |a| < 1, then X 1 ai = . 1−a
(1.6)
i>0
This geometric series representation extends to matrices: If A is a matrix satisfying a P certain condition, then (1.6) holds, in the sense that i>0 Ai = (I − A)−1 . (Here I is the identity matrix.) But what is the “certain condition” that we need to place on A, which generalizes the concept |a| < 1 to matrices? The answer to this question involves the “spectral radius” of a matrix, which we now describe.
1.2.2.1
Spectral Radius Fix A ∈ Mn×n . With |z| indicating the modulus of a complex number z, the spectral radius of A is defined as r (A) := max{|λ| : λ is an eigenvalue of A}.
(1.7)
Within economics, the spectral radius has important applications in dynamics, asset pricing, and numerous other fields. As we will see, the same concept also plays a key role in network analysis. remark 1.2.1 For any square matrix A, we have r (A> ) = r (A). This follows from the fact that A and A> always have the same eigenvalues. Example 1.2.1: As usual, diagonal matrices supply the simplest example: If D = diag(di ), then the spectrum σ(D) is just {di }i∈[n] , and hence r (D) = maxi |di |. After executing import numpy as np The following Python code computes the spectral radius of a square matrix M: def spec_rad(M): return np.max(np.abs(np.linalg.eigvals(M)))
1.2.2.2
Geometric Series We can now return to the matrix extension of (1.6) and state a formal result. theorem 1.2.5 (Neumann series lemma (NSL)) then I − A is nonsingular and (I − A)−1 =
∞ X
If A is in Mn×n and r (A) < 1,
Am .
(1.8)
m=0
P∞
Am
The sum is called the power series representation of (I − A)−1 . m=0 Convergence of the matrix series is understood as element-by-element convergence.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
12
Introduction
A full proof of Theorem 1.2.5 can be found in Cheney (2013) and many other sources. The core idea is simple: if S = I + A + A2 + · · · then I + AS = S. Reorganizing gives (I − A)S = I , which is equivalent to (1.8). The main technical issue is showing that the power series converges. The full proof shows that this always holds when r (A) < 1. Exercise 1.2.19. Fix A ∈ Mn×n . Prove the following: if r (A) < 1, then, for each b ∈ Rn , the linear system x = Ax + b has the unique solution x ∗ ∈ Rn given by x∗ =
∞ X
Am b.
(1.9)
m=0
1.2.3
The Perron–Frobenius Theorem In this section we state and discuss a suprisingly far-reaching theorem due to Oskar Perron and Ferdinand Frobenius, which has applications in network theory, machine learning, asset pricing, Markov dynamics, nonlinear dynamics, input–output analysis, and many other fields. In essence, the theorem provides additional information about eigenvalues and eigenvectors when the matrix in question is positive in some sense.
1.2.3.1
Order in Matrix Space We require some definitions. In what follows, for A ∈ Mn×k , we write • A > 0 if all elements of A are nonnegative and • A 0 if all elements of A are strictly positive. It’s easy to imagine how nonnegativity and positivity are important notions for matrices, just as they are for numbers. However, strict positivity of every element of a matrix is hard to satisfy, especially for a large matrix. As a result, mathematicians routinely use two notions of “predominantly strictly positive,” which sometimes provide sufficient positivity for the theorems that we need. Regarding these two notions, for A ∈ Mn×n , we say that A > 0 is P∞ m • irreducible if m=0 A 0 and m • primitive if there exists an m ∈ N such that A 0. Evidently, for A ∈ Mn×n we have A 0 H⇒ A primitive
H⇒ A irreducible
H⇒ A > 0.
A nonnegative matrix is called reducible if it fails to be irreducible. Exercise 1.2.20. By examining the expression for Pwm in (1.3), show that Pw is (i) irreducible if and only if 0 < α,β 6 1; and (ii) primitive if and only if 0 < α,β 6 1 and min{α,β} < 1.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
13
1.2 Spectral Theory
In addition to the above notation, for A, B ∈ Mn×k , we also write • A > B if A − B > 0 and A B if A − B 0, • A 6 0 if −A > 0, etc. Exercise 1.2.21. Show that 6 is a partial order (see §A.2.1) on Mn×k . The partial order 6 discussed in Exercise 1.2.21 is usually called the pointwise partial order on Mn×k . Analogous notation and terminology are used for vectors. The following exercise shows that nonnegative matrices are order-preserving maps (see §A.2.3) on vector space under the pointwise partial order – a fact we shall exploit many times. Exercise 1.2.22. Show that the map x 7→ Ax is order-preserving (see §A.2.3) whenever A > 0 (i.e., x 6 y implies Ax 6 Ay for any conformable vectors x, y).
1.2.3.2
Statement of the Theorem Let A be in Mn×n . In general, r (A) is not an eigenvalue of A. For example, A = diag(−1,0) H⇒ σ(A) = {−1,0} while r (A) = 1. But r (A) is always an eigenvalue when A > 0. This is just one implication of the following famous theorem. theorem 1.2.6 (Perron–Frobenius) If A > 0, then r (A) is an eigenvalue of A with nonnegative real right and left eigenvectors: ∃ nonzero e,ε ∈ Rn+ such that Ae = r (A)e and ε> A = r (A)ε > .
(1.10)
If A is irreducible, then, in addition, (i) r (A) is strictly positive and a simple eigenvalue; (ii) the eigenvectors e and ε are everywhere positive; and (iii) eigenvectors of A associated with other eigenvalues fail to be nonnegative. If A is primitive, then, in addition, (i) the inequality |λ| 6 r (A) is strict for all eigenvalues λ of A distinct from r (A); and (ii) with e and ε normalized so that hε,ei = 1, we have r (A)−m Am → e ε>
(m → ∞).
(1.11)
The fact that r (A) is simple under irreducibility means that its eigenvectors are unique up to scalar multiples. We will exploit this property in several important uniqueness proofs. In the present context, r (A) is called the dominant eigenvalue or Perron root of A, while ε and e are called the dominant left and right eigenvectors of A, respectively.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
14
Introduction
Why do we use the word “dominant” here? To help illustrate, let us suppose that A ∈ Mn×n is primitive and fix any x ∈ Rn . Consider what happens to the point xm := Am x as m grows. By (1.11) we have Am x ≈ r (A)m ce for large m, where c = ε> x. In other words, asymptotically, the sequence (Am x)m∈N is just scalar multiples of e, growing at rate ln r (A). Thus, r (A) dominates other eigenvalues in controlling the growth rate of Am x, while e dominates other eigenvectors in controlling the direction of growth. Exercise 1.2.23. The n × n matrix P := e ε> in (1.11) is called the Perron projection of A. Prove that P 2 = P (a property that is often used to define projection matrices) and rank P = 1. Describe the one-dimensional space that P projects all of Rn into.
Example 1.2.2: Fix A > 0. If r (A) = 1, then I − A is not invertible. To see this, observe that, by Theorem 1.2.6, since r (A) is an eigenvalue of A, there exists a nonzero vector e such that (I − A)e = 0. The claim follows. (Why?)
1.2.3.3
Worker Dynamics II We omit the full proof of Theorem 1.2.6, which is quite long and can be found in Meyer (2000), Seneta (2006b), or Meyer-Nieberg (2012).6 Instead, to build intuition, let us prove the theorem in a rather simple special case. The special case we will consider is the class of matrices ! 1−α α Pw = with 0 6 α,β 6 1. β 1−β This example is drawn from the study of worker dynamics in §1.2.1.3. You might recall from §1.2.1.3 that λ 1 = 1 and λ 2 = 1 − α − β. Clearly r (A) = 1, so r (A) is an eigenvalue, as claimed by the first part of the Perron–Frobenius theorem. From now on we assume that min{α,β} > 0, which just means that we are excluding the identity matrix in order to avoid some tedious qualifying remarks. The two right eigenvectors (e1,e2 ) and two left eigenvectors (ε1,ε2 ) are, respectively, ! ! ! ! 1 1 −α α α e1 := , e2 := , ε1 := , and ε2 := . 1 β −α α+β β Exercise 1.2.24. Verify these claims. (The right eigenvectors were treated in §1.2.1.3.) Exercise 1.2.25. Recall from Exercise 1.2.20 that Pw is irreducible if and only if both α and β are strictly positive. Show that all the claims about irreducible 6 See also Glynn and Desai (2018), which provides a new proof of the main results, based on probabilistic
arguments, including extensions to infinite state spaces. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.3 Probability
15
matrices in the Perron–Frobenius theorem are valid for Pw under this irreducibility condition. Exercise 1.2.26. Recall from Exercise 1.2.20 that Pw is primitive if and only if 0 < α,β 6 1 and min{α,β} < 1. Verify the claim (1.11) for Pw under these conditions. In doing so, you can use the expression for Pwm in (1.3).
1.2.3.4
Bounding the Spectral Radius Using the Perron–Frobenius theorem, we can provide useful bounds on the spectral radius of a nonnegative matrix. In what follows, fix A = (ai j ) ∈ Mn×n and set P • rowsumi (A) := P j ai j = the i-th row sum of A and • colsum j (A) := i ai j = the j-th column sum of A. lemma 1.2.7 If A > 0, then (i) mini rowsumi (A) 6 r (A) 6 maxi rowsumi (A) and (ii) min j colsum j (A) 6 r (A) 6 max j colsum j (A). Proof Let A be as stated and let e be the right eigenvector in (1.10). Since P e is nonnegative and nonzero, we can and do assume that j e j = 1. From P Ae = r (A)e, we have j ai j e j = r (A)ei for all i. Summing with respect to i P gives j colsum j (A)e j = r (A). Since the elements of e are nonnegative and sum to one, r (A) is a weighted average of the column sums. Hence the second pair of bounds in Lemma 1.2.7 holds. The remaining proof is similar (use the left eigenvector).
1.3
Probability Next we review some elements of probability that will be required for analysis of networks.
1.3.1
Discrete Probability We first introduce probability models on finite sets and then consider sampling methods and stochastic matrices.
1.3.1.1
Probability on Finite Sets Throughout this text, if S is a finite set, then we set ( ) X S 𝒟(S) := ϕ ∈ R+ : ϕ(x) = 1 x∈S
and call 𝒟(S) the set of distributions on S. We say that a random variable X taking d
values in S has distribution ϕ ∈ 𝒟(S) and write X = ϕ if P{X = x} = ϕ(x) https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
for all x ∈ S.
16
Introduction
(0, 0, 1)
(1, 0, 0) (0, 1, 0)
Figure 1.4 If S = {1,2,3}, then 𝒟(S) is the unit simplex in R3
n A distribution ϕ can also be understood as a vector (ϕ(xi ))i=1 ∈ Rn (see Lemma A.1.2 in §A.1.3). As a result, 𝒟(S) can be viewed as a subset of Rn . Figure 1.4 provides a visualization when S = {1,2,3}. Each ϕ ∈ 𝒟(S) is identified by the point (ϕ(1),ϕ(2),ϕ(3)) in R3 . More generally, if |S| = n, then 𝒟(S) can be identified with the unit simplex in Rn , which is the set of all n-vectors that are nonnegative and sum to one. Throughout, given x ∈ S, we use the symbol δ x to represent the element of 𝒟(S) that puts all mass on x. In other words, δ x (y) = 1{y = x} for all y ∈ S. In Figure 1.4, each δ x is a vertex of the unit simplex. We frequently make use of the law of total probability, which states that, for a random variable X on S and arbitrary A ⊂ S, X P{X ∈ A} = P{X ∈ A | X ∈ Bi }P{X ∈ Bi }, (1.12) i
where {Bi } is a partition of S (i.e., finite collection of disjoint subsets of S such that their union equals S). Exercise 1.3.1. Prove (1.12) assuming P{X ∈ Bi } > 0 for all i.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
17
1.3 Probability
1.3.1.2
Inverse Transform Sampling Let S be a finite set. Suppose we have the ability to generate random variables that are uniformly distributed on (0,1]. We now want to generate random draws from S that are distributed according to arbitrary ϕ ∈ 𝒟(S). Let W be uniformly distributed on (0,1], so that, for any a 6 b ∈ (0,1], we have P{a < W 6 b} = b − a, which is the length of the interval (a,b].7 Our problem will be solved if we can create a function z 7→ κ(z) from (0,1] to S such that κ(W ) has distribution ϕ. One technique is as follows. First we divide the unit interval (0,1] into disjoint subintervals, one for each x ∈ S. The interval corresponding to x is denoted I (x) and is chosen to have length ϕ(x). More specifically, when S = {x1, . . . ,x N }, we take I (xi ) := (qi−1, qi ],
where qi := ϕ(x1 ) + · · · + ϕ(xi )
You can easily confirm that the length of I (xi ) is ϕ(xi ) for all i. Now consider the function z 7→ κ(z) defined by X κ(z) := x1{z ∈ I (x)} (z ∈ (0,1]),
and q0 := 0.
(1.13)
x∈S
where 1{z ∈ I (x)} is one when z ∈ I (x) and zero otherwise. It turns out that κ(W ) has the distribution we desire. Exercise 1.3.2. Prove: (i) For all x ∈ S, we have κ(z) = x if and only if z ∈ I (x). (ii) The random variable κ(W ) has distribution ϕ. Exercise 1.3.3. Let ϕ, κ, and W be as defined above. Prove that E1{κ(W ) = j} = ϕ( j) holds for all j ∈ [n]. Exercise 1.3.4. Using Julia or another language of your choice, implement the inverse transform sampling procedure described above when S = {1,2,3} and ϕ = (0.2,0.1,0.7). Generate 1,000,000 (quasi)independent draws (X i ) from ϕ, and conPn firm that (1/n) i=1 1{X i = j} ≈ ϕ( j) for j ∈ {1,2,3}. The last exercise tells us that the law of large numbers holds in this setting, since, under this law, we expect that n 1X 1{X i = j} → E1{X i = j} n i=1
with probability one as n → ∞. In view of Exercise 1.3.3, the right-hand side equals ϕ( j). 7 The probability is the same no matter whether inequalities are weak or strict.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
18
Introduction
Exercise 1.3.5. Suppose that, on a computer, you can generate only uniform random variables on (0,1], and you wish to simulate a flip of a biased coin with heads probability δ ∈ (0,1). Propose a method. Exercise 1.3.6. Suppose that, on a computer, you are able to sample from distributions ϕ and ψ defined on some set S. The set S can be discrete or continuous and, in the latter case, the distributions are understood as densities. Propose a method to sample on a computer from the convex combination f (s) = δϕ(s) + (1 − δ)ψ(s), where δ ∈ (0,1).
1.3.1.3
Stochastic Matrices A matrix P = ( pi j ) ∈ Mn×n is called a stochastic matrix if P>0
and
P1 = 1, where 1 ∈ Rn is a column vector of ones.
In other words, P is nonnegative and has unit row sums. We will see many applications of stochastic matrices in this text. Often the applications are probabilistic, where each row of P is interpreted as a distribution over a finite set. Exercise 1.3.7. Let P, Q be n × n stochastic matrices. Prove the following facts. (i) P Q is also stochastic. (ii) r (P) = 1. (iii) There exists a row vector ψ ∈ Rn+ such that ψ1 = 1 and ψ P = ψ. The vector ψ in part (iii) of Exercise 1.3.7 is called the PageRank vector by some authors, due to its prominence in Google’s PageRank algorithm. We will call it a stationary distribution instead.8 Stationary distributions play a key role in the theory of Markov chains, to be treated in §4.1. Ranking methods are discussed again in §1.4.3. PageRank is treated in more detail in §4.2.3.3.
1.3.2
Power Laws Next we discuss distributions on the (nondiscrete) sets R and R+ . We are particularly interested in a certain class of distributions that are apparently nonstandard and yet appear with surprising regularity in economics, social science, and the study of networks. We refer to distributions that are said to obey a “power law.” In what follows, given a real-valued random variable X , the function F(t) := P{X 6 t}
(t ∈ R)
8 Stationary distributions of stochastic matrices were intensively studied by many mathematicians well
over a century before Larry Page and Sergey Brin patented the PageRank algorithm, so it seems unfair to allow them to appropriate the name.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.3 Probability
19
is called the cumulative distribution function (cdf) of X . The counter cdf (ccdf) of X is the function G(t) := P{X > t} = 1 − F(t). A useful property that holds for any nonnegative random variable X and p ∈ R+ is the identity Z ∞ EXp = pt p−1 P{X > t} dt. (1.14) 0
See, for example, Çınlar (2011), p. 63.
1.3.2.1
Heavy Tails Recall that a random variable X on R is said to be normally distributed with mean d µ and variance σ2 , and we write X = N (µ,σ2 ), if X has density r 1 −(t − µ)2 exp (t ∈ R). ϕ(t) := 2πσ2 2σ2 One notable feature of the normal density is that the tails of the density approach zero quickly. For example, ϕ(t) goes to zero like exp(−t 2 ) as t → ∞, which is extremely fast. A random variable X on R+ is called exponentially distributed and we write d
X = Exp(λ) if, for some λ > 0, X has density p(t) = λe−λt
(t > 0).
The tails of the exponential density go to zero like exp(−t) as t → ∞, which is also relatively fast. When a distribution is relatively light-tailed, in the sense that its tails go to zero quickly, draws rarely deviate more than a few standard deviations from the mean. In the case of a normal random variable, the probability of observing a draw more than three standard deviations above the mean is around 0.0014. For six standard deviations, the probability falls to 10−11 . In contrast, for some distributions, “extreme” outcomes occur relatively frequently. The left panel of Figure 1.5 helps to illustrate this by simulating 1,000 independent draws from Student’s t-distribution, with 1.5 degrees of freedom. For comparison, the right subfigure shows an equal number of independent draws from the N (0,4) distribution. The Student’s t draws reveal tight clustering around zero combined with a few large deviations. Formally, a random variable X on R is called light-tailed if its moment generating function m(t) := Eet X
(t > 0)
(1.15)
is finite for at least one t > 0. Otherwise X is called heavy-tailed.9 9 Terminology on heavy tails varies across the literature, but our choice is increasingly standard. See, for
example, Foss et al. (2011) or Nair et al. (2021).
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
20
Introduction
N (0; ¾ 2 ) with ¾ = 2
Student t draws 40
40
20
20
0
0
−20
−20
−40
−40 0
200
400
600
800
1000
0
200
400
600
800
1000
Figure 1.5 Independent draws from Student’s t- and normal distributions d
Example 1.3.1: If X = N (µ,σ2 ), the moment generating function of X is known to be t 2 σ2 m(t) = exp µt + (t > 0). 2 Hence X is light-tailed. Example 1.3.2: A random variable X on (0,∞) is said to have lognormal density d d and we write X = L N (µ,σ2 ) if ln X = N (µ,σ2 ). The mean and variance of this distribution are, respectively, E X = exp(µ + σ 2 /2)
and
Var X = (exp(σ2 ) − 1) exp(2µ + σ2 ).
The moment generating function m(t) is known to be infinite for all t > 0, so any lognormally distributed random variable is heavy-tailed. For any random variable X and any r > 0, the (possibly infinite) expectation E|X |r called the r -th moment of X . lemma 1.3.1 Let X be a random variable on R+ . If X is light-tailed, then all of its moments are finite. Proof Pick any r > 0. We will show that EX r < ∞. Since X is light-tailed, there exists a t > 0 such that m(t) = E exp(t X ) < ∞. For a sufficiently large constant x¯ we have exp(t x) > x r whenever x > x. ¯ As a consequence, with F as the distribution of X , we have Z x¯ Z ∞ r r EX = x F(dx) + x r F(dx) 6 x¯ r + m(t) < ∞. 0
x¯
Exercise 1.3.8. Prove that the lognormal distribution has finite moments of every order. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.3 Probability
21
Together with Lemma 1.3.1, Exercise 1.3.8 shows that existence of an infinite moment is a sufficient but not necessary condition for heavy tails.
1.3.2.2
Pareto Tails Given α > 0, a nonnegative random variable X is said to have a Pareto tail with tail index α if there exists a c > 0 such that lim t α P{X > t} = c.
t→∞
(1.16)
In other words, the ccdf G of X satisfies G(t) ≈ ct −α for large t.
(1.17)
If X has a Pareto tail for some α > 0, then X is also said to obey a power law. Example 1.3.3: A random variable X on R+ is said to have a Pareto distribution with parameters x,α ¯ > 0 if its ccdf obeys ( 1 if t < x¯ . (1.18) G(t) = α ¯ if t > x¯ (x/t) It should be clear that such an X has a Pareto tail with tail index α. Regarding Example 1.3.3, note that the converse is not true: Pareto-tailed random variables are not necessarily Pareto-distributed, since the Pareto tail property only restricts the far right-hand tail. Exercise 1.3.9. Show that, if X has a Pareto tail with tail index α, then E[X r ] = ∞ for all r > α. [Hint: Use (1.14).] From Exercise 1.3.9 and Lemma 1.3.1, we see that every Pareto-tailed random variable is heavy-tailed. The converse is not true, since the Pareto tail property (1.16) is very specific. Despite this, it turns out that many heavy-tailed distributions encountered in the study of networks are, in fact, Pareto-tailed. d
Exercise 1.3.10. Prove: If X = Exp(λ) for some λ > 0, then X does not obey a power law.
1.3.2.3
Empirical Power Law Plots When the Pareto tail property holds, the ccdf satisfies ln G(t) ≈ ln c − α ln t for large t. In other words, G is eventually log linear. Figure 1.6 illustrates this using a Pareto distribution. For comparison, the ccdf of an exponential distribution is also shown. If we replace the ccdf G with its empirical counterpart – which returns, for each x, the fraction of the sample with values greater than x – we should also obtain an approximation to a straight line under the Pareto tail assumption.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
22
Introduction
0
ln G(x)
−2
−4
−6
−8
Pareto Exponential
−10 0.0
0.5
1.0
1.5
2.0
ln x Figure 1.6 ccdf plots for the Pareto and exponential distributions
0
log prob.
−1 −2 −3 −4 −5
firm size (market value) slope = −1.32
−6 10
11
12
13
14
log value Figure 1.7 Empirical ccdf plots for largest firms (Forbes)
For example, consider the cross-sectional distribution of firm sizes. While the precise nature of this distribution depends on the measure of firm size, the sample of firms, and other factors, the typical picture is one of extreme heavy tails. As an illustration, Figure 1.7 shows an empirical ccdf log–log plot for market values of the largest 500 firms in the Forbes Global 2000 list, as of March 2021. The slope estimate and data distribution are consistent with a Pareto tail and infinite population variance.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
23
1.3 Probability
1.3.2.4
Discrete Power Laws Let X be a random variable with the Pareto distribution, as described in Example 1.3.3. The density of this random variable on the set [x,∞) ¯ is p(t) = ct −γ with c := α x¯ α and γ := α + 1. The next exercise extends this idea. Exercise 1.3.11. Let X be a random variable with density p on R+ . Suppose that, for some constants c > 0, γ > 1, and x¯ ∈ R+ , we have p(t) = ct −γ
whenever t > x. ¯
(1.19)
Prove that X is Pareto-tailed with tail index α := γ − 1. The discrete analog of (1.19) is a distribution on the positive integers with f (k) = ck −γ
(1.20)
for large k. In the special case where this equality holds for all k ∈ N, and c is chosen P so that k∈N f (k) = 1, we obtain the zeta distribution.10 In general, when we see a probability mass function with the specification (1.20) for large k, we can identify this with a Pareto tail, with tail index α = γ − 1. Figure 1.8 illustrates with γ = 2.
2
zeta distribution with γ = 2 density of Pareto with tail index α
1
0 2
4
6
8
10
Figure 1.8 Zeta and Pareto distributions
10 Obviously the correct value of c depends on γ, so we can write c = H (γ) for some suitable function
H . The correct function for this normalization is called the Riemann zeta function.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
24
Introduction
1.4
Graph Theory Graph theory is a major branch of discrete mathematics. It plays an essential role in this text because it forms the foundations of network analysis. This section provides a concise introduction to graph theory suitable for our purposes.11 Graph theory has another closely related use: Many economic models are stochastic and dynamic, which means that they specify states of the world and rates of transition between them. One of the most natural ways to conceptualize these notions is to view states as vertices in a graph and transition rates as relationships between them. We begin with definitions and fundamental concepts. We focus on directed graphs, where there is a natural asymmetry in relationships (bank A lends money to bank B, firm A supplies goods to firm B, etc.). This costs no generality, since undirected graphs (where relationships are symmetric two-way connections) can be recovered by insisting on symmetry (i.e., existence of a connection from A to B implies existence of a connection from B to A).
1.4.1
Unweighted Directed Graphs We begin with unweighted directed graphs and examine standard properties, such as connectedness and aperiodicity.
1.4.1.1
Definition and Examples A directed graph or digraph is a pair 𝒢 = (V , E), where • V is a finite nonempty set and • E is a collection of ordered pairs (u,v) ∈ V × V called edges. Elements of V are called the vertices or nodes of 𝒢. Intuitively and visually, an edge (u,v) is understood as an arrow from vertex u to vertex v. Two graphs are given in Figures 1.9 and 1.10. Each graph has three vertices. In these cases, the arrows (edges) could be thought of as representing positive possibility of transition over a given unit of time.
middle class poor
rich
Figure 1.9 A digraph of classes
11 Graph theory is often regarded as originating from work by the brilliant Swiss mathematician Leonhard
Euler (1707–1783), including his famous paper on the “Seven Bridges of Königsberg.”
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
25
poor
middle class
rich
Figure 1.10 An alternative edge list
For a given edge (u,v), the vertex u is called the tail of the edge, while v is called the head. Also, u is called a direct predecessor of v, and v is called a direct successor of u. For v ∈ V , we use the following notation: • ℐ(v) := the set of all direct predecessors of v • 𝒪(v) := the set of all direct successors of v Also, the in-degree and out-degree of v ∈ V are defined by • the i d (v) := |ℐ(v)| and • the od (v) := |𝒪(v)|, respectively. If i d (v) = 0 and od (v) > 0, then v is called a source. If either 𝒪(v) = ∅ or 𝒪(v) = {v}, then v is called a sink. For example, in Figure 1.10, “poor” is a sink with an in-degree of 3.
1.4.1.2
Digraphs in NetworkX Both Python and Julia provide valuable interfaces to numerical computing with graphs. Of these libraries, the Python package NetworkX is probably the most mature and fully developed. It provides a convenient data structure for representing digraphs and implements many common routines for analyzing them. To import it into Python we run import networkx as nx In all of the code snippets shown below, we assume readers have executed this import statement, as well as import numpy as np import matplotlib.pyplot as plt As an example, let us create the digraph in Figure 1.10, which we denote henceforth by 𝒢 p . To do so, we first create an empty DiGraph object: G_p = nx.DiGraph() Next we populate it with nodes and edges. To do this we write down a list of all edges, with poor represented by p and so on:
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
26
Introduction
edge_list (’p’, (’m’, (’r’, ]
= [ ’p’), ’p’), (’m’, ’m’), (’m’, ’r’), ’p’), (’r’, ’m’), (’r’, ’r’)
Finally, we add the edges to our DiGraph object: for e in edge_list: u, v = e G_p.add_edge(u, v) Adding the edges automatically adds the nodes, so G_p is now a correct representation of 𝒢 p . For our small digraph we can verify this by plotting the graph via NetworkX with the following code: fig, ax = plt.subplots() nx.draw_spring(G_p, ax=ax, node_size=500, with_labels=True, font_weight=’bold’, arrows=True, alpha=0.8, connectionstyle=’arc3,rad=0.25’, arrowsize=20) plt.show()
This code produces Figure 1.11, which matches the original digraph in Figure 1.10. DiGraph objects have methods that calculate the in-degrees and out-degrees of vertices. For example, G_p.in_degree(’p’) prints 3.
p
m
r Figure 1.11 NetworkX digraph plot
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
1.4.1.3
27
Communication Next we study communication and connectedness, which have important implications for production, financial, transportation, and other networks, as well as for dynamic properties of Markov chains. A directed walk from vertex u to vertex v of a digraph 𝒢 is a finite sequence of vertices, starting with u and ending with v, such that any consecutive pair in the sequence is an edge of 𝒢. A directed path from u to v is a directed walk from u to v such that all vertices in the path are distinct. For example, in Figure 1.12, (3,2,3,2,1) is a directed walk from 3 to 1 but not a directed path, while (3,2,1) is both a directed path and a directed walk from 3 to 1. As is standard, the length of a directed walk (or path) counts the number of edges rather than vertices. For example, the directed path (3,2,1) from 3 to 1 in Figure 1.12 is said to have length 2. Vertex v is called accessible (or reachable) from vertex u, and we write u → v, if either u = v or there exists a directed path from u to v. A set U ⊂ V is called absorbing for the directed graph (V , E) if no element of V \ U is accessible from U . Example 1.4.1: Let 𝒢 = (V , E) be a digraph representing a production network, where elements of V are sectors, and (i, j) ∈ E means that i supplies products or services to j. Then sector m is an upstream supplier of sector ` whenever m → `. Example 1.4.2: The vertex {poor} in the Markov digraph displayed in Figure 1.10 is absorbing, since {middle, rich} is not accessible from {poor}. Two vertices u and v are said to communicate if u → v and v → u. Exercise 1.4.1. Let (V , E) be a directed graph, and write u ∼ v if u and v communicate. Show that ∼ is an equivalence relation (see §A.1.2). Since communication is an equivalence relation, it induces a partition of V into a finite collection of equivalence classes. Within each of these classes, all elements communicate. These classes are called strongly connected components. The graph itself is called strongly connected if there is only one such component; that is, v is accessible from u for any pair (u,v) ∈ V × V . This corresponds to the idea that any node can be reached from any other.
1
2
3
Figure 1.12 Strongly connected components of a digraph (rectangles)
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
28
Introduction
Example 1.4.3: Figure 1.12 shows a digraph with strongly connected components {1} and {2,3}. The digraph is not strongly connected. Example 1.4.4: In Figure 1.9, the digraph is strongly connected. In contrast, in Figure 1.10, rich is not accessible from poor, so the graph is not strongly connected. NetworkX can be used to test for communication and strong connectedness, as well as to compute strongly connected components. For example, applied to the digraph in Figure 1.12, the code G = nx.DiGraph() G.add_edge(1, 1) G.add_edge(2, 1) G.add_edge(2, 3) G.add_edge(3, 2) list(nx.strongly_connected_components(G)) prints [{1}, {2, 3}].
1.4.1.4
Aperiodicity A cycle (u,v,w, . . . ,u) of a directed graph 𝒢 = (V , E) is a directed walk in 𝒢 such that (i) the first and last vertices are equal and (ii) no other vertex is repeated. The graph is called a directed acyclic graph if it contains no cycles. The graph is called periodic if it contains at least one cycle and, moreover, there exists a k > 1 such that the length of every cycle is a multiple of k. The graph is called aperiodic if it is not periodic. Example 1.4.5: In Figure 1.13, the cycles are (a,b,a), (b,a,b), (b,c,b), (c,b,c), (c,d,c) and (d,c,d). Hence the length of every cycle is 2 and the graph is periodic. Exercise 1.4.2. Prove the following: If 𝒢 is a directed acyclic graph, then, for any node u in 𝒢, there exists a node v such that u → v and od (v) = 0. An obvious sufficient condition for aperiodicity is existence of even one self-loop. The digraphs in Figures 1.9–1.12 are aperiodic for this reason. The next result provides an easy way to understand aperiodicity for connected graphs. Proofs can be found in Norris (1998) and Häggström et al. (2002).
a
b
c
Figure 1.13 A periodic digraph
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
d
29
1.4 Graph Theory
lemma 1.4.1 Let 𝒢 = (V , E) be a digraph. If 𝒢 is strongly connected, then 𝒢 is aperiodic if and only if, for all v ∈ V , there exists a q ∈ N such that, for all k > q, there exists a directed walk of length k from v to v. It is common to call a vertex v satisfying the condition in Lemma 1.4.1 aperiodic. With this terminology, Lemma 1.4.1 states that a strongly connected digraph is aperiodic if and only if every vertex is aperiodic. NetworkX can be used to check for aperiodicity of vertices or graphs. For example, if G is a DiGraph object, then nx.is_aperiodic(G) returns True or False depending on the aperiodicity of G.
1.4.1.5
Adjacency Matrices There is a simple map between edges of a graph with fixed vertices and a binary matrix called an adjacency matrix. The benefit of viewing connections through adjacency matrices is that they bring the power of linear algebra to the analysis of digraphs. We illustrate this briefly here and extensively in §1.4.2. If 𝒢 = (V , E) is a digraph with V = {v1, . . . ,vn }, then the n × n adjacency matrix corresponding to (V , E) is defined by12 A = (ai j )16i, j6n
with ai j = 1{(vi ,v j ) ∈ E}.
(1.21)
For example, with {poor, middle, rich} mapped to (1,2,3), the adjacency matrix corresponding to the digraph in Figure 1.10 is 1 0 0 (1.22) A = 1 1 1 . 1 1 1 An adjacency matrix provides us with enough information to recover the edges of a graph. More generally, given a set of vertices V = {v1, . . . ,vn }, an n × n matrix A = (ai j )16i, j6n with binary entries generates a digraph 𝒢 with vertices V and edges E = {(vi ,v j ) ∈ V × V : ai j = 1}. The adjacency matrix of this graph (V , E) is A. Exercise 1.4.3. A digraph (V , E) is called undirected if (u,v) ∈ E implies (v,u) ∈ E. What property does this imply on the adjacency matrix? remark 1.4.1 The idea that a digraph can be undirected, presented in Exercise 1.4.3, seems contradictory. After all, a digraph is a directed graph. Another way to introduce undirected graphs is to define them as a vertex-edge pair (V , E), where each edge {u,v} ∈ E is an unordered pair, rather than an ordered pair (u,v). However, 12 Note that, in some applied fields, the adjacency matrix is transposed: a = 1 if there is an edge from j ij
to i, rather than from i to j. We will avoid this odd and confusing definition (which contradicts both standard graph theory and standard notational conventions in the study of Markov chains).
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
30
Introduction
the definition in Exercise 1.4.3 is essentially equivalent and more convenient for our purposes, since we mainly study directed graphs. Like NetworkX, the Python library quantecon provides a graph object that supplies certain graph-theoretic algorithms. In the case of QuantEcon’s DiGraph object, algorithms are implemented by interfacing with routines in SciPy, and an instance is created by supplying an adjacency matrix. For example, to construct a digraph corresponding to Figure 1.10, we use the corresponding adjacency matrix (1.22): import quantecon as qe import numpy as np A = ((1, 0, 0), (1, 1, 1,), (1, 1, 1)) A = np.array(A) G = qe.DiGraph(A)
# Convert to NumPy array
Let’s print the set of strongly connected components, as a list of NumPy arrays: G.strongly_connected_components The output is [array([0]), array([1, 2])].
1.4.2
Weighted Digraphs Early quantitative work on networks tended to focus on unweighted digraphs, where the existence or absence of an edge is treated as sufficient information (e.g., following or not following on social media, existence or absence of a road connecting two towns). However, for some networks, this binary measure is less significant than the size or strength of the connection. As one illustration, consider Figure 1.14, which shows flows of funds (i.e., loans) between private banks, grouped by country of origin. An arrow from Japan to the USA, say, indicates aggregate claims held by Japanese banks on all US-registered banks, as collected by the Bank of International Settlements (BIS). The size of each node in the figure is increasing in the total foreign claims of all other nodes on this node. The widths of the arrows are proportional to the foreign claims they represent.13 The country codes are given in Table 1.1. In this network, an edge (u,v) exists for almost every choice of u and v (i.e., almost every country in the network).14 Hence existence of an edge is not particularly informative. To understand the network, we need to record not just the existence or 13 Data for the figure was obtained from the BIS consolidated banking statistics, for Q4 of 2022. Our
calculations used the immediate counterparty basis for financial claims of domestic and foreign banks, which calculates the sum of cross-border claims and local claims of foreign affiliates in both foreign and local currencies. The foreign claim of a node to itself is set to zero. 14 In fact arrows representing foreign claims less than US$10 million are cut from Figure 1.14, so the network is even denser than it appears. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
31
1.4 Graph Theory
Table 1.1 Codes for the 16-country financial network AU PT US BE
Australia Portugal United States Belgium
DE FR IE JP
Germany France Ireland Japan
CL TR AT SW
Chile Turkey Austria Switzerland
CL
IT
ES GB IT SE
Spain United Kingdom Italy Sweden
ES
TR US
FR BE
AU
IE
JP
SE
GB
SW
AT
DE
Figure 1.14 International private credit flows by country
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
PT
32
Introduction
absence of a credit flow, but also the size of the flow. The correct data structure for recording this information is a “weighted directed graph,” or “weighted digraph.” In this section we define this object and investigate its properties.
1.4.2.1
Definitions A weighted digraph 𝒢 is a triple (V , E,w) such that (V , E) is a digraph and w is a function from E to (0,∞), called the weight function. remark 1.4.2 Weights are traditionally regarded as nonnegative. In this text we insist that weights are also positive, in the sense that w(u,v) > 0 for all (u,v) ∈ E. The reason is that the intuitive notion of zero weight is understood, here and below, as absence of a connection. In other words, if (u,v) has “zero weight,” then (u,v) is not in E, so w is not defined on (u,v).
Example 1.4.6: As suggested by the discussion above, the graph shown in Figure 1.14 can be viewed as a weighted digraph. Vertices are countries of origin, and an edge exists between country u and country v when private banks in u lend nonzero quantities to banks in v. The weight assigned to edge (u,v) gives total loans from u to v as measured according to the discussion of Figure 1.14. Example 1.4.7: Figure 1.15 shows a weighted digraph, with arrows representing edges of the induced digraph (compare with the unweighted digraph in Figure 1.9). The numbers next to the edges are the weights. In this case, you can think of the numbers on the arrows as transition probabilities for a household over, say, one year. For example, a rich household has a 10% chance of becoming poor. The definitions of accessibility, communication, periodicity, and connectedness extend to any weighted digraph 𝒢 = (V , E,w) by applying them to (V , E). For example, (V , E,w) is called strongly connected if (V , E) is strongly connected. The weighted digraph in Figure 1.15 is strongly connected. 0.4 middle class 0.1
0.2 0.8
0.9 0.4
0.1
poor
rich 0.1
Figure 1.15 A weighted digraph
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
33
1.4 Graph Theory
1.4.2.2
Adjacency Matrices of Weighted Digraphs In §1.4.1.5 we discussed adjacency matrices of unweighted digraphs. The adjacency matrix of a weighted digraph (V , E,w) with vertices {v1, . . . ,vn } is the matrix ( A = (ai j )16i, j6n
with ai j =
w(vi ,v j )
if (vi ,v j ) ∈ E
0
otherwise.
Clearly, once the vertices in V are enumerated, the weight function and adjacency matrix provide the same information. We often work with the latter, since it facilitates computations. Example 1.4.8: With {poor, middle, rich} mapped to (1,2,3), the adjacency matrix corresponding to the weighted digraph in Figure 1.15 is 0.9 A = 0.4 0.1
0.1 0.4 0.1
0 0.2 . 0.8
(1.23)
In QuantEcon’s DiGraph implementation, weights are recorded via the keyword weighted: A = ((0.9, 0.1, 0.0), (0.4, 0.4, 0.2), (0.1, 0.1, 0.8)) A = np.array(A) G = qe.DiGraph(A, weighted=True)
# Store weights
remark 1.4.3 Every unweighted digraph can be regarded as a weighted digraph by introducing a weight function that assigns unit weight to each edge. The resulting adjacency matrix is binary and agrees with our original definition for unweighted digraphs in (1.21). In this sense, the set of unweighted digraphs is a subset of the set of all weighted digraphs. One of the key points to remember about adjacency matrices is that taking the transpose “reverses all the arrows” in the associated digraph. Example 1.4.9: The digraph in Figure 1.16 can be interpreted as a stylized version of a financial network, with vertices as banks and edges showing flow of funds, similar to Figure 1.14 on page 31. For example, we see that bank 2 extends a loan of size 200 to bank 3. The corresponding adjacency matrix is
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
34
Introduction
50
2
1
100
200
150
500 250
5 50
3 4
300
100 Figure 1.16 A network of credit flows across institutions
0 100 50 0 A= 0 0 0 500 150 0
0 0 0 200 0 0 0 100 0 . 0 0 50 250 300 0
(1.24)
The transposition is
0 100 A> = 0 0 0
50 0 0 0 0 500 200 0 0 0 100 0 0 0 50
150 0 250 . 300 0
(1.25)
The corresponding network is visualized in Figure 1.17. This figure shows the network of liabilities after the loans have been granted. Both of these networks (original and transpose) are useful for the analysis of financial markets (see, e.g., Chapter 5). It is not difficult to see that each nonnegative n × n matrix A = (ai j ) can be viewed as the adjacency matrix of a weighted digraph with vertices equal to [n]. The weighted digraph 𝒢 = (V , E,w) in question is formed by setting V = [n],
E = {(i, j) ∈ V × V : ai j > 0} and w(i, j) = ai j for all (i, j) ∈ E.
We call 𝒢 the weighted digraph induced by A. The next exercise helps to reinforce the point that transposes reverse the edges. Exercise 1.4.4. Let A = (ai j ) be a nonnegative n×n matrix, and let 𝒢 = ([n], E,w) and 𝒢0 = ([n], E 0,w0 ) be the weighted digraphs induced by A and A> , respectively. Show that
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
50
2
1
100
200
35
150
500 250
5 50
3 4
300
100 Figure 1.17 The transpose: a network of liabilities
(i) ( j,k) ∈ E 0 if and only if (k, j) ∈ E. (ii) j → k in 𝒢0 if and only if k → j in 𝒢.
1.4.2.3
Application: Quadratic Network Games Acemoglu et al. (2016) and Zenou (2016) consider quadratic games with n agents where agent k seeks to maximize 1 u k (x) := − xk2 + αx > Ax + xk εk . 2
(1.26)
n , A is a symmetric matrix with a = 0 for all i, α ∈ (0,1) is a Here x = (xi )i=1 ii n parameter, and ε = (εi )i=1 is a random vector. (This is the set up for the quadratic game in §21.2.1 of Acemoglu et al. (2016).) The k-th agent takes the decisions x j as given for all j 6= k when maximizing (1.26). In this context, A is understood as the adjacency matrix of a graph with vertices V = [n], where each vertex is one agent. We can reconstruct the weighted digraph (V , E,w) by setting w(i, j) = ai j and letting E be all (i, j) pairs in [n] × [n] with ai j > 0. The weights identify some form of relationship between the agents, such as influence or friendship.
Exercise 1.4.5. A Nash equilibrium for the quadratic network game is a vector ∈ Rn such that, for all i ∈ [n], the choice xi∗ of agent i maximizes (1.26) taking x ∗j as given for all j 6= i. Show that, whenever r (A) < 1/α, a unique Nash equilibrium x ∗ exists in Rn and, moreover, x ∗ := (I − α A)−1 ε. x∗
The network game described in this section has many interesting applications, including social networks, crime networks and peer networks. References are provided in §1.5.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
36
Introduction
1.4.2.4
Properties In this section, we examine some of the fundamental properties of and relationships among digraphs, weight functions, and adjacency matrices. Throughout this section, without loss of generality, we consider a weighted digraph with V = [n]. As an additional convention, if A is an adjacency matrix, and Ak is the k-th power of A, then we write aikj for a typical element of Ak . With this notation, we observe that, since A(s+t) = As At , the rules of matrix multiplication imply ais+t j =
n X `=1
s t ai` a`j
(i, j ∈ [n], s,t ∈ N).
(1.27)
(A0 is the identity.) The next proposition explains the significance of the powers. proposition 1.4.2 Let 𝒢 be a weighted digraph with adjacency matrix A. For distinct vertices i, j ∈ [n] and k ∈ N, we have aikj > 0 ⇐⇒
there exists a directed walk of length k from i to j.
Proof (⇐ ) The statement is true by definition when k = 1. Suppose in addition that ⇐ holds at k − 1, and suppose there exists a directed walk (i,`,m, . . . ,n, j) of length k−1 k from i to j. By the induction hypothesis we have ain > 0. Moreover, (n, j) is part of a directed walk, so an j > 0. Applying (1.27) now gives aikj > 0. (⇒) Left as an exercise (just use the same logic).
Example 1.4.10: In §4.1 we show that if elements of A represent one-step transition probabilities across states, then elements of At , the t-th power of A, provide t-step transition probabilities. In Markov process theory, (1.27) is called the Chapman–Kolmogorov equation. In this context, the next result is fundamental. theorem 1.4.3 Let 𝒢 be a weighted digraph. The following statements are equivalent: (i) 𝒢 is strongly connected. (ii) The adjacency matrix generated by 𝒢 is irreducible. Proof Let 𝒢 be a weighted digraph with adjacency matrix A. By Proposition 1.4.2, strong connectedness of 𝒢 is equivalent to the statement that, for each i, j ∈ V , we can find a k > 0 such that aikj > 0. (If i = j then set k = 0.) This, in turn, is equivalent to P∞ m m=0 A 0, which is irreducibility of A. Example 1.4.11: Strong connectivity fails in the digraph in Figure 1.18, since vertex 4 is a source. By Theorem 1.4.3, the adjacency matrix must be reducible.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
37
a11 1 a21 a31
a12 2
4 a43 a23 3
Figure 1.18 Failure of strong connectivity
We will find that the property of being primitive is valuable for analysis. (The Perron–Frobenius theorem hints at this.) What do we need to add to strong connectedness to obtain primitiveness? theorem 1.4.4 For a weighted digraph 𝒢 = (V , E,w), the following statements are equivalent: (i) 𝒢 is strongly connected and aperiodic. (ii) The adjacency matrix generated by 𝒢 is primitive. Proof of Theorem 1.4.4 First we show that, if 𝒢 is aperiodic and strongly connected, then, for all i, j ∈ V , there exists a q ∈ N such that aikj > 0 whenever k > q. To this end, pick any i, j in V . Since 𝒢 is strongly connected, there exists an s ∈ N such that aisj > 0. Since 𝒢 is aperiodic, we can find an m ∈ N such that ` > m implies a `j j > 0. Picking ` > m and applying (1.27), we have ais+` j =
X
s ` air ar j > aisj a `j j > 0.
r ∈V
Thus, with t = s + m, we have aikj > 0 whenever k > t. ((i) ⇒ (ii)). By the preceding argument, given any i, j ∈ V , there exists an s(i, j) ∈ N such that aimj > 0 whenever m > s(i, j). Setting k := max s(i, j) over all (i, j) yields Ak 0. ((ii) ⇒ (i)). Suppose that A is primitive. Then, for some k ∈ N, we have Ak 0. Strong connectedness of the digraph follows directly from Proposition 1.4.2. It remains to check aperiodicity.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
38
Introduction
k+1 Aperiodicity will hold if we can establish that a11 > 0, since then we have a cycle of length k and another of length k + 1. To show that this holds, we use (1.27) to write X X k+1 k ai`, a1` a`1 > a¯ a11 = `∈V
`∈V
k > 0. The proof will be done if P where a¯ := min`∈V a`1 `∈V a1` > 0. But this must be true, since otherwise vertex 1 is a sink, which contradicts strong connectedness.
Example 1.4.12: In Exercise 1.2.20 we worked hard to show that Pw is irreducible if and only if 0 < α,β 6 1, using the approach of calculating and then examining the powers of Pw (as shown in (1.3)). However, the result is trivial when we examine the corresponding digraph in Figure 1.3 and use the fact that irreducibility is equivalent to strong connectivity. Similarly, the result in Exercise 1.2.20 that Pw is primitive if and only if 0 < α,β 6 1 and min{α,β} < 1 becomes much easier to establish if we examine the digraph and use Theorem 1.4.4.
1.4.3
Network Centrality When studying networks of all varieties, a recurring topic is the relative “centrality” or “importance” of different nodes. One classic application is the ranking of web pages by search engines. Here are some examples related to economics: • In which industry will one dollar of additional demand have the most impact on aggregate production, once we take into account all the backward linkages? In which sector will a rise in productivity have the largest effect on national output? • A negative shock endangers the solvency of the entire banking sector. Which institutions should the government rescue, if any? • In the network games considered in §1.4.2.3, the Nash equilibrium is x ∗ = (I − α A)−1 ε. Players’ actions are dependent on the topology of the network, as encoded in A. A common finding is that the level of activity or effort exerted by an agent (e.g., severity of criminal activity by a participant in a criminal network) can be predicted from their “centrality” within the network. In this section we review essential concepts related to network centrality.15
1.4.3.1
Centrality Measures Let G be the set of weighted digraphs. A centrality measure associates to each 𝒢 = (V , E,w) in G a vector m(𝒢) ∈ R|V | , where the i-th element of m(𝒢) is interpreted as the centrality (or rank) of vertex vi . In most cases m(𝒢) is nonnegative. In what follows, to simplify notation, we take V = [n]. 15 Centrality measures are sometimes called “influence measures,” particularly in connection with social
networks.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
hub
39
authority
Figure 1.19 Hub vs. authority
(Unfortunately, the definitions and terminology associated with even the most common centrality measures vary widely across the applied literature. Our convention is to follow the mathematicians, rather than the physicists. For example, our terminology is consistent with Benzi and Klymko (2015).)
1.4.3.2
Authorities vs. Hubs Search engine designers recognize that web pages can be important in two different ways. Some pages have high hub centrality, meaning that they link to valuable sources of information (e.g., news aggregation sites). Other pages have high authority centrality, meaning that they contain valuable information, as indicated by the number and significance of incoming links (e.g., websites of respected news organizations). Figure 1.19 helps to visualize the difference. Similar ideas can be and have been applied to economic networks (often using different terminology). For example, in the production networks we study below, high hub centrality is related to upstreamness: Such sectors tend to supply intermediate goods to many important industries. Conversely, a high authority ranking will coincide with downstreamness. In what follows we discuss both hub-based and authority-based centrality measures, providing definitions and illustrating the relationship between them.
1.4.3.3
Degree Centrality Two of the most elementary measures of “importance” of a vertex in a given digraph 𝒢 = (V , E) are its in-degree and out-degree. Both of these provide a centrality measure. In-degree centrality i(𝒢) is defined as the vector (i d (v))v∈V . Out-degree centrality o(𝒢) is defined as (od (v))v∈V . If 𝒢 is expressed as a NetworkX DiGraph called G (see, e.g., §1.4.1.2), then i(𝒢) can be calculated via iG = [G.in_degree(v) for v in G.nodes()] This method is relatively slow when 𝒢 is a large digraph. Since vectorized operations are generally faster, let’s look at an alternative method using operations on arrays.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
40
Introduction
To illustrate the method, recall the network of financial institutions in Figure 1.16. We can compute the in-degree and out-degree centrality measures by first converting the adjacency matrix, which is shown in (1.24), to a binary matrix that corresponds to the adjacency matrix of the same network viewed as an unweighted graph: 0 1 0 0 0 1 0 1 0 0 (1.28) U = 0 0 0 1 0 . 0 1 0 0 1 1 0 1 1 0 Now U (i, j) = 1 if and only if i points to j. The out-degree and in-degree centrality measures can be computed as o(𝒢) = U 1 and i(𝒢) = U > 1,
(1.29)
respectively. That is, summing the rows of U gives the out-degree centrality measure, while summing the columns gives the in-degree measure. The out-degree centrality measure is a hub-based ranking, while the vector of indegrees is an authority-based ranking. For the financial network in Figure 1.16, a high out-degree for a given institution means that it lends to many other institutions; a high in-degree indicates that many institutions lend to it. Notice that, to switch from a hub-based ranking to an authority-based ranking, we need only transpose the (binary) adjacency matrix U . We will see that the same is true for other centrality measures. This is intuitive, since transposing the adjacency matrices reverses the directions of the edges (Exercise 1.4.4). For a weighted digraph 𝒢 = (V , E,w) with adjacency matrix A, the weighted outdegree centrality and weighted in-degree centrality measures are defined as o(𝒢) = A1 and i(𝒢) = A> 1,
(1.30)
respectively, by analogy with (1.29). We present some intuition for these measures in applications below. Unfortunately, while in- and out-degree measures of centrality are simple to calculate, they are not always informative. As an example, consider again the international credit network shown in Figure 1.14. There, an edge exists between almost every node, so the in- or out-degree-based centrality ranking fails to effectively separate the countries. This can be seen in the out-degree ranking of countries corresponding to that network in the top left panel of Figure 1.20 and in the in-degree ranking in the top right. There are other limitations of degree-based centrality rankings. For example, suppose web page A has many inbound links, while page B has fewer. Even though page A dominates in terms of in-degree, it might be less important than web page B to, say, a potential advertiser, when the links into B are from more heavily trafficked pages. Thinking about this point suggests that importance can be recursive: The importance of a given node depends on the importance of other nodes that link to it. The next set of centrality measures we turn to has this recursive property. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
20.0
41
20.0
out degree
17.5
17.5
15.0
15.0
12.5
12.5
10.0
10.0
7.5
7.5
5.0
5.0
2.5
2.5
in degree
0.0
0.0 CL AUPTTR US AT BESWDE ES FR GB IE IT JP SE
eigenvector hub
0.200
TRAU CL PT US AT BESWDE ES FR GB IE IT JP SE
0.30
eigenvector authority
0.25
0.175 0.150
0.20
0.125 0.15
0.100 0.075
0.10
0.050 0.05
0.025 0.000
0.00 TR CL PT AT IE BE SE AU IT SWDE ES FR US GB JP
Katz hub
PT CL TR AT SE ESSWBE IE AU IT FR JP DEGB US
60
Katz authority
40 50 30
40 30
20
20 10 10 0
0 TR CL PT AT IE BE SE AU IT SWDE ES FR US GB JP
CL PTTR AT SE ESSWBE IE AU IT FR JP DEGB US
Figure 1.20 Centrality measures for the credit network
1.4.3.4
Eigenvector Centrality Let 𝒢 = (V , E,w) be a weighted digraph with adjacency matrix A. Recalling that r (A) is the spectral radius of A, the hub-based eigenvector centrality of 𝒢 is defined as the e ∈ Rn+ that solves 1 e= Ae. (1.31) r (A)
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
42
Introduction
Element-by-element, this is ei =
1 X ai j e j r (A)
for all i ∈ [n].
(1.32)
j∈[n]
Note the recursive nature of the definition: The centrality obtained by vertex i is proportional to a sum of the centralities of all vertices, weighted by the “rates of flow” from i into these vertices. A vertex i is highly ranked if (a) there are many edges leaving i, (b) these edges have large weights, and (c) the edges point to other highly ranked vertices. When we study demand shocks in §2.1.3, we will provide a more concrete interpretation of eigenvector centrality. We will see that, in production networks, sectors with high hub-based eigenvector centrality are important suppliers. In particular, they are activated by a wide array of demand shocks once orders flow backwards through the network. Exercise 1.4.6. Show that (1.32) has a unique solution, up to a positive scalar multiple, whenever A is strongly connected.16 As the name suggests, hub-based eigenvector centrality is a measure of hub centrality: Vertices are awarded high rankings when they point to important vertices. The next two exercises help to reinforce this point. Exercise 1.4.7. Show that nodes with zero out-degree always have zero hub-based eigenvector centrality. To compute eigenvector centrality when the adjacency matrix A is primitive, we can employ the Perron–Frobenius theorem, which tells us that r (A)−m Am → e ε> as m → ∞, where ε and e are the dominant left and right eigenvectors of A. This implies r (A)−m Am 1 → ce,
where c := ε> 1.
(1.33)
Thus, evaluating r (A)−m Am 1 at large m returns a scalar multiple of e. The package NetworkX provides a function for computing eigenvector centrality via (1.33). One issue with this method is the assumption of primitivity, since the convergence in (1.33) can fail without it. The following function uses an alternative technique, based on Arnoldi iteration, which typically works even when primitivity fails. (The authority option is explained below.) import numpy as np from scipy.sparse import linalg def eigenvector_centrality(A, m=40, authority=False): """ Computes and normalizes the dominant eigenvector of A. """ 16 While the dominant eigenvector is only defined up to a positive scaling constant, this is no reason for
concern, since positive scaling has no impact on the ranking. In most cases, users of this centrality ranking choose the dominant eigenvector e satisfying kek = 1. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
1.4 Graph Theory
1
1
43
1 2
3
2 1 1 2
4 Figure 1.21 A network with a source and a sink
A_temp = A.T if authority else A r, vec_r = linalg.eigs(A_temp, k=1, which=’LR’) e = vec_r.flatten().real return e / np.sum(e) Exercise 1.4.8. Show that the digraph in Figure 1.21 is not primitive. Using the code above or another suitable routine, compute the hub-based eigenvector centrality rankings. You should obtain values close to e = (0.3694,0.2612,0.3694,0). Note that the sink vertex (vertex 4) obtains the lowest rank. The middle left panel of Figure 1.20 shows the hub-based eigenvector centrality ranking for the international credit network shown in Figure 1.14. Countries that are rated highly according to this rank tend to be important players in terms of supply of credit. Japan takes the highest rank according to this measure, although countries with large financial sectors, such as Great Britain and France, are not far behind. (The color scheme in Figure 1.14 is also matched to hub-based eigenvector centrality.) The authority-based eigenvector centrality of 𝒢 is defined as the e ∈ Rn+ solving 1 e= A> e. (1.34) r (A) The difference between (1.34) and (1.32) is just transposition of A. (Transposes do not affect the spectral radius of a matrix.) Element-by-element, this is 1 X ej = ai j ei for all j ∈ [n]. (1.35) r (A) i∈[n]
We see e j will be high if many nodes with high authority rankings link to j. The middle right panel of Figure 1.20 shows the authority-based eigenvector centrality ranking for the international credit network shown in Figure 1.14. Highly ranked countries are those that attract large inflows of credit, or credit inflows from other major players. The USA clearly dominates the rankings as a target of inter-bank credit. Exercise 1.4.9. Assume that A is strongly connected. Show that authority-based eigenvector centrality is uniquely defined up to a positive scaling constant and equal to the dominant left eigenvector of A. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
44
Introduction
1.4.3.5
Katz Centrality Eigenvector centrality can be problematic. Although the definition in (1.32) makes sense when A is strongly connected (so that, by the Perron–Frobenius theorem, r (A) > 0), strong connectedness fails in many real world networks. We will see examples of this in §2.1, for production networks defined by input–output matrices. In addition, while strong connectedness yields strict positivity of the dominant eigenvector, many vertices can be assigned a zero ranking when it fails (see, e.g., Exercise 1.4.7). This zero ranking often runs counter to our intuition when we examine specific networks. Considerations such as these encourage the use of an alternative notion of centrality for networks called Katz centrality, originally due to Katz (1953), which is positive under weaker conditions and uniquely defined up to a tuning parameter. Fixing β in (0,1/r (A)), the hub-based Katz centrality of weighted digraph 𝒢 with adjacency matrix A, at parameter β, is defined as the vector κ := κ(β, A) ∈ Rn+ that solves X κi = β ai j κ j + 1 for all i ∈ [n]. (1.36) j∈[n]
The intuition is very similar to that provided for eigenvector centrality: High centrality is conferred on i when it is linked to by vertices that themselves have high centrality. The difference between (1.36) and (1.32) is just in the additive constant 1. Exercise 1.4.10. Show that, under the stated condition 0 < β < 1/r (A), hub-based Katz centrality is always finite and uniquely defined by X κ = (I − β A)−1 1 = (β A)` 1, (1.37) `>0
where 1 is a column vector of ones. Exercise 1.4.11. We know from the Perron–Frobenius theorem that the eigenvector centrality measure will be everywhere positive when the digraph is strongly connected. A condition weaker than strong connectivity is that every vertex has positive outdegree. Show that the Katz measure of centrality is strictly positive on each vertex under this condition. The attenuation parameter β is used to ensure that κ is finite and uniquely defined under the condition 0 < β < 1/r (A). It can be proved that, when the graph is strongly connected, hub-based (resp., authority-based) Katz centrality converges to the hubbased (resp., authority-based) eigenvector centrality as β ↑ 1/r (A).17 This is why, in the bottom two panels of Figure 1.20, the hub-based (resp., authority-based) Katz centrality ranking is seen to be close to its eigenvector-based counterpart. When r (A) < 1, we use β = 1 as the default for Katz centrality computations. Exercise 1.4.12. Compute the hub-based Katz centrality rankings for the simple digraph in Figure 1.21 when β = 1. You should obtain κ = (5,4,5,1). Hence, the 17 See, for example, Benzi and Klymko (2015).
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
45
1.4 Graph Theory
source vertex (vertex 1) obtains equal highest rank, and the sink vertex (vertex 4) obtains the lowest rank. Analogously, the authority-based Katz centrality of 𝒢 is defined as the κ ∈ Rn+ that solves X κj = β ai j κi + 1 for all j ∈ [n]. (1.38) i∈[n]
Exercise 1.4.13. Show that, under the restriction 0 < β < 1/r (A), the unique solution to (1.38) is given by κ = (I − β A> )−1 1
⇐⇒
κ> = 1> (I − β A)−1 .
(1.39)
(Verify the stated equivalence.) Exercise 1.4.14. Compute the authority-based Katz centrality rankings for the digraph in Figure 1.21 when β = 1. You should obtain κ = (1,6,4,4). Notice that the source vertex now has the lowest rank. This is due to the fact that hubs are devalued relative to authorities.
1.4.4
Scale-Free Networks What kinds of properties do large, complex networks typically possess? One of the most striking facts about complex networks is that many exhibit the scale-free property, which means, loosely speaking, that the number of connections possessed by each vertex in the network follows a power law. The scale-free property is remarkable because it holds for a wide variety of networks, from social networks to citation, sales, financial, and production networks, each of which is generated by different underlying mechanisms. Nonetheless, they share this specific statistical structure. We begin this section by defining the degree distribution and then discuss its properties, including possible power law behavior.
1.4.4.1
Empirical Degree Distributions Let 𝒢 = (V , E) be a digraph. Assuming without loss of generality that V = [n] for some n ∈ N, the in-degree distribution of G is the sequence (ϕin (k))nk=0 defined by P 1{i d (v) = k} ϕin (k) = v∈V (k = 0, . . . ,n), (1.40) n where i d (v) is the in-degree of vertex v. In other words, the in-degree distribution evaluated at k is the fraction of nodes in the network that have in-degree k. In Python, when 𝒢 is expressed as a NetworkX DiGraph called G and import numpy as np has been executed, the in-degree distribution can be calculated via def in_degree_dist(G): n = G.number_of_nodes() iG = np.array([G.in_degree(v) for v in G.nodes()])
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
46
Introduction
phi = [np.mean(iG == k) for k in range(n+1)] return phi The out-degree distribution is defined analogously, replacing i d with od in (1.40), and denoted by (ϕout (k))nk=0 . Recall that a digraph 𝒢 = (V , E) is called undirected if (u,v) ∈ E implies (v,u) ∈ E. If 𝒢 is undirected, then i d (v) = od (v) for all v ∈ V . In this case we usually write ϕ instead of ϕin or ϕout and refer simply to the degree-distribution of the digraph. A scale-free network is a network whose degree distribution obeys a power law, in the sense that there exist positive constants c and γ with ϕ(k) ≈ ck −γ
for large k.
(1.41)
Here ϕ(k) can refer to the in-degree or the out-degree (or both), depending on our interest. In view of the discussion in §1.3.2.4, this can be identified with the idea that the degree distribution is Pareto-tailed with tail index α = γ − 1. Although we omit formal tests, the degree distribution for the commercial aircraft international trade network shown in Figure 1.2 on page 3 is approximately scale-free. Figure 1.22 illustrates this by plotting the degree distribution alongside f (x) = cx −γ with c = 0.2 and γ = 1.1. (In this calculation of the degree distribution, performed by the NetworkX function degree_histogram, directions are ignored and the network is treated as an undirected graph.) Attention was drawn to the scale-free nature of many networks by Barabási and Albert (1999). They found, for example, that the in-degree and out-degree distributions for internet pages connected by hyperlinks both follow power laws. In subsequent years, many networks have been found to have the scale-free property, up to a first 0.25
degree distribution power law 0.20
0.15
0.10
0.05
0.00 2.5
5.0
7.5
10.0
12.5
15.0
17.5
Figure 1.22 Degree distribution for international aircraft trade
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
20.0
1.4 Graph Theory
47
approximation, including networks of followers on Twitter (Pearce, 2017; Punel and Ermagun, 2018), other social networks (Rybski et al., 2009), and academic collaboration networks (e.g., papers plus citations). Within economics and finance, Carvalho (2014) shows that the weighted out-degree distribution for US input–output data (discussed further in Chapter 2) obeys a power law, as does the Katz centrality measure. Carvalho et al. (2021) document power law tails for the in-degree (suppliers) and out-degree (customers) distributions in a Japanese network of interacting firms. Scale-free degree distributions have also been observed in a number of financial and inter-bank credit networks (Kim et al., 2007; Ou et al., 2007; De Masi et al., 2011). In many cases, the scale-free property of a given network has significant implications for economic outcomes and welfare. For example, a power law in input–output networks often typically indicates dominance by a small number of very large sectors or firms. This in turn affects both the dynamism of the industry and the likelihood of aggregate instability caused by firm-level shocks. We explore some of these issues in Chapter 2.
1.4.4.2
Random Graphs One way to explore the implications of different dynamics for the degree distribution of graphs is to specify a law for generating graphs randomly and then examine the degree distribution that results. This methodology leads to insights on the kinds of mechanisms that can generate scale-free networks. We begin with one of the most popular and elementary ways of randomly generating an undirected graph, originally examined by Erdös and Rényi (1960). The process to generate a graph 𝒢 = (V , E) is (i) (ii) (iii) (iv)
fix an integer n ∈ N and a p ∈ (0,1); view V := [n] as a collection of vertices; let E = {∅}; and for each (i, j) ∈ V × V with i 6= j, add the undirected edge {i, j} to the set of edges E with probability p.
In the last step additions are independent – each time, we flip an unbiased iid coin with head probability p and add the edge if the coin comes up heads. The Python code below provides a function that can be called to randomly generate an undirected graph using this procedure. It applies the combinations function from the itertools library, which, for the call combinations(A, k), returns a list of all subsets of A of size k. For example, import itertools letters = ’a’, ’b’, ’c’ list(itertools.combinations(letters, 2)) returns [(’a’, ’b’), (’a’, ’c’), (’b’, ’c’)]. We use combinations to produce the set of all possible edges and then add them to the graph with probability p: https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
48
Introduction
Graph visualization
Degree distribution 0:20
0:15
0:10
0:05
0:00 0
2
4
6
8
Figure 1.23 An instance of an Erdos–Renyi random graph
def erdos_renyi_graph(n=100, p=0.5, seed=1234): "Returns an Erdos-Renyi random graph." np.random.seed(seed) edges = itertools.combinations(range(n), 2) G = nx.Graph() for e in edges: if np.random.rand() < p: G.add_edge(*e) return G (The code presented here is a simplified version of functionality provided by the library NetworkX. It is written for clarity rather than efficiency. More efficient versions can be found both in NetworkX and in Julia’s Graphs.jl library.) The left-hand side of Figure 1.23 shows one instance of a graph that was generated by the erdos_renyi_graph function, with n = 100 and p = 0.05. Lighter colors on a node indicate higher degree (more connections). The right-hand side shows the degree distribution, which exhibits a bell-shaped curve typical for Erdos–Renyi random graphs. In fact one can show (see, e.g., Bollobás (1999) or Durrett (2007)) that the degree distribution is binomial, with n−1 k ϕ(k) = p (1 − p)n−1−k (k = 0, . . . ,n − 1). k
1.4.4.3
Preferential Attachment Clearly Erdos–Renyi random graphs fail to replicate the heavy right-hand tail of the degree distribution observed in many networks. In response to this, Barabási and Albert (1999) proposed a mechanism for randomly generating graphs that feature the scale-free property.
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
49
1.5 Chapter Notes
Graph visualization
Degree distribution 0:30 0:25 0:20 0:15 0:10 0:05 0:00 0
5
10
15
Figure 1.24 An instance of a preferential attachment random graph
The stochastic mechanism they proposed is called preferential attachment. In essence, each time a new vertex is added to an undirected graph, it is attached by edges to m of the existing vertices, where the probability of vertex v being selected is proportional to the degree of v. Barabási and Albert (1999) showed that the resulting degree distribution exhibits a Pareto tail in the limit as the number of vertices converges to +∞. A careful proof can be found in Chapter 4 of Durrett (2007). Although we omit details of the proof, we can see the power law emerge in simulations. For example, Figure 1.24 shows a random graph with 100 nodes generated by NetworkX’s barabasi_albert_graph function. The number of attachments m is set to 5. The simulated degree distribution on the right-hand side of Figure 1.24 already exhibits a long right tail. The preferential attachment model is popular not just because it replicates the scalefree property of many real-world networks but also because its mechanism is simple and plausible. For example, in citation networks, we can imagine that a well-cited paper is more likely to attract additional citations than a poorly cited paper. Similar intuition can be applied to an individual on a social network, where the number of links is measured in terms of the number of followers.
1.5
Chapter Notes The Perron–Frobenius theorem is due to Oskar Perron (1880–1975) and Ferdinand Georg Frobenius (1849–1917). The main results were proved by 1912. As early as 1915, Dénes König (1884–1944) saw the connection between the Perron–Frobenius theorem and graph theory, and provided an alternative proof using bipartite graphs. Some of the history is discussed in Schrijver (2005). We have already mentioned the textbooks on economic and social networks by Jackson (2010), Easley et al. (2010), Borgatti et al. (2018), and Goyal (2023), as well as the handbook by Bramoullé et al. (2016). Jackson (2014) gives a survey of the
https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
50
Introduction
literature. Within the realm of network science, the high level texts by Newman (2018), Menczer et al. (2020), and Coscia (2021) are excellent. One good text on graphs and graph-theoretic algorithms is Kepner and Gilbert (2011). Ballester et al. (2006) provide an interpretation of Katz centrality (which they call Bonacich centrality) in terms of Nash equilibria of quadratic games. Sharkey (2017) presents a new interpretation of Katz centrality using control theory. Polovnikov et al. (2022) use Katz centrality to uncover hidden ultimate owners in firm ownership data. Du et al. (2015) show how PageRank can be obtained as a competitive equilibrium of an economic problem. Calvó-Armengol et al. (2009) develop a model in which the outcomes for agents embedded in a network are proportional to the Katz centrality. Elliott and Golub (2019) show that, in a setting where agents can create nonrival, heterogeneous public goods, an important set of efficient solutions are characterized by contributions being proportional to agents’ eigenvector centralities in the network. Kumamoto and Kamihigashi (2018) provide a detailed survey of power laws in economics and the social sciences, including a discussion of the preferential attachment model of Barabási and Albert (1999). Newman (2005) is also highly readable. The textbook of Durrett (2007) is rigorous, carefully written, and contains interesting motivational background, as well as an extensive citation list for studies of scale-free networks. It should be clear from the symbol ≈ in (1.41) that the definition of scale-free networks is not entirely rigorous. Moreover, when connecting the definition to observed networks, we cannot obtain complete clarity by taking a limit, as we did when we defined power laws in §1.3.2, since the number of vertices is always finite. This imprecision in the definition has led to heated debate (see, e.g., Holme (2019)). Given the preponderance of positive empirical studies, we take the view that, up to a reasonable degree of approximation, the scale-free property is remarkably widespread. In §1.4.2.3 we briefly mentioned network games, social networks, and key players. These topics deserve more attention than we are able to provide. An excellent overview is given in Zenou (2016). Amarasinghe et al. (2020) apply these ideas to problems in economic development. Valuable related papers include Allouch (2015), Belhaj et al. (2016), Demange (2017), Belhaj and Deroïan (2019), and Galeotti et al. (2020). Another topic we reluctantly omit in order to keep the textbook short is endogenous network formation in economic environments. Influential papers in this field include Jackson and Wolinsky (1996), Bala and Goyal (2000), Watts (2001), Hojman and Szeidl (2008), Galeotti and Goyal (2010), and Graham (2017). Finally, Candogan et al. (2012) study the profit maximization problem for a monopolist who sells items to participants in a social network. The main idea is that, in certain settings, the monopolist will find it profitable to offer discounts to key players in the network. Atalay et al. (2011) argue that in-degrees observed in US buyer– supplier networks have lighter tails than a power law and supply a model that better fits their data. https://doi.org/10.1017/9781009456340.003 Published online by Cambridge University Press
2
Production
In this chapter we study production in multisector environments. The basic framework is input–output analysis, which was initiated by Wassily Leontief (1905–1999) and popularized in Leontief (1941). Input–output analysis is routinely used to organize national accounts and study inter-industry relationships. In 1973, Leontief received the Nobel Prize in Economic Sciences for his work on input–output systems. Input–output analysis is currently being incorporated into modern theories of trade, growth, shock propagation, and aggregate fluctuations in multisector models (§2.4 provides a detailed list of references). One of the reasons for the renewed interest is that the introduction of concepts from network analysis and graph theory has yielded new insights. This chapter provides an introduction to the main ideas.
2.1
Multisector Models In this section we introduce the basic input–output model, explain the network interpretation of the model, and connect traditional questions, such as the relative impact of demand shocks across sectors, to network topology and network centrality.
2.1.1
Production Networks We begin with the foundational concepts of input–output tables and how they relate to production networks. To simplify the exposition, we ignore imports and exports in what follows. (References for the general case are discussed in §2.4.)
2.1.1.1
Input–Output Analysis Agencies tasked with gathering national and regional production accounts (such as the US Bureau of Economic Analysis) compile input–output data based on the structure set out by Leontief (1941). Firms are divided across n sectors, each of which produces a single homogeneous good. These sectors are organized into an input–output table, a highly simplified example of which is
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
52
Production
sector 1 sector 2 sector 3
sector 1 a11 a21 a31
sector 2 a12 a22 a32
sector 3 a13 a23 a33
Entries ai j are called the input–output coefficients; ai j =
value of sector j’s inputs purchased from sector i . total sales of sector j
Thus, ai j is large if sector i is an important supplier of intermediate goods to sector j. The sum of the j-th column of the table gives the value of all inputs to sector j. The i-th row shows how intensively each sector uses good i as an intermediate good. The production coefficient matrix A = (ai j ) induces a weighted digraph 𝒢 = (V , E,w), where V = [n] is the list of sectors and E := {(i, j) ∈ V × V : ai j > 0} is the edge set. The values ai j show backward linkages across sectors. Given i ∈ V , the set 𝒪(i) of direct successors of i is all sectors to which i supplies a positive quantity of output. The set ℐ(i) is all sectors that supply a positive quantity to i. Figure 2.1 illustrates the weighted digraph associated with the 15-sector version of the input–output tables provided by the Bureau of Economic Analysis for the year 2021.1 An arrow from i to j indicates a positive weight ai j . Weights are indicated by the widths of the arrows, which are proportional to the corresponding input–output coefficients. The sector codes are provided in Table 2.1. The sizes of vertices are proportional to their share of total sales across all sectors. A quick look at Figure 2.1 shows that manufacturing (ma) is an important supplier for many sectors, including construction (co) and agriculture (ag). Similarly, the financial sector (fi) and professional services (pr) supply services to a broad range of sectors. On the other hand, education (ed) is relatively downstream and only a minor supplier of intermediate goods to other sectors. The color scheme for the nodes is by hub-based eigenvector centrality, with hotter colors indicating higher centrality. Later, in §2.1.3, we will give an interpretation of hub-based eigenvector centrality for this setting that connects to the relative impact of demand shocks.
2.1.1.2
Connectedness We will gain insights into input–output networks by applying some of the graphtheoretic notions studied in Chapter 1.4. One elementary property we can investigate is connectedness. We can imagine that demand and productivity shocks diffuse more widely through a given production network when the network is relatively connected. 1 We obtain input expenditures and total sales for each sector from the Make-Use Tables of the
Input–Output Accounts Data. The figure was created using Python’s NetworkX library.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
53
2.1 Multisector Models
ot re ar
co
ut
in
mi
ma wh
ag go ed pr
tr fi
Figure 2.1 Backward linkages for 15 US sectors in 2021
Conversely, the impact of a demand shock occurring within an absorbing set will be isolated to sectors in that set. The 15-sector network in Figure 2.1 is strongly connected. Checking this visually is hard, so instead we use a graph-theoretic algorithm that finds strongly connected components from QuantEcon’s DiGraph class. (This class is convenient for the current problem because instances are created directly from the adjacency matrix.) Examining the attributes of this class when the weights are given by the 15-sector input–output model confirms its strong connectedness. The same class can be used to
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
54
Production
Table 2.1 Sector codes for the 15-good case Label
Sector
ag ar co ed fi go in ma mi ot pr re tr ut wh
Agriculture, forestry, fishing, and hunting Arts, entertainment, accommodation, and food services Construction Educational services, health care, and social assistance Finance, insurance, real estate, rental, and leasing Government Information Manufacturing Mining Other services, except government Professional and business services Retail trade Transportation and warehousing Utilities Wholesale trade
verify that the network is also aperiodic. Hence, the input–output matrix A is primitive. This fact will be used in computations below.
2.1.1.3
Disaggregation Figure 2.2 repeats the graphical representation for the more disaggregated 71-sector case. Sector codes are provided in Table 2.2. Input–output coefficients below 0.01 were rounded to zero to increase visual clarity. As in the 15-sector case, the sizes of vertices and edges are proportional to share of sales and input–output coefficients, respectively. Hotter colors indicate higher hub-based eigenvector centrality (which we link to propagation of demand shocks in §2.1.3). Unlike the 15-sector case, the 71-sector 2021 input–output matrix is not strongly connected. This is because it contains sinks (sectors with zero out-degree). For example, according to the data, sector 441 “motor vehicle and parts dealers” do not supply any intermediate inputs, although they do, of course, supply products to final consumers.
2.1.2
Equilibrium Equilibrium in Leontief models involves tracing the impact of final demand as it flows backward through different sectors in the economy. To illustrate the challenges this generates, consider the simplified network shown in Figure 2.3. Suppose sector 3 receives a positive demand shock. Meeting this demand will require greater output from its immediate suppliers, which are sectors 2 and 4. However, an increase in production in sector 2 requires more output from sector 1, which then requires more output from sector 3, where the initial shock occurred. This, in turn, requires more
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
55
2.1 Multisector Models
313TT 483
722
23 486
GFGN 711AS
335
445
624
212
487OS 441
GFGD
334
61
512
514
325
327
113FF 211 GSLE
621
333
315AL
511 532RL
5412OP 326 GSLG 622
GFE
22 521CI
213111CA
482 485 5415 323
525 523
339
562 3361MV
4A0
332
311FT 561
HS
815411 452
322
55 623 337
721
484 42
513 324
493 713
321
481 ORE
5243364OT 331
Figure 2.2 Network for 71 US sectors in 2021
output from sectors 2 and 4, and so on. Thus, the chain of backward linkages leads to an infinite loop. Resolving this tail-chasing problem requires some analysis.
2.1.2.1
Identities To start our search for equilibria, we set • di := final consumer demand for good i. • xi := total sales of sector i. • z i j := inter-industry sales from sector i to sector j.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
56
Production
Table 2.2 Sector codes for the 71-good case IO Code
Sector
IO Code Sector
111CA 113FF 211 212 213 22 23 311FT 313TT 315AL 321 322 323 324 325 326 327 331 332 333 334 335 3361MV 3364OT 337 339 4A0 42 441 445 452 481 482 483 484 485
Farms Forestry, fishing Oil and gas extraction Mining, except oil, gas Mining support activities Utilities Construction Food, beverage, tobacco Textile mills and products Apparel and leather Wood products Paper products Printing Petroleum and coal Chemical products Plastics, rubber Nonmetallic mineral products Primary metals Fabricated metal products Machinery Computer & electronic products Electrical equipment Motor vehicles, parts Other transportation equipment Furniture Miscellaneous manufacturing Other retail Wholesale trade Motor vehicle and parts dealers Food and beverage stores General merchandise stores Air transportation Rail transportation Water transportation Truck transportation Passenger transportation
486 487OS 493 511 512 513 514 521CI 523 524 525 532RL 5411 5412OP 5415 55 561 562 61 621 622 623 624 711AS 713 721 722 81 GFE GFGD GFGN GSLE GSLG HS ORE
Pipeline transportation Other transportation Warehousing and storage Publishing industries Motion picture and sound Broadcasting, telecommunications Data processing, internet publishing Reserve banks, credit intermediation Securities and investments Insurance carriers Funds, trusts, financial vehicles Rental and leasing services Legal services Miscellaneous technical services Computer systems design Firm management Administrative Waste management Educational services Ambulatory health care services Hospitals Nursing and residential care facilities Social assistance Arts, spectator sports, museums Amusements, gambling, recreation Accommodation Food services and drinking places Other services, except government Federal government enterprises Federal government (defense) Federal government (nondefense) State and local government enterprises State and local government Housing Other real estate
All numbers are understood to be in units of national currency – dollars, say. For each sector i, we have the accounting identity xi =
n X
z i j + di ,
(2.1)
j=1
which states that total sales are divided between sales to other industries and sales to final consumers.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.1 Multisector Models
57
zi j = dollar value of inputs from i per dollar output from j = ai j , xj
(2.2)
a11 1 a21 a31
a12 2
4 a24 a43 a23 3
Figure 2.3 A simple production network
Notice that
where the values ai j are the the input–output coefficients discussed in §2.1.1.1. Using the coefficients, (2.1) can be rewritten as xi =
n X
ai j x j + di ,
i = 1, . . . n.
(2.3)
j=1
The first term on the right-hand side is the amount of good i required as input when n . We can combine the n equations in (2.3) into the the output vector is x := (xi )i=1 linear system x = Ax + d.
2.1.2.2
(2.4)
Existence and Uniqueness So far we have used no more than accounting identities and definitions. However, we would also like to use (2.4) to determine output vector x given demand vector d, taking A as fixed. As a first step, we seek conditions under which nonnegative solutions to (2.4) exist and are unique. The value added of sector j is defined as sales minus spending on intermediate goods, or v j := x j −
n X i=1
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
zi j .
58
Production
assumption 2.1.1 The input–output adjacency matrix A obeys η j :=
n X
ai j < 1 for all j ∈ [n].
(2.5)
i=1
Exercise 2.1.1. Prove that Assumption 2.1.1 holds whenever value added is strictly positive in each sector. Exercise 2.1.1 shows that Assumption 2.1.1 is very mild. For example, in a competitive equilibrium, where firms make zero profits, positive value added means that payments to factors of production other than intermediate goods (labor, land, etc.) are strictly positive. Exercise 2.1.2. Let η(A) := max j∈[n] η j . Prove that r (A) 6 η(A) < 1 whenever Assumption 2.1.1 holds. proposition 2.1.1 If Assumption 2.1.1 holds, then, for each d > 0, the production system (2.4) has the unique nonnegative output solution x ∗ = Ld,
where L := (I − A)−1 .
(2.6)
Proof By Exercise 2.1.2 and Assumption 2.1.1, we have r (A) < 1. Hence the Neumann series lemma (NSL) implies x ∗ in (2.6) is the unique solution in Rn . Regarding nonnegativity, since A is nonnegative, so is Ai for all i. Hence x ∗ > 0, by the power P∞ i series representation L = i=0 A provided by the NSL. The matrix L = (`i j ) in (2.6) is called the Leontief inverse associated with the coefficient matrix A. We discuss its interpretation in §2.1.3. Exercise 2.1.3. A demand vector is called nontrivial if d 6= 0. Let d be nontrivial, and suppose that r (A) < 1. Show that, in equilibrium, every sector is active (i.e., x ∗ 0) when A is irreducible. Exercise 2.1.4. A closed input–output system is one where d = 0. A nontrivial solution of a closed system x = Ax is a nonzero x ∈ Rn+ such that Ax ∗ = x ∗ . Let A be irreducible. Show that no nontrivial solution exists when r (A) < 1. Show that a nontrivial solution exists and is unique up to constant multiples when r (A) = 1. Exercise 2.1.5. Consider a closed input–output system defined by input matrix A. Let A be primitive. Show that every nontrivial solution is everywhere positive. Show that no nontrivial solution exists when r (A) > 1.
2.1.2.3
Assumptions It is common to interpret the expression x ∗ = (I − A)−1 d from (2.6) as meaning that supply is driven by demand. While this is not a universal truth, it does have plausibility in some settings, such as when analyzing demand shifts in the short run.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.1 Multisector Models
59
Changes in demand lead to changes in inventories, which typically cause firms to modify production quantities. We investigate these ideas in depth in §2.1.3. Another assumption concerns the production function in each sector. You might recall from elementary microeconomics that the Leontief production function takes the form x = f (z 1, . . . ,z n ) = min{γ1 z 1, . . . ,γn z n }.
(2.7)
Here x is the output in a given sector, {γi } is a set of parameters, and {z i } is a set of inputs. To understand why (2.7) is called a Leontief production function, note that by (2.2) we have zi j for all i ∈ [n] such that ai j > 0. (2.8) xj = ai j If we interpret z/0 = ∞ for all z > 0, then (2.8) implies x j = mini∈[n] z i j /ai j . This is a version of (2.7) specialized to sector j. Hence (2.7) arises naturally from Leontief input–output analysis. A final comment on assumptions is that, while the Leontief model is too simple for some purposes, it serves as a useful building block for more sophisticated models. We discuss one such model in §2.2.1.
2.1.3
Demand Shocks In this section we study the impacts of changes in demand via a power series repreP sentation i>0 Ai of the Leontief inverse L. We assume throughout that r (A) < 1, so that the series and L are finite and equal.
2.1.3.1
Response to Demand Shocks Consider the impact of a demand shock of size 1d, so that demand shifts from d0 to d1 = d0 + 1d. The equilibrium output vector shifts from x0 = Ld0 to x1 = Ld1 . Subtracting the first of these equations from the second and expressing the result in terms of differences gives 1x = L1d. Using the geometric sum version of the Leontief inverse yields 1x = 1d + A(1d) + A2 (1d) + · · · .
(2.9)
The sums in this term show how the shock propagates backward through the production network: (i) 1d is the initial response in each sector; (ii) A(1d) is the response generated by the first round of backward linkages; (iii) A2 (1d) is the response generated by the second round; and so on. The total response is the sum of responses at all rounds. P We can summarize the above by stating that a typical element `i j of L = m>0 Am shows the total impact on sector i of a unit change in demand for good j, after taking
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
60
Production
go ot ar ed pr
sector i
fi in tr re wh ma co ut mi ag ag
mi
ut
co
ma
wh
re
tr
in
fi
pr
ed
ar
ot
go
sector j Figure 2.4 The Leontief inverse L (hotter colors indicate larger values)
into account all direct and indirect effects. L itself is reminiscent of a Keynesian multiplier: Changes in demand are multiplied by this matrix to generate the final output. Figure 2.4 helps visualize the Leontief inverse computed from the 15-sector network. Hotter colors indicate larger values for `i j , with i on the vertical axis and j on the horizontal axis. We see, for example, that an increase in demand in almost any sector generates a rise in manufacturing output.
2.1.3.2
Shock Propagation Figure 2.5 shows the impact of a given vector of demand shocks 1d on the 15-sector input–output model. In this simulation, each element of 1d was drawn independently from a uniform distribution. The vector 1d is shown visually in the panel titled “round 0,” with hotter colors indicating larger values. The shock draw was relatively large in retail (re) and information (in). The remaining rounds then show the values A2 (1d), A4 (1d), etc., with hotter colors indicating higher values. In each round, to make the within-round comparison between sectors clearer, values of the vector Ai (1d) are rescaled into the [0,1] interval before the color map is applied. Note that, by round 6, the values of Ai (1d) have settled into a fixed pattern. (This is only up to a scaling constant, since values are rescaled into [0,1] as just discussed.) Manufacturing is the most active sector, while finance and professional services are
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
61
2.1 Multisector Models
round 0
round 2
ag
re
go
ag
re
go
ut
ut
mi
mi
in
wh
co
tr
in
ma
co
tr
ed
pr
wh
ed
pr ma
fi ar
ot
fi
round 4
round 6
ag
re
ar
ot
go
ag
re
go
ut
ut
mi
mi
in
wh
co
tr
in
ma
co
tr
ed
pr
wh
ed
pr ma
fi ar
ot
fi
round 8
round 10
ag
re
ar
ot
go
ag
re
go
ut
ut
mi
mi
in
wh
co
tr
ed
pr ma
fi ot
in
wh
co
tr
ed
pr ma
ar
fi ot
ar
Figure 2.5 Propagation of demand shocks via backward linkages
also quite active. In fact, if we repeat the simulation with a new draw for 1d, the pattern of active sectors quickly converges to exactly the same configuration. We can explain this phenomenon using the Perron–Frobenius theorem. Since A is primitive (in the 15-sector case), we know that r (A)−m Am converges to eε> as m → ∞, where e and ε are the dominant left and right eigenvectors, respectively, normalized so that hε,ei = 1. It follows that, for large m, we have Am (1d) ≈ r (A)m hε,1di e.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
(2.10)
62
Production
In other words, up to a scaling constant, the shock response Am (1d) converges to the dominant right eigenvector, which is also the hub-based eigenvector centrality measure. In Figure 2.5, the scaling constant is not visible because the values are rescaled to a fixed interval before the color map is applied. However, (2.10) shows us its value, as well as the fact that the scaling constant converges to zero like r (A)m . Hence, the dominant eigenpair (r (A),e) gives us both the configuration of the response to an arbitrary demand shock and the rate at which the response dies out as we travel back through the linkages. At this point, we recall that the sectors in Figure 2.1 were colored according to hub-based eigenvector centrality. If you compare this figure to Figure 2.5, you will be able to confirm that, at least for later rounds, the color schemes line up, as predicted by the theory. Finance (fi) and manufacturing (ma) rank highly, as does the professional services sector (pr), which includes consulting, accounting, and law.
2.1.3.3
Eigenvector Centrality Let’s look at hub-based eigenvector centrality more closely. In a production network, the hub property translates into being an important supplier. Our study of demand shocks in §2.1.3 highlighted the significance of the eigenvector measure of hub-based centrality: If sector i has high rank under this measure, then it becomes active after a large variety of different shocks. Figure 2.6 shows hub-based eigenvector centrality as a bar graph for the 15-sector case. By this measure, manufacturing is by far the most dominant sector in the US economy. Reviewing the color scheme in Figure 2.2 based on our current understanding of eigenvector centrality, we see that technical servies (54120P), insurance (524),
0:40
eigenvector centrality
0:35 0:30 0:25 0:20 0:15 0:10 0:05 0:00 ag
mi
ut
co ma wh
re
tr
in
fi
pr
ed
Figure 2.6 Eigenvector centrality across US industrial sectors
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
ar
ot
go
63
2.1 Multisector Models
5101 2701
1501
2404
0201 4401
7001
3301
2303
7210 1101
6301
1304
0501 4601 1701 1001
9201 2405 5201
1902 0701 2304
8601 1107 1801 1303 2601
5801
6601
4501 1205 8010 1804
6401
0103 0102
0901 9502
3002
5501
3201
1108
2102
4701
3901
2203 7310
1803
3001
2401 1301
9402 8901
0401
7701 0301
2001 5601
2901 8110
0101
1402 2202
1601 1201
2002 1105
9501 2801
9101
31011102
2302
6001
1306 2004 1106
5701
4801 8401
2301 1109 2605 2201
1305 6701 2204 7501 2005
0802 1401 2101
9401
2403 1502
7601 4901
6901 2502 1104
1802
6702
6201 5401 1103 2501 2003 0801 0601
1901 8210 1202
1302
Figure 2.7 Network for 114 Australian industry sectors in 2020
chemical products (325), and primary metals (331) are among the most highly ranked, and hence a wide range of demand shocks generate high activity in these sectors. To provide some extra context, we show the analogous figure using Australian 2020 input–output data, collected by the Australian Bureau of Statistics (Figure 2.7). Node size is proportional to sales share, and arrow width is proportional to the input–output coefficient. The color map shows hub-based eigenvector centrality. By this measure, the highest-ranked sector is 6901, which is “professional, scientific, and technical services.” This includes scientific research, engineering, computer
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
64
Production
systems design, law, accountancy, advertising, market research, and management consultancy. The next-highest sectors are construction and electricity generation.
2.1.3.4
Output Multipliers One way to rank sectors that has a long tradition in input–output analysis is via output multipliers. The output multiplier of sector j, denoted below by µ j , is usually defined as the “total sector-wide impact of an extra dollar of demand in sector j,” where total means taking into account backward linkages. This measure has historically been of interest to policy makers considering the impacts of fiscal stimuli. Recalling from §2.1.3.1 that `i j shows the total impact on sector i of a unit change in demand for good j, we come to the definition µj =
n X
`i j
( j ∈ [n]).
i=1
In vector notation, this is µ> = 1> L, or µ> = 1> (I − A)−1 .
(2.11)
Comparing this with (1.39), we see that the vector of output multipliers is equal to the authority-based Katz centrality measure (with the parameter β defaulting to unity). The connection between the two measures makes sense: High authority-based centrality means that a sector has many inward links and that those links are from other important sectors. Loosely speaking, such a sector is an important buyer of intermediate inputs. A sector highly ranked by this measure that receives a demand shock will cause a large impact on the whole production network. Figure 2.8 shows the sizes of output multipiers across 15 US industrial sectors, calculated from the same input–output data as the previous 15-sector figures, using (2.11). The highest ranks are assigned to manufacturing, agriculture, and construction.
2.1.4
Forward Linkages Several economic questions connect to the relative “upstreamness” of a sector or production good. For example, Olabisi (2020) finds that upstreamness is related to sectoral volatility, while Antràs et al. (2012) examine the relationship between upstreamness and tendency to export. Tariff changes tend to have different aggregate effects when applied to upstream rather than downstream industries (Martin & Otto, 2020). Finally, since WWII, many developing countries have systematically supported and encouraged upstream industries (Liu, 2019). In order to study upstreamness, we first introduce the Ghosh model for forward linkages, which uses a rearrangement of terms from the original Leontief model.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.1 Multisector Models
65
2:00 1:75
Output multipliers
1:50 1:25 1:00 0:75 0:50 0:25 0:00 ag
mi
ut
co ma wh
re
tr
in
fi
pr
ed
ar
ot
go
Figure 2.8 Output multipliers across 15 US industrial sectors
2.1.4.1
The Ghosh Model Recall that ai j = z i j /x j = the dollar value of inputs from i per dollar of sales from j. Consider now the related quantities zi j f i j := = value of inputs from i to j per dollar output from i. (2.12) xi Let F := ( f i j )i, j∈[n] . The matrix F is called the direct-output matrix or the Ghosh matrix. Element f i j can be interpreted as the size of the “forward linkage” from i to j. Analogous to A, the matrix F can be viewed as a weight function over output sectors and visualized as in Figure 2.9. This digraph uses the same data source as Figure 2.1. Exercise 2.1.6. Prove that A and F are similar matrices (see §1.2.1.5) when x 0. Let v j be value added in sector j (i.e., payments to factors of production other than intermediate goods). We have xj =
n X
zi j + v j
( j ∈ [n]).
(2.13)
i=1
This states that (under perfect competition), the revenue of sector j is divided between Pn spending on intermediate goods, which is the first term i=1 z i j , and payments to other factors of production (value added). P Using the forward linkages, we can rewrite (2.13) as x j = i f i j xi + v j for all j or, in matrix form, x > = x > F + v> .
(2.14)
Taking transposes and solving under the assumption r (F) < 1 gives x ∗ = (I − F > )−1 v.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
(2.15)
66
Production
ot re ar
co
ut
in
mi
ma wh
ag go ed pr
tr fi
Figure 2.9 Forward linkages and upstreamness over US industrial sectors
We can think of the solution x ∗ in (2.15) as the amount of output necessary to acquire a given amount of value added. Since payments of value added are made to underlying factors of production, the Ghosh model is also called a “supply-side input–output model.” Exercise 2.1.7. In §2.1.2.2 we argued that r (A) < 1 will almost always hold. This carries over to r (F), since r (A) = r (F) whenever x 0. Provide a proof of the last statement.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.1 Multisector Models
67
We omit a discussion of the relative merits of supply- and demand-driven input– output models. Our main interest in forward linkages is due to their connection to the topic of ranking sectors by relative upstreamness.
2.1.4.2
Upstreamness Which industries are relatively upstream? One proposed measure of upstreamness can be found in Antràs et al. (2012). With f i j as defined in (2.12), the upstreamness u i of sector i is defined recursively by ui = 1 +
n X
fi j u j .
(2.16)
j=1
The recursive definition of the vector u in (2.16) stems from the idea that those sectors selling a large share of their output to upstream industries should be upstream themselves. We can write (2.16) in vector form as u = 1 + Fu and solve for u as u = (I − F)−1 1.
(2.17)
A unique nonnegative solution exists provided that r (F) < 1. We expect this to hold in general, due to the findings in Exercise 2.1.7. Maintaining the convention β = 1, we see that the upstreamness measure (2.17) proposed by Antràs et al. (2012) is identical to the hub-based Katz centrality measure (1.37) for the production network with weights allocated by the forward linkage matrix F. Figure 2.10 shows the result of computing u via (2.17), plotted as a bar graph, for the 15-sector input–output network. Consistent with expectations, the primary 3:0
upstreamness
2:5
2:0
1:5
1:0
0:5
0:0 ag
mi
ut
co ma wh
re
tr
in
fi
pr
Figure 2.10 Relative upstreamness of US industrial sectors
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
ed
ar
ot
go
68
Production
commodity producers (agriculture and mining) are the most upstream, while retail and education are typical downstream sectors. The nodes in Figure 2.9 are also colored by upstreamness.
2.2
General Equilibrium One limitation of the Leontief input–output analysis from §2.1 is that demand is fixed and exogenous. In this section we embed Leontief’s model in an equilibrium setting where output and prices are determined by a combination of supply and demand. One objective is to understand how an input–output structure interacts with firm-level shocks to shape aggregate volatility.
2.2.1
Supply and Demand Our first step is to introduce and solve a multisector general equilibrium model based on Acemoglu et al. (2012) and Carvalho and Tahbaz-Salehi (2019).
2.2.1.1
Production and Prices As in the Leontief economy, there are n sectors, also called industries, each of which produces one good. Real output in sector j is given by y j = s j `αj
n Y
a
qi ji j .
(2.18)
i=1
Here • • • •
s j is a sector-specific shock (independent across sectors); ` j is labor input to sector j; qi j is the amount of good i used in the production of good j; and P α and ai j take values in (0,1) and satisfy α + i ai j = 1 for all j ∈ [n].
The last condition implies constant returns to scale (CRS) in each sector.2 Exercise 2.2.1. Let A = (ai j ) be the n × n matrix of technical coefficients from the Cobb–Douglas production function in (2.18). Using the stated assumptions and the results in §1.2.3.4, show that r (A) < 1.3 Exercise 2.2.2. Prove that the (i, j)-th element of Am .
P P i
(m)
j
(m)
ai j = n(1 − α)m for all m ∈ N, where ai j is
2 In order to be consistent with traditional input–output notation (see §2.1), we transpose i and j relative
to sources such as Acemoglu et al. (2012) and Carvalho and Tahbaz-Salehi (2019). This is just a matter of convention. 3 Later, in §2.3, we use additional spectral theory to prove the exact result r (A) = 1 − α.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.2 General Equilibrium
69
Firms are price takers. With p j being the price of good j, a firm in sector j maximizes profits X π j := p j y j − w` j − pi qi j (2.19) i
with respect to the n + 1 controls ` j and q1 j , . . . ,qn j . Exercise 2.2.3. Show that, when prices and wages are taken as given, the unique global maximizers of (2.19) are pj yj pj yj `j = α and qi j = ai j (i, j ∈ [n]). (2.20) w pi
remark 2.2.1 From (2.20) we have ai j = ( pi qi j )/( p j y j ), which states that the i, j-th technical coefficient is the dollar value of inputs from i per dollar of sales from j. This coincides with the definition of ai j from the discussion of input–output tables in §2.1.1.1. Hence, in the current setting, the (unobservable) technical coefficient matrix equals the (observable) input–output coefficient matrix defined in §2.1. Substituting the maximizers (2.20) into the production function gives n p y α Y p j y j ai j j j y j = cs j , w pi
(2.21)
i=1
where c is a positive constant depending only on parameters. Exercise 2.2.4. Using (2.21), show that X pj ρj = ai j ρi − ε j , where ρ j := ln w
and
ε j := ln(cs j ).
i
n n Let ρ and ε be the column vectors (ρi )i=1 and (εi )i=1 of normalized prices and log shocks from Exericse 2.2.4. Collecting the equations stated there leads to ρ > = ρ > A − ε> , or
ρ = A> ρ − ε. Exercise 2.2.5. Prove that X ρj = − εi `i j ,
where L := (`i j ) := (I − A)−1 .
(2.22)
(2.23)
i
Why is L well defined? As in Chapter 2, the matrix L is the Leontief inverse generated by A.
2.2.1.2
Consumption Wages are paid to a representative household who chooses consumption to maximize P utility i ln ci . In equilibrium, profits are zero, so the only income accruing to the
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
70
Production
household consists of wage income. The household supplies one unit of labor inelasP tically. Hence, the budget constraint is i pi ci = w. Exercise 2.2.6. Show that the unique utility maximizer is the vector (c1, . . . ,cn ) that satisfies pi ci = w/n for all i ∈ [n]. (Equal amounts are spent on each good.)
2.2.1.3
Aggregate Output In this economy, aggregate value added (defined in §2.1.4) is equal to the wage bill. This quantity is identified with real aggregate output and referred to as GDP. The Domar weight of each sector is defined as its sales as a fraction of GDP: pi yi . h i := w P From the closed economy market clearing condition yi = ci + j qi j and the optimality conditions, we obtain X pj yj w yi = + ai j . (2.24) npi pi j
Exercise 2.2.7. Letting L = (`i j ) be the Leontief inverse and using (2.24), show that Domar weights satisfy hi =
1X `i j n
for all i ∈ [n].
j
Pn
Exercise 2.2.8. Prove that
i=1 h i
= 1/α.
From the results of Exercise 2.2.4 we obtain ln w = ln p j + g := ln w and summing yields X X X ng = ln p j + εi `i j . j
Normalizing prices so that
P
i
i
P
i
εi `i j . Setting
j
ln pi = 0, this simplifies to X g= εi h i .
(2.25)
i
Thus, log GDP is the inner product of sectoral shocks and the Domar weights.
2.2.2
The Granular Hypothesis We have just constructed a multisector model of production and output. We plan to use this model to study shock propagation and aggregate fluctuations. Before doing so, however, we provide a relatively simple and network-free discussion of shock propagation. The first step is to connect the propagation of shocks to the firm size
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.2 General Equilibrium
71
distribution. Later, in §2.2.3, we will see how these ideas relate to the general equilibrium model and the topology of the production network.
2.2.2.1
Aggregate vs. Idiosyncratic Shocks Some fluctuations in aggregate variables, such as GDP growth and the unemployment rate, can be tied directly to large exogenous changes in the aggregate environment. One obvious example is the jump in the US unemployment rate from 3.5% to 14.8% between February and April 2020, which was initiated by the onset of the COVID pandemic and the resulting economic shutdown. Other significant fluctuations lack clear macro-level causes. For example, researchers offer mixed explanations for the 1990 US recession, including “technology shocks,” “consumption shocks,” and loss of “confidence” (Cochrane, 1994). However, these explanations are either difficult to verify on the basis of observable outcomes or require exogenous shifts in variables that should probably be treated as endogenous. One way to account for at least some of the variability observed in output growth across most countries is on the basis of firm-level and sector-specific productivity and supply shocks. Examples of sector-specific shocks include (i) the spread of African Swine Fever to China in 2018; (ii) the Great East Japan Earthquake of 2011 and resulting tsunami, which triggered meltdowns at three reactors in the Fukushima Daiichi Nuclear Power Plant; and (iii) the destruction of Asahi Kasei Microdevices’ large scale integrated circuit factory in Miyazaki Prefecture in October 2020. In the discussion below, we investigate the extent to which firm-level shocks can drive fluctuations in aggregate productivity.
2.2.2.2
The Case of Many Small Firms It has been argued that idiosyncratic, firm-level shocks can only account for a very small fraction of aggregate volatility (see, e.g., Dupor (1999)). The logical heart of this argument is the dampening effect of averaging over independent random variables. To illustrate the main idea, we follow a simple model of production without linkages across firms by Gabaix (2011). Suppose there are n firms, with the size of the i-th firm, measured by sales, denoted Pn by Si . Since all sales fulfill final demand, GDP is given by Y := i=1 Si . We use 0 primes for next period values and 1 for first differences (e.g., 1Si = Si − Si ). We assume that firm growth 1Si /Si is equal to σ F εi , where {εi } is a collection of iid random variables corresponding to firm-level idiosyncratic shocks. We also assume that Var(εi ) = 1, so that σ F represents firm-level growth volatility. GDP growth is then Pn n X 1Si 1Y Si G := = i=1 = σF εi . Y Y Y i=1
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
72
Production
Exercise 2.2.9. Treating the current firm size distribution {Si } and hence GDP as given, show that, under the stated assumptions, the standard deviation of GDP growth σG := (Var G)1/2 is ! n 2 1/2 X Si σG = σ F Hn , where Hn := . (2.26) Y i=1
√ If, say, all firms are equal size, so that nSi = Y , this means that σG = σ F / n, so volatility at the aggregate level is very small when the number of firms is large. For example, if the number of firms n is 106 , which roughly matches US data, then σG 1 1/2 = 10−3 = 0.001. (2.27) = Hn = σF 106 Hence firm-level volatility accounts for only 0.1% of aggregate volatility. To be more concrete, Gabaix (2011) calculates σ F = 12, which means that, by (2.27), σG = 0.012%. But the volatility of GDP growth is actually far higher. Indeed, Figure 2.11 reports that, for the USA, σG is approximately 2%, which is two orders of magnitude greater. The core message is that, under the stated assumptions, firm-level shocks explain only a tiny part of aggregate volatility.
2.2.2.3
The Effect of Heavy Tails There are some obvious problems with the line of reasoning used in §2.2.2.2. One is that firms are assumed to be of identical size. In reality, most firms are small to medium, while a relative few are enormous. For example, in the USA, sectors such as technology, electronics, and retail are each dominated by a small number of very large firms. Gabaix (2011) emphasized that we can get closer to actual GDP volatility by more n thoughtful specification of the firm size distribution. Altering the distribution {Si }i=1 changes the value Hn in (2.27), which is called the Herfindahl index. This index is often applied to a group of firms in a sector to measure industry concentration. For given aggregate output Y , the Herfindahl index is minimized when Si = S j for all i, j. This is the case we considered above. The index is maximized at Hn = 1 when a single firm dominates all sales. By (2.27), a larger Herfindahl index will increase σG relative to σ F , which allows firm-level shocks to account for more of aggregate volatility. n Calculation of Hn is challenging because the entire firm size distribution {Si }i=1 is difficult to observe. Nonetheless, we can estimate Hn by (a) estimating a populan tion probability distribution that fits the empirical distribution {Si }i=1 and (b) using analysis or Monte Carlo simulations to calculate typical values of Hn . For step (a), Gabaix (2011) cites the study of Axtell (2001), which finds the firm n size distribution to be Pareto with tail index 1.059. If we repeatedly draw {Si }i=1 6 from a Pareto distribution with α = 1.059 and n = 10 , record the value of Hn after
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
73
2.2 General Equilibrium
Brazil (4.15%)
United States (2.14%) 10 %
%
10 0 −10
0 −10
1960
1970
1980
1990
2000
2010
2020
1960
1970
United Kingdom (2.70%)
%
% 1970
1980
1990
2000
2010
2020
1960
1970
%
%
1990
2000
2010
2020
2010
2020
2010
2020
2010
2020
10
0
0 −10
1960
1970
1980
1990
2000
2010
2020
1960
1970
1980
1990
2000
Mexico (3.80%) 10 %
10 %
1980
Indonesia (3.40%)
Argentina (5.45%)
0
0 −10
1960
1970
1980
1990
2000
2010
2020
1960
1970
Australia (1.76%)
1980
1990
2000
South Africa (2.66%)
10
10 %
%
2020
−10 1960
10
0 −10
2010
0
Japan (3.92%)
−10
2000
10
0
−10
1990
France (2.44%)
10
−10
1980
1960
1970
1980
1990
2000
2010
2020
0 −10
1960
1970
1980
1990
2000
Figure 2.11 GDP growth rates and std. deviations (in parentheses) for 10 countries
each draw, and then take the median value as our estimate, we obtain Hn ≈ 0.88. In other words, under the Pareto assumption just stated, firm-level volatility accounts for almost 90% of aggregate volatility. In essence, this means that, to explain aggregate volatility, we need to look no further than firm-level shocks.
2.2.2.4
Sensitivity Analysis The finding in the previous paragraph is quite striking. How seriously should we take it? One issue is that the figure Hn ≈ 0.88 is not robust to small changes in assumptions. For example, the regression in Figure 1.7 suggests that we take 1.32 as our estimate for
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
74
Production
the tail index α, rather than Axtell’s value of 1.059. If we rerun the same calculation with α = 1.32, the estimated value of Hn falls to 0.018. In other words, firm-level shocks account for only 1.8% of aggregate volatility. Another issue is that the large value for Hn obtained under Axtell’s parameterization is very sensitive to the parametric family chosen for the firm size distribution. The next exercise illustrates this. Exercise 2.2.10. Figure 1.7 suggests only that the far right tail of the firm size distribution obeys a Pareto law. In fact, some authors argue that the lognormal distribution provides a better fit than the Pareto distribution (Kondo et al. (2020) provide a recent discussion). So suppose now that {Si } is n iid draws from the L N (µ,σ 2 ) distribution (as given in Example 1.3.2), where µ,σ are parameters.4 Implement and run Algorithm 1. Set m = 103 and n = 106 . Choose µ and σ so that the mean and median of the L N (µ,σ2 ) distribution agree with that of the standard Pareto distribution with tail index α, which are α/(α − 1) and 21/α , respectively. As in Gabaix (2011), set α = 1.059. What estimate do you obtain for Hn ? How much of aggregate volatility is explained?
1 2 3 4 5 6
for j in 1, . . . ,m do j generate n independent draws {Si } from the L N (µ,σ2 ) distribution ; j
j
compute the Herfindahl index Hn corresponding to {Si } ; end j
set Hn equal to the median value of {Hn }mj=1 ; return Hn Algorithm 1: Generate an estimate of Hn under lognormality
2.2.3
Network Structure and Shock Propagation The sensitivity analysis in §2.2.2.4 suggests we should be skeptical of the claim that firm-level shocks explain most aggregate-level shocks that we observe. This means that either micro-level shocks account for only a small fraction of aggregate volatility or, alternatively, that the model is too simple, and micro-level shocks are amplified through some other mechanism. An obvious way to explore this further is to allow linkages between firms, in the sense that the inputs for some firms are outputs for others. Such an extension opens up the possibility that shocks propagate through the network. This seems plausible even for the sector-specific shocks listed above, such as the Great East Japan Earthquake. 4 In other words, each S is an independent copy of the random variable S := exp(µ + σ Z ), where Z is i
standard normal.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.2 General Equilibrium
75
Although the initial impact was focused on electricity generation, the flow-on effects for other sectors were rapid and substantial (Carvalho et al., 2021). To investigate more deeply, we connect our discussion of the granular hypothesis back to the multisector models with linkages studied above, allowing us to study flowon and multiplier effects across industries.
2.2.3.1
Industry Concentration and Shocks From (2.25) and the independence of sectoral shocks, the standard deviation σg of log GDP is given by !1/2 n X 2 σg = σ Hn , where Hn := hi , (2.28) i=1
where σ is the standard deviation of each εi . Note that the expression for aggregate volatility takes the same form as (2.26) from our discussion of the granular hypothesis in §2.2.2, where Hn was called the Herfindahl index. Once again, this index is the critical determinant of how much firmlevel volatility passes through to aggregate volatility. In particular, as discussed in §2.2.2.3, independent firm-level shocks cannot explain aggregate volatility unless Hn is large, which in turn requires that the components of the vector h are relatively concentrated in a single or small number of sectors. Pn To investigate an extreme case, we recall from Exercise 2.2.8 that i=1 h i = 1/α. The Herfindahl index is Hn := khk, where k · k is the Euclidean norm. Pn Exercise 2.2.11. Show that the minimizer of khk given i=1 h i = 1/α is the constant vector where h i = 1/(αn) for all i. Under this configuration of sector shares, 1 √ 1 k1k = n=O Hn = nα nα
1 √ n
.
Hence, by (2.28), we have σg = O(n −1/2 ). This is the classic diversification result. The standard deviation of log GDP goes to zero like n −1/2 , as in the identical firm size case in §2.2.2.2. Now let’s consider the other extreme: Exercise 2.2.12. Show that the maximum of Hn = khk under the constraint Pn i=1 h i = 1/α is 1/α, attained by setting h k = 1/α for some k and h j = 0 for other indices. This is the extreme case of zero diversification. By (2.25), log GDP is then X 1 g= εi h i = ε k . α i
The volatility of log GDP is constant in n, rather than declining in the number of sectors. In other words, idiosyncratic and aggregate shocks are identical.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
76
Production
1
2
3
4
5
Figure 2.12 Star network with single hub
2.2.3.2
The Role of Network Topology In the previous section we looked at two extreme cases, neither of which is realistic. Now we look at intermediate cases. In doing so, we note an interesting new feature: Unlike the analysis in §2.2.2, where the sector shares were chosen from some fixed distribution, the Herfindahl index is now determined by the network structure of production. To see this, we can use the results of Exercise 2.2.7 to obtain 1 1 X m h = L1 = A 1. n n m>0
Recalling our discussion in §1.4.3.5, we see that the vector of Domar weights is just a rescaling of the vector of hub-based Katz centrality rankings for the input– output matrix. Thus, the propagation of sector-specific productivity shocks up to the aggregate level depends on the distribution of Katz centrality across sectors. The more “unequal” this distribution, the larger the pass through. Figures 2.12 and 2.13 show some examples of different network configurations, each of which is associated with a different Katz centrality vector. Not surprisingly, the symmetric network has a constant centrality vector, so that all sectors have equal centrality. This is the maximum diversification case, as discussed in §2.2.3.1. The other two cases have nonconstant centrality vectors and hence greater aggregate volatility.5 Exercise 2.2.13. Let the nonzero input–output coefficients ai j shown by the arrows in Figures 2.12 and 2.13 all have equal value 0.2. Show computationally that the hubbased Katz centrality vectors for the hub and star networks are κ h = (1.8,1,1,1,1)
and
κs = (1.2,1.2,1.2,1.2,1),
respectively (for nodes 1, . . . ,5). The results of Exercise 2.2.13 show that the hub network has the more unequal Katz centrality vector. Not surprisingly, the source node in the hub has a high hub-
5 The captions in Figure 2.13 refer to these two cases as “star networks,” in line with recent usage in
multisector production models. In graph theory, a star network is an undirected graph that (a) is strongly connected and (b) has only one node with degree greater than one.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.2 General Equilibrium
2
77
1
5
3
4
(a) Star network with single authority 1
2
4
3 (b) Symmetric network Figure 2.13 Symmetric and asymmetric networks
Katz hub centrality
4
3
2
1
0 ag
mi
ut
co ma wh
re
tr
in
fi
pr
ed
ar
ot
go
Figure 2.14 Hub-based Katz centrality across 15 US industrial sectors
based centrality ranking. Productivity shocks affecting this sector have a large effect on aggregate GDP. Figure 2.14 shows hub-based Katz centrality computed from the 15-sector input– output data for 2021. We can see that productivity shocks in manufacturing will have a significantly larger impact on aggregate output than shocks in, say, retail or education.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
78
Production
2.2.3.3
Supply Shocks vs. Demand Shocks In the previous section we saw that the degree to which a productivity shock propagates through the economy depends on the hub-based centrality ranking of the relevant sector. This is intuitive. Sectors that act like hubs supply many sectors, so changes in productivity in these sectors will have large flow-on effects. This is in contrast to what we learned in §2.1.3.4, where a high authority-based centrality measure leads to high shock propagation. The difference can be explained by the source of the shocks: In §2.1.3.4, we were concerned with the impact of demand shocks. Demand shocks to sector i have large flow-on effects when many sectors purchase inputs from sector i. Hence, authority-based centrality measures are appropriate for studying this case.
2.3
More Spectral Theory This is a relatively technical section, which analyzes aspects of vector dynamics and spectral theory in more depth. It is aimed at readers who are interested in further mathematical discussion of the theory treated above. The ideas studied here are applied to production problems to generate additional insights into the existence and uniqueness of equilibria, as well as later topics such as convergence of distributions for Markov models on networks.
2.3.1
Vector Norms In this section we learn about abstract vector norms on Rn and provide several examples. Later we will see how the different norms are related and how they can be useful for some kinds of network analysis.
2.3.1.1
Norms A function k · k : Rn → R is called a norm on Rn if, for any α ∈ R and u,v ∈ Rn , (a) (b) (c) (d)
kuk > 0 kuk = 0 ⇐⇒ u = 0 kαuk = |α|kuk and ku + vk 6 kuk + kvk
(nonnegativity) (positive definiteness) (positive homogeneity) (triangle inequality)
The Euclidean norm is a norm on Rn , as suggested by its name. Example 2.3.1: The `1 norm of a vector u ∈ Rn is defined by u = (u 1, . . . ,u n ) 7→ kuk1 :=
n X i=1
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
|u i |.
(2.29)
79
2.3 More Spectral Theory
In machine learning applications, k · k1 is sometimes called the “Manhattan norm,” and d1 (u,v) := ku − vk1 is called the “Manhattan distance” or “taxicab distance” between vectors u and v. We will refer to it more simply as the `1 distance or `1 deviation. Exercise 2.3.1. Verify that the `1 norm on Rn satisfies (a)–(d) above. The `1 norm and the Euclidean norm are special cases of the so-called ` p norm, which is defined for p > 1 by !1/ p n X p u = (u 1, . . . ,u n ) 7→ kuk p := |u i | . (2.30) i=1
It can be shown that u 7→ kuk p is a norm for all p > 1, as suggested by the name (see, e.g., Kreyszig (1978)). For this norm, the subadditivity in (d) is called Minkowski’s inequality. Since the Euclidean case is obtained by setting p = 2, the Euclidean norm is also called the `2 norm, and we write k · k2 rather than k · k when extra clarity is required. n |u | is also a norm on Rn . Exercise 2.3.2. Prove that u 7→ kuk∞ := maxi=1 i
(The symbol kuk∞ is used because, ∀ u ∈ Rn , we have kuk p → kuk∞ as p → ∞.) This norm is called the supremum norm. Pn Exercise 2.3.3. The so-called `0 “norm” kuk0 := i=1 1{u i 6= 0}, routinely used n in data science applications, is not in fact a norm on R . Prove this.
2.3.1.2
Equivalence of Vector Norms When u and (u m ) := (u m )m∈N are all elements of Rn , we say that (u m ) converges to u and write u m → u if ku m − uk → 0 as m → ∞ for some norm k · k on Rn . It might seem that this definition is imprecise. Don’t we need to clarify that the convergence is with respect to a particular norm? In fact we do not. This is because any two norms k · ka and k · kb on Rn are equivalent, in the sense that there exist finite constants M, N such that Mkuka 6 kukb 6 N kuka
for all u ∈ Rn .
(2.31)
Exercise 2.3.4. Let us write k · ka ∼ k · kb if there exist finite M, N such that (2.31) holds. Prove that ∼ is an equivalence relation on the set of norms on Rn . Exercise 2.3.5. Let k · ka and k · kb be any two norms on Rn . Given a point u in and a sequence (u m ) in Rn , use (2.31) to confirm that ku m − uka → 0 implies ku m − ukb → 0 as m → ∞. Rn
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
80
Production
Another way to understand u m → u is via pointwise convergence: Each element of the vector sequence u m converges to the corresponding element of u. Pointwise and norm convergence are equivalent, as the next result makes clear. lemma 2.3.1 Fix (u m ) ⊂ Rn , u ∈ Rn , and norm k · k on Rn . Taking m → ∞, the following statements are equivalent: (i) ku m − uk → 0; (ii) ha,u m i → ha,ui for all a ∈ Rn ; and (iii) (u m ) converges pointwise to u. Exercise 2.3.6. Prove Lemma 2.3.1. Exercise 2.3.7. Using Lemma 2.3.1, provide a simple proof of the fact that convergence in Rn is preserved under addition and scalar multiplication: If u m → x and vm → y in Rn , while αm → α in R, then u m + vm → x + y and α m u m → αx.
2.3.2
Matrix Norms In some applications, the number of vertices n of a given digraph is measured in millions or billions. This means that the adjacency matrix A is enormous. To control complexity, A must often be replaced by a sparse approximation As . It is natural to require that A and As are close. But how should we define this? More generally, how can we impose a metric on a set of matrices to determine similarity or distance between them? One option is to follow the example of vectors on Rn and introduce a norm on Mn×k . With such a norm k · k in hand, we can regard A and As as close when kA − As k is small. For this and other reasons, we now introduce the notion of a matrix norm.
2.3.2.1
Definition Analogous to vectors on Rn , we will call a function k · k from Mn×k to R+ a norm if for any A, B ∈ Mn×k , (a) (b) (c) (d)
kAk > 0 kAk = 0 ⇐⇒ u = 0 kα Ak = |α|kAk and kA + Bk 6 kAk + kBk
(nonnegativity) (positive definiteness) (positive homogeneity) (triangle inequality)
The distance between two matrices A, B is then specified as kA − Bk. Unlike vectors, matrices have a product operation defined over all conformable matrix pairs. We want matrix norms to interact with this product in a predictable way. For example, it is helpful for analysis when a matrix norm k · k is submultiplicative, meaning that
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
81
2.3 More Spectral Theory
kABk 6 kAk · kBk for all conformable matrices A, B.
(2.32)
A useful implication of (2.32) is that kAi k 6 kAki for any i ∈ N and A ∈ Mn×n , where Ai is the i-th power of A.
2.3.2.2
The Frobenius Norm One way to construct a norm on matrix space Mn×k is to first introduce the Frobenius inner product of matrices A = (ai j ), B = (bi j ) as hA, Bi F :=
n X n X
ai j bi j = trace(AB > ) = trace(B A> ).
(2.33)
i=1 j=1
From this inner product, the Frobenius norm of A ∈ Mn×k is defined as 1/2
kAk F := hA, Ai F .
(2.34)
In essence, the Frobenius norm converts an n × k matrix into an nk vector and computes the Euclidean norm. The Frobenius norm is submultiplicative. The next exercise asks you to prove this in one special case. Exercise 2.3.8. Suppose that A is a row vector and B is a column vector. Show that (2.32) holds in this case when k · k is the Frobenius norm.
2.3.2.3
The Operator Norm Another important matrix norm is the operator norm, defined at A ∈ Mn×k by kAk := sup{kAuk : u ∈ Rk and kuk = 1},
(2.35)
where the norm k · k on the right hand size of (2.35) is the Euclidean norm on Rn . P Example 2.3.2: If A = diag(ai ), then, for any u ∈ Rn we have kAuk2 = i (ai u i )2 . P 2 To maximize this value subject to i u i = 1, we pick j such that a 2j > ai2 for all i and set u i = 1{i = j}. The maximized value of kAuk is then q kAk = a 2j = max |ai |. i∈[n]
Exercise 2.3.9. Show that kAk equals the supremum of kAuk/kuk over all u 6= 0. Exercise 2.3.10. It is immediate from the definition of the operator norm that kAuk 6 kAk · kuk
∀ u ∈ Rn .
Using this fact, prove that the operator norm is submultiplicative.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
(2.36)
82
Production
Exercise 2.3.11. Let k · k be the operator norm on Mn×n . Show that, for each A ∈ Mn×n , we have (i) kAk2 = r (A> A); (ii) r (A)k 6 kAk k for all k ∈ N; and (iii) kA> k = kAk.
2.3.2.4
Other Matrix Norms Two other useful matrix norms are the `1 and `∞ norms given by kAk1 :=
n X k X
|ai j | and kAk∞ :=
i=1 j=1
max
i∈[n], j∈[k]
|ai j |.
Exercise 2.3.12. Prove that both are norms on Mn×k . Exercise 2.3.13. Prove that both norms are submultiplicative.
2.3.2.5
Equivalence of Matrix Norms In §2.3.1.2 we saw that all norms on Rn are equivalent. Exactly the same result holds true for matrix norms: Any two norms k · ka and k · kb on Mn×k are equivalent, in the sense that there exist finite constants M, N such that MkAka 6 kAkb 6 N kAka
for all A ∈ Mn×k .
(2.37)
A proof can be found (for abstract finite-dimensional vector space) in Bollobás (1999). Analogous to the vector case, given A and (Am ) := (Am )m∈N in Mn×k , we say that (Am ) converges to A and write Am → A if kAm − Ak → 0 as m → ∞, where k · k is a matrix norm. Once again, we do not need to clarify the norm due to the equivalence property. Also, norm convergence is equivalent to pointwise convergence: Exercise 2.3.14. Prove that, given A and (Am ) in Mn×k , we have Am → A as m → ∞ if and only if every element aimj of Am converges to the corresponding element ai j of A. Exercise 2.3.15. Prove the following result for matrices A, B,C and matrix sequences (Am ),(Bm ), taking m → ∞ and assuming sizes are conformable: (i) If Bm → A and Am − Bm → 0, then Am → A. (ii) If Am → A, then B Am C → B AC.
Example 2.3.3: Convergence of the Perron projection in (1.11) of the Perron–Frobenius theorem was defined using pointwise convergence. By Exercise 2.3.14, norm convergence also holds. One of the advantages of working with norms
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
83
2.3 More Spectral Theory
is that we can give rates of convergence for norm deviation. This idea is discussed further in §2.3.3.3. Exercise 2.3.16. Given A and (Am ) in Mn×n , prove that Am → A as m → ∞ if and only if s > Am s → s > As for every s ∈ Rn .
2.3.3
Iteration in Matrix Space Results such as Proposition 1.4.2 on page 36 already showed us the significance of powers of adjacency matrices. The Perron–Frobenius theorem revealed connections between spectral radii, dominant eigenvectors, and powers of positive matrices. In this section we investigate powers of matrices in more depth.
2.3.3.1
Gelfand’s Formula One very general connection between matrix powers and spectral radii is Gelfand’s formula for the spectral radius: theorem 2.3.2 For any matrix norm k · k and A ∈ Mn×n , we have r (A) = lim kAk k1/k . k→∞
(2.38)
Proofs can be found in Bollobás (1999) or Kreyszig (1978). Exercise 2.3.17. The references above show that the limit (2.38) always exists. Using this fact, prove that every choice of norm over Mn×n yields the same value for this limit. The next exercise shows that r (A) < 1 implies kAk k → 0 at a geometric rate. Exercise 2.3.18. Using (2.38), show that r (A) < 1 implies the existence of a constant δ < 1 and an M < ∞ such that kAk k 6 δ k M for all k ∈ N. Exercise 2.3.19. Consider the dynamic system xt = Axt−1 + d with x0 given, where each xt and d are vectors in Rn , and A is n × n. (If you like, you can think of this process as orders flowing backwards through a production network.) Show that, when r (A) < 1, the sequence (xt )t>0 converges to x ∗ := (I − A)−1 d, independent of the choice of x0 . Exercise 2.3.20. In §2.2.1 we studied a production coefficient matrix of the form A = (ai j ) in Mn×n , where each ai j takes values in (0,∞), and, for each j, α + P 0. We can calculate r (A) using the following strategy. In i ai j = 1 for some α > P P (m) (m) Exercise 2.2.2 we saw that i j ai j = n(1 − α)m for all m ∈ N, where ai j is the P P (i, j)-th element of Am . Using the fact that kBk1 := i j |bi j | is a matrix norm, apply Gelfand’s formula to obtain r (A) = 1 − α.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
84
Production
2.3.3.2
A Local Spectral Radius Theorem The next theorem is a “local” version of Gelfand’s formula that relies on positivity. It replaces matrix norms with vector norms, which are easier to compute. theorem 2.3.3 x 0, then
Fix A ∈ Mn×n and let k · k be any norm on Rn . If A > 0 and kAm xk1/m → r (A)
(m → ∞).
(2.39)
Theorem 2.3.3 tells us that, eventually, for any positive x, the norm of the vector Am x grows at rate r (A). A proof can be found in Krasnoselskii (1964).6 Example 2.3.4: In §2.1.3 we studied how the impact of a given demand shock 1d flows backward through a production network, with Am (1d) giving the impact on sectors at m steps (backward linkages). When 1d 0 and r (A) < 1, Theorem 2.3.3 tells us that kAm 1dk = O(r (A)m ). If we set the norm to k · k∞ , this tells us that the maximal impact of demand shocks through backward linkages fades at rate r (A). Exercise 2.3.21. Prove Theorem 2.3.3 in the case where A is primitive.
2.3.3.3
Convergence to the Perron Projection The local spectral radius theorem assumes A > 0. Now we further strengthen this assumption by requiring that A is primitive. In this case, r (A)−m Am converges to the Perron projection as m → ∞ (see (1.11)). We want rates of convergence in highdimensional settings. We fix A ∈ Mn×n and label the eigenvalues so that |λi+1 | 6 |λi | for all i. Note that |λ 1 | = λ 1 = r (A). Let E := e ε> be the Perron projection. proposition 2.3.4 and
If A is diagonalizable and primitive, then α := |λ 2 /λ 1 | < 1 kr (A)−m Am − Ek = O α m .
(2.40)
Thus, an upper bound on the rate of convergence to the Perron projection is determined by the modulus of the ratio of the first two eigenvalues. Pn Proof We saw in (1.5) that Am = i=1 λim ei εi> for all m ∈ N. From this spectral representation we obtain n X r (A)−m Am − e1 ε1> = r (A)−m Am − r (A)m e1 ε1> = θim ei εi> i=2
when θi := λi /r (A). Let k · k be the operator norm on gives
Mn×n .
The triangle inequality
6 A direct proof of a generalized version of Theorem 2.3.3 is provided in Theorem B1 of Boroviˇcka and
Stachurski (2020).
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.3 More Spectral Theory
−m
kr (A)
A
m
− e1 ε1> k
6
n X
m
|θi |
kei εi> k
i=2
m
6 |θ2 |
n X
85
kei εi> k.
i=2
Since A is primitive, the Perron–Frobenius theorem tells us that |λ 2 | < r (A). Hence α := |θ2 | < 1. The proof is now complete.
2.3.4
Exact Stability Conditions The Neumann series lemma tells us that the linear system x = Ax + d has a unique solution whenever r (A) < 1. We also saw that, in the input–output model, where A is the adjacency matrix, the condition r (A) < 1 holds whenever every sector has positive value added (Assumption 2.1.1 and Exercise 2.1.2). Hence we have sufficient conditions for stability. This analysis, while important, leaves open the question of how tight the conditions are and what happens when they fail. For example, we might ask (i) To obtain r (A) < 1, is it necessary that each sector has positive value added? Or can we obtain the same result under weaker conditions? (ii) What happens when r (A) < 1 fails? Do we always lose existence of a solution, or uniqueness, or both? In §2.3.4.1 and §2.3.4.2 below we address these two questions.
2.3.4.1
Spectral Radii of Substochastic Matrices To reiterate, the results in §5.1.3 relied on the assumption that every sector has positive value added, which in turn gave us the property r (A) < 1 for the adjacency matrix of the input–output production network. Positive value added in every sector is not necessary, however. Here we investigate a weaker condition that is exactly necessary and sufficient for r (A) < 1. This weaker condition is very helpful for understanding other kinds of networks too, including financial networks, as discussed in §5.2. To begin, recall that a matrix P ∈ Mn×n is called stochastic if P > 0 and P1 = 1. Similarly, P ∈ Mn×n is called substochastic if P > 0 and P1 6 1. Thus, a substochastic matrix is a nonnegative matrix with less than unit row sums. Clearly the transpose Q > of a nonnegative matrix Q is substochastic if and only if Q has less than unit column sums. A natural example of a substochastic matrix is the transpose A> of an adjacency matrix A of an input–output network. Indeed, such an A is nonnegative and, for the j-th column sum we have P X zi j spending on inputs by sector j ai j = i = . xj total sales of sector j i
P
Hence i ai j 6 1, which says that spending on intermediate goods and services by a given industry does not exceed total sales revenue, is a necessary condition for
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
86
Production
nonnegative profits in sector j. When this holds for all j, the adjacency matrix has less than unit column sums. From Lemma 1.2.7 on page 15, we see that any substochastic matrix P has r (P) 6 max rowsumi (P) 6 1. i
(2.41)
We wish to know when we can tighten this to r (P) < 1. From (2.41), one obvious sufficient condition is that rowsumi (P) < 1 for all i. This is, in essence, how we used Assumption 2.1.1 (every sector has positive value added) P in the input–output model. Under that condition, we have i ai j < 1 for all j, which says all column sums are strictly less than one. Hence max colsumi (A) < 1 ⇐⇒ max rowsumi (A> ) < 1 H⇒ r (A> ) < 1 ⇐⇒ r (A) < 1, i
i
where the middle implication is by (2.41), and the last equivalence is by r (A) = r (A> ). Now we provide a weaker – in fact necessary and sufficient – condition for r (P) < 1, based on network structure. To do so, we define an n × n substochastic matrix P = ( pi j ) to be weakly chained substochastic if, for all m ∈ [n], there exists P an i ∈ [n] such that m → i and j pi j < 1. Here accessibility of i from m is in terms of the induced weighted digraph.7 Exercise 2.3.22. Let A = (ai j ) ∈ Mn×n be nonnegative. Show that A> is weakly chained substochastic if and only if A has less than unit column sums and, for each m ∈ [n], there exists an i ∈ [n] such that i → m under (the digraph induced by) A P and k aki < 1. proposition 2.3.5 For a substochastic matrix P, we have r (P) < 1
⇐⇒
P is weakly chained substochastic.
A proof can be found in Corollary 2.6 of Azimzadeh (2019). Now we return to the input–output model. Let’s agree to say that sector i is an upstream supplier to sector j if i → j in the input–output network. By Proposition 1.4.2 on page 36, an equivalent statement is that there exists a k ∈ N such that aikj > 0. Exercise 2.3.23. Let A be the adjacency matrix of an input–output network, and assume that value added is nonnegative in each sector. Using Proposition 2.3.5, show that r (A) < 1 if and only if each sector in the network has an upstream supplier with positive value added.
7 Induced weighted digraphs are defined in §1.4.2.1. By Proposition 1.4.2, accessibility of i from m is k > 0, where p k is the m,i-th element of P k (and P 0 = I ). equivalent to existence of a k > 0 with pmi mi
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
2.3 More Spectral Theory
2.3.4.2
87
A Converse to the Neumann Series Lemma Since the Neumann series lemma is a foundational result with many economic applications, we want to know what happens when the conditions of the lemma fail. Here is a partial converse: theorem 2.3.6 Fix A ∈ Mn×n with A > 0. If A is irreducible, then the following statements are equivalent: (i) (ii) (iii) (iv)
r (A) < 1. x = Ax + b has a unique everywhere positive solution for all b > 0 with b 6= 0. x = Ax + b has a nonnegative solution for at least one b > 0 with b 6= 0. There exists an x 0 such that Ax x.
remark 2.3.1 If A is irreducible and one of (and hence all of) items (i)–(iv) are P true, then, by the Neumann series lemma, the unique solution is x ∗ := m>0 Am b. remark 2.3.2 Statement (iii) is obviously weaker than statement (ii). It is important, however, in the case where r (A) < 1 fails. In this setting, from the negation of (iii), we can conclude that there is not even one nontrivial b in Rn+ such that a nonnegative solution to x = Ax + b exists. Proof of Theorem 2.3.6 We show (i) ⇐⇒ (iv) and then (i) ⇐⇒ (ii) ⇐⇒ (iii). ((i) ⇒ (iv)). For x in (iv) we can use the Perron–Frobenius theorem to obtain a real eigenvector e satisfying Ae = r (A)e e and e 0. ((iv) ⇒ (i)). Fix x 0 such that x Ax. Through positive scaling, we can assume that kxk = 1. Choose λ < 1 such that λx > Ax. Iterating on this inequality gives, for all k ∈ N, λ k x > Ak x
H⇒
λ k = λk kxk > kAk xk
⇐⇒
kAk xk1/k 6 λ.
Hence, by the local spectral radius result in Theorem 2.3.3, r (A) 6 λ < 1. P ((i) ⇒ (ii)). Existence of a unique solution x ∗ = i>0 Ai b follows from the NSL. P Positivity follows from irreducibility of A, since b 6= 0 and i Ai 0. ((ii) ⇒ (iii)). Obvious. ((iii) ⇒ (i)). Suppose there is a b > 0 with b 6= 0 and an x > 0 such that x = Ax + b. By the Perron–Frobenius theorem, we can select a left eigenvector e such that e 0 and e> A = r (A)e> . For this e we have e> x = e> Ax + e> b = r (A)e> x + e> b. Since e 0 and b 6= 0, we must have e> b > 0. In addition, x 6= 0 because b 6= 0 and x = Ax + b, so e> x > 0. Therefore r (A) satisfies (1 − r (A))α = β for positive constants α,β. Hence r (A) < 1. Exercise 2.3.24. For the production system x = Ax + d, what do we require on A for the condition r (A) < 1 to be necessary for existence of a nonnegative output solution x ∗ , for each nontrivial d?
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
88
Production
Exercise 2.3.25. Irreducibility cannot be dropped from Theorem 2.3.6. Provide an example demonstrating that, without irreducibility, we can have r (A) > 1 for some A > 0 and yet find a nonzero b > 0 and an x > 0 such that x = Ax + b.
2.4
Chapter Notes High-quality foundational textbooks on input–output analysis and multisector production networks include Nikaido (1968), Miller and Blair (2009), and Antràs (2020). References on production networks and aggregate shocks include Acemoglu et al. (2012), Antràs et al. (2012), Di Giovanni et al. (2014), Carvalho (2014), Barrot and Sauvagnat (2016), Baqaee (2018), Carvalho and Tahbaz-Salehi (2019), Acemoglu and Azar (2020), Liu and Tsyvinski (2020), Miranda-Pinto (2021), and Carvalho et al. (2021). For other network-centric analysis of multisector models, see, for example, Bernard et al. (2019), who use buyer–supplier relationship data from Belgium to investigate the origins of firm size heterogeneity when firms are interconnected in a production network. Herskovic (2018) analyzes asset pricing implications of production networks. Cai and Szeidl (2018) consider the effect of inter-firm relationships on business performance. La’O and Tahbaz-Salehi (2022) study optimal monetary policy in a production network. Dew-Becker (2022) analyzes tail risk and aggregate fluctuations in a nonlinear production network. Elliott et al. (2022) show that complex supply networks can greatly amplify small idiosyncratic shocks. Elliott and Golub (2022) provide a survey of network fragility that includes a discussion of production networks and the impact of sectoral shocks.
https://doi.org/10.1017/9781009456340.004 Published online by Cambridge University Press
3
Optimal Flows
Up until now we have analyzed problems where network structure is either fixed or generated by some specified random process. In this chapter, we investigate networks where connections are determined endogenously via equilibrium or optimality conditions. In the process, we cover some of the most powerful methods available for solving optimization problems in networks and beyond, with applications ranging from traditional graph and network problems, such as trade, matching, and communication, through to machine learning, econometrics, and finance.
3.1
Shortest Paths As a preliminary step, we study the shortest path problem – a topic that has applications in production, network design, artificial intelligence, transportation, and many other fields. The solution method we adopt also happens to be one of the clearest illustrations of Bellman’s principle of optimality, which is one of the cornerstones of optimization theory and modern economic analysis.
3.1.1
Definition and Examples We start proceedings by introducing simple examples. (In the next section we will formalize the problem and consider solution methods.)
3.1.1.1
Set Up Consider a firm that wishes to ship a container from A to G at minimum cost, where A and G are vertices of the weighted digraph 𝒢 shown in Figure 3.1. Arrows (edges) indicate paths that can be used for freight, while weights indicate costs of traversing them. In this context, the weight function is also called the cost function, and we denote it by c. For example, c(A, B) is the cost of traveling from vertex A to vertex B. Since this graph is small, we can find the minimum cost path visually. A quick scan shows that the minimum attainable cost is 8. Two paths realize this cost: (A,C, F,G) and (A, D, F,G), as shown in Figure 3.2 and Figure 3.3, respectively.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
90
Optimal Flows
A 5 C
3
1
D
9
B 6
2
4
E 8
F
4
1 G
Figure 3.1 Graph for the shortest path problem
A 5 C
3
1
D
9
B 6
2
4
E 8
F
4
1 G Figure 3.2 Solution 1
A 5 C
3
1
D
9
B 6
2
4
E 8
F
4
1 G Figure 3.3 Solution 2
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.1 Shortest Paths
3.1.1.2
91
A Recursive View Let’s now consider a systematic solution that can be applied to larger graphs. Let q ∗ (x) denote the minimum cost-to-go from vertex x. That is, q ∗ (x) is the total cost of traveling from x to G if we take the best route. Its values are shown at each vertex in Figure 3.4. We can represent q ∗ in vector form via (q ∗ (A),q ∗ (B),q ∗ (C),q ∗ (D),q ∗ (E),q ∗ (F),q ∗ (G)) = (8,10,3,5,4,1,0) ∈ R7 . (3.1) As is clear from studying Figure 3.4, once q ∗ is known, the least-cost path can be computed as follows: Start at A and, from then on, at arbitrary vertex x, move to any y that solves min {c(x, y) + q ∗ (y)}.
y∈𝒪(x)
(3.2)
Here 𝒪(x) = {y ∈ V : (x, y) ∈ E} is the set of direct successors of x, as defined in §1.4.1, while c(x, y) is the cost of traveling from x to y. In other words, to minimize the cost-to-go, we choose the next path to minimize current traveling cost plus costto-go from the resulting location. Thus, if we know q ∗ (x) at each x, then finding the best path reduces to the simple two stage optimization problem in (3.2). But now another problem arises: how to find q ∗ in more complicated cases, where the graph is large. One approach to this problem is to exploit the fact that q ∗ (x) = min {c(x, y) + q ∗ (y)} y∈𝒪(x)
(3.3)
must hold for every vertex x in the graph apart from G (where q ∗ (G) = 0). Take the time to convince yourself that, for our example, the function q ∗ satisfies (3.3). In particular, check that (3.3) holds at each nonterminal x in Figure 3.4. We can understand (3.3), which is usually called the Bellman equation, as a restriction on q ∗ that helps us identify this vector. The main difficulty with our plan is that 8 A 5 3 C 2
3
1
5 D
9
B 10 6
4
E 4 8
1 F
4
1 G 0
Figure 3.4 The cost-to-go function, with q ∗ (x) indicated by red digits at each x
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
92
Optimal Flows
the Bellman equation is nonlinear in the unknown function q ∗ . Our strategy will be to convert this nonlinear equation into a fixed point problem, so that fixed point theory can be applied. We do this in the context of a more general version of the shortest path problem.
3.1.2
Bellman’s Method We consider a generic shortest path problem on a flow network, which consists of a weighted digraph 𝒢 = (V , E,c) with a sink d ∈ V called the destination and a weight function c : E → (0,∞) that associates a positive cost to each edge (x, y) ∈ E. In what follows, we take |V | = n. We consider how to find the shortest (i.e., minimum cost) path from x to d for every x ∈ V . In doing so we impose the following assumption. assumption 3.1.1 𝒢 is a directed acyclic graph. Moreover, for each x ∈ V with x 6= d, there exists a directed path from x to d. To simplify the arguments below, we consider a second digraph 𝒢0 = (V , E 0 ), where V is unchanged and E 0 = E ∪ {(d,d)}. In other words, E 0 extends E by adding a self-loop at d. We also extend c to this self-loop by setting c(d,d) = 0. This just means that “terminating at d” is the same as “staying at d,” since no more cost accrues after arrival at the destination. Figure 3.5 illustrates this in the context of the previous example. Exercise 3.1.1. Prove that, for the extended digraph 𝒢0 , every infinite directed path x1,x2, . . . obeys xi = d for all i > n.
A 5 C
3
1
D
9
B 6
2
4
E 8
F
4
1 G 0
Figure 3.5 Addition of a self loop to the destination
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.1 Shortest Paths
93
We will use the intuition from the previous section, based around the Bellman equation, to construct a solution method.
3.1.2.1
Policies Instead of optimal paths, it turns out to be more convenient to aim for optimal policies. In general, a policy is a specification of how to act in every state. In the present setting, a policy is a map σ : V → V with σ(x) = y understood as meaning “when at vertex x, go to y.” A policy is called feasible if σ(x) ∈ 𝒪(x) for all x ∈ V . For any feasible policy σ and x ∈ V , the trajectory of x under σ is the path from x to the destination indicated by the feasible policy. In other words, it is the sequence ( p0, p1, p2, . . .) defined by p0 = x and pi = σ( pi−1 ) for all i ∈ N. It can also be expressed as (σi (x)) := (σi (x))i>0 , where σi is the i-th composition of σ with itself. Let 6 be the set of all feasible policies. In view of Exercise 3.1.1, policies in 6 have the property that every trajectory they generate reaches d in n steps and stays there. In other words, σi (x) = d for all i > n and all x ∈ V .
(3.4)
V , we call σ ∈ 6 q-greedy if Given q ∈ R+
σ(x) ∈ argmin{c(x, y) + q(y)}
for all x ∈ V .
y∈𝒪(x)
In essence, a greedy policy treats q as the minimum cost-to-go function and picks out an optimal path under that assumption. Using our new terminology, we can rephrase the discussion in §3.1.1.2 as follows: The shortest-path problem can be solved by finding the true minimum cost-to-go function q ∗ and then following a q ∗ -greedy policy. In the remainder of this section, we prove this claim more carefully.
3.1.2.2
Cost of Policies We need to be able to assess the cost of any given policy. To this end, for each x ∈ V and σ ∈ 6, let qσ (x) denote the cost of following σ from x. That is, qσ (x) =
∞ X
c(σi (x),σi+1 (x)) =
i=0
n−1 X
c(σi (x),σi+1 (x)).
(3.5)
i=0
σi (x)
This second equality holds because = d for all i > n and c(d,d) = 0. The V is called the cost-to-go under σ. function qσ ∈ R+ It will be helpful in what follows to design an operator such that qσ is a fixed point. V with q(d) = 0 and define T : U → U by For this purpose we let U be all q ∈ R+ σ (Tσ q)(x) = c(x,σ(x)) + q(σ(x))
(x ∈ V ).
Here and below, with k ∈ N, the expression Tσk indicates the k-th composition of Tσ with itself (i.e., Tσ is applied k times).
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
94
Optimal Flows
Exercise 3.1.2. Prove that Tσ is a self-map on U for all σ ∈ 6. proposition 3.1.1 For each σ ∈ 6, the function qσ is the unique fixed point of Tσ in U , and Tσk q = qσ for all k > n and all q ∈ U . Proof Fix σ ∈ 6 and q ∈ U . For each x ∈ V we have (Tσ2 q)(x) = c(x,σ(x)) + (Tσ q)(σ(x)) = c(x,σ(x)) + c(σ(x),σ2 (x)) + q(σ 2 (x)). More generally, for k > n, we have (Tσk
q)(x) =
k−1 X
i
c(σ (x),σ
i+1
k
(x)) + q(σ (x)) =
n−1 X
c(σi (x),σi+1 (x)).
i=0
i=0
The second equality holds because σ k (x) = d for all k > n and q(d) = 0. Hence (Tσk q)(x) = qσ (x) by (3.5). The fact that qσ is the unique fixed point of Tσ now follows from Exercise A.1.3 in the appendix (page 185).
3.1.2.3
Optimality The minimum cost-to-go function q ∗ is defined by q ∗ (x) = min qσ (x) σ∈6
(x ∈ V ).
The definition of q ∗ matches our intuitive definition from §3.1.1.2, in the sense that q ∗ (x) is, for each x ∈ V , the minimum cost of traveling from x to the destination d. A policy σ ∗ ∈ 6 is called optimal if it attains the minimum in the definition of q ∗ , so that q ∗ = qσ∗ on V . Our main aims are to (i) obtain a method for calculating q ∗ and (ii) prove that a q ∗ -greedy policy is optimal, as suggested in our informal discussion above. Regarding the first step, we claim that q ∗ satisfies the Bellman equation (3.3). To prove this claim, we introduce the Bellman operator T via (T q)(x) = min {c(x, y) + q(y)} y∈𝒪(x)
(x ∈ V ).
(3.6)
By construction, q ∗ satisfies the Bellman equation (3.3) if and only if T q ∗ = q ∗ . Exercise 3.1.3. Show that T is a self-map on U and, moreover, T q 6 Tσ q for all q ∈ U and σ ∈ 6. V with respect Exercise 3.1.4. Show that T and Tσ are both order-preserving on R+ to the pointwise partial order 6. Prove that T k q 6 Tσk q for all q ∈ U , σ ∈ 6, and k ∈ N.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
95
3.1 Shortest Paths
Exercise 3.1.5. Fix q ∈ U and let σ be a q-greedy policy. Show that T q = Tσ q. The next result is central. It confirms that the minimum cost-to-go function satisfies the Bellman equation and also provides us with a means to compute it: Pick any q in U and then iterate with T . proposition 3.1.2 The function q ∗ is the unique fixed point of T in U and, in addition, T k q → q ∗ as k → ∞ for all q ∈ U . Proof In view of Exercise A.1.3 in the appendix (page 185), it suffices to verify the existence of an m ∈ N such that T k q = q ∗ for all k > m and all q ∈ U . To this end, let γ be the minimum of c(x, y) over all (x, y) ∈ E. Since c is positive on such edges and E is finite, γ > 0. Fix q ∈ U . We claim first that T k q > q ∗ for sufficiently large k. To see this, fix k ∈ N and iterate with T to get (T k q)(x) = c(x, p1 ) + c( p1, p2 ) + · · · + c( pk−1, pk ) + q( pk ) for some path (x, p1, . . . , pk ). By Exercise 3.1.1, this path leads to d in n steps. This means that (T k q)(x) > q ∗ (x) when k > n, since q ∗ (x) is the minimum cost of reaching d from x. For the reverse inequality, fix k > n and observe that, by Proposition 3.1.1 and the inequality from Exercise 3.1.4, T k q 6 Tσk∗ q = qσ∗ = q ∗ . We have now shown that T k q = q ∗ for sufficiently large k, as required. We now have a means to compute the minimum cost-to-go function (by iterating with T , starting at any q ∈ U ) and, in addition, a way to verify the following key result. theorem 3.1.3 A policy σ ∈ 6 is optimal if and only if σ is q ∗ -greedy. Proof By the definition of greedy policies, σ is q ∗ -greedy
c(x,σ(x))+q ∗ (σ(x)) = min {c(x, y)+q ∗ (y)},
⇐⇒
y∈𝒪(x)
∀x ∈ V.
Since q ∗ satisfies the Bellman equation, we then have σ is q ∗ -greedy
⇐⇒
c(x,σ(x)) + q ∗ (σ(x)) = q ∗ (x),
∀x ∈ V.
The right-hand side is equivalent to Tσ q ∗ = q ∗ . At the same time, Tσ has only one fixed point in U , which is qσ . Hence qσ = q ∗ . Hence, by this chain of logic and the definition of optimality, σ is q ∗ -greedy
⇐⇒
q ∗ = qσ
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
⇐⇒
σ is optimal.
96
Optimal Flows
3.1.2.4
An Implementation in Julia Let’s use the ideas set out above to solve the original shortest-path problem, concerning shipping, which we introduced in §3.1.1.1. We will implement in Julia. Our first step is to set up the cost function, which we store as an array called c. We identify the vertices A, . . . , G, with the integers 1, . . . ,7. We set c[i, j] = Inf when no edge exists from i to j, so that such a path is never chosen when evaluating the Bellman operator, as defined in (3.3). When an edge does exist, we enter the cost shown in Figure 3.1: c = fill(Inf, (7, 7)) c[1, c[2, c[3, c[4, c[5, c[6, c[7,
2], c[1, 3], c[1, 4] = 1, 5, 3 4], c[2, 5] = 9, 6 6] = 2 6] = 4 7] = 4 7] = 1 7] = 0
Next we define the Bellman operator: function T(q) Tq = similar(q) n = length(q) for x in 1:n Tq[x] = minimum(c[x, :] + q[:]) end return Tq end Now we arbitrarily set q ≡ 0, generate the sequence of iterations T q,T 2 q,T 3 q, and plot them: using PyPlot fig, ax = plt.subplots() n = 7 q = zeros(n) ax.plot(1:n, q) for i in 1:3 new_q = T(q) ax.plot(1:n, new_q, "-o", alpha=0.7) q = new_q end
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.1 Shortest Paths
97
Figure 3.6 Shortest path Bellman iteration
After adding some labels, the output looks like the image in Figure 3.6. Notice that, by T 3 q, we have already converged on q ∗ . You can confirm this by checking that the values of T 3 q line up with those we obtained manually in Figure 3.4.
3.1.3
Betweenness Centrality In §1.4.3 we discussed a range of centrality measures for networks, including degree, eigenvector, and Katz centrality. Aside from these, there is another well-known centrality measure, called betweenness centrality, which builds on the notion of shortest paths and is particularly popular in analysis of social and peer networks. Formally, for a given graph 𝒢 = (V , E), directed or undirected, the betweenness centrality of vertex v ∈ V is b(v) :=
X x, y∈V \{v}
|S(x,v, y)| , |S(x, y)|
where S(x, y) is the set of all shortest paths from x to y, and S(x,v, y) is the set of all shortest paths from x to y that pass through v. (As usual, |A| is the cardinality of A.) Thus, b(v) is proportional to the probability that, for a randomly selected pair of nodes x, y, a randomly selected shortest path from x to y contains v. Thus, the measure will be high for nodes that “lie between” a large number of node pairs. For example, NetworkX stores a graph called florentine_families_graph that details the marriage relationships between 15 prominent Florentine families during the fifteenth century. The data can be accessed via import networkx as nx G = nx.florentine_families_graph()
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
98
Optimal Flows
Pazzi azzi
Salviati
Acciaiuoli Barbad rbadori ri
Medici
Castellani
Ridolfi Tornabuoni buoni Albizzi
Strozzi
Gin inoori
Peruzzi zzi Guadagni uadagni uadagn
Bischeri
Lamberteschi Lam erteschi
Figure 3.7 Betweenness centrality (by color and node size) for Florentine families
The network is shown in Figure 3.7, which was created using nx.draw_networkx(G, [params]) where [params] stands for parameters listing node size, node color, and other features. For this graph, node size and node color are scaled by betweenness centrality, which is calculated via nx.betweenness_centrality(G) Although this graph is very simple, the output helps to illustrate the prominent role of the Medici family, consistent with their great wealth and influence in Florence and beyond.
3.2
Linear Programming and Duality Our study of shortest paths in §3.1 used a relatively specialized optimization method. In this section we cover more general results in optimization and duality, which will
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.2 Linear Programming and Duality
99
then be applied to endogenous networks, optimal transport, and optimal flows. Part of the strategy is to take challenging optimization problems and regularize them, often by some form of convexification. Before diving into theory, we use §3.2.1 below to provide motivation via one very specific application. This application involves what is typically called matching in economics and linear assignment in mathematics. We illustrate the key ideas in the context of matching workers to jobs. Later, when we discuss how to solve the problem, we will see the power of linear programming, convexification, and duality.
3.2.1
Linear Assignment Behold the town of Springfield. A local employer is shutting down, and 40 workers stand idle. Fortunately for these workers, Springfield lies within a political battleground state, and, as a result, the mayor receives backing to attract a new employer. She succeeds by promising a certain firm that the 40 workers will be retrained for the new skills they require. For mathematical convenience, let us suppose that there are exactly 40 new positions, each with distinct skill requirements. The team set up by the mayor records the individual skills of the 40 workers, along with the requirements of the new positions, and estimates the cost c(i, j) of retraining individual i for position j. The team’s challenge is to minimize the total cost of retraining. In particular, they wish to solve min σ∈𝒫
40 X
c(i,σ(i)),
(3.7)
i=1
where 𝒫 is the set of all permutations (i.e., bijective self-maps) on the integers 1, . . . ,40. Figure 3.8 illustrates one possible permutation. The problem is discrete, so first-order conditions are unavailable. Unsure of how to proceed but possessing a powerful computer, the team instructs its workstation to step through all possible permutations and record the one that leads to the lowest total retraining cost. The instruction set is given in Algorithm 2. After five days of constant execution, the workstation is still running and the mayor grows impatient. The team starts to calculate how long execution will take. The main determinant is the size of the set 𝒫. Elementary combinatorics tells us that the number
workers
1
2
3
···
40
jobs
1
2
3
···
40
Figure 3.8 One possible assignment (i.e., permutation of [40])
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
100
Optimal Flows
1 2 3 4 5 6 7 8 9
set m = +∞ ; for σ in 𝒫 do P40 set t(σ) = i=1 c(i,σ(i)) ; if t(σ) < m then set m = t(σ) ; set σ∗ = σ ; end end return σ∗ Algorithm 2: Minimizing total cost by testing all permutations
of permutations of a set of size n is n!. Quick calculations show that 40! exceeds 8 × 1047 . A helpful team member points out that this is much less than the number of possible AES-256 password keys (approximately 1077 ). The mayor is not appeased and demands a runtime estimate. Further calculations reveal the following: If, for each σ in 𝒫, the workstation can P40 evaluate the cost t(σ) = i=1 c(i,σ(i)) in 10−10 -th of a second (which is extremely optimistic), then the total run time would be 10−10 × 8 × 1047 = 8 × 1037 seconds ≈ 2.5 × 1030 years. Another helpful team member provides perspective by noting that the sun will expand into a red giant and vaporize planet Earth in less than 1010 years. The great computational cost of solving this problem by direct calculations is an example of what is often called the curse of dimensionality. This phrase, coined by Richard Bellman (1920–1984) during his fundamental research into dynamic optimization, refers to the exponential increase in processor cycles needed to solve computational problems to a given level of accuracy as the number of dimensions increases. The matching problem we have just described is high-dimensional because the choice variable σ, a permutation in 𝒫, is naturally associated with the vector (σ(1), . . . ,σ(40)). This, in turn, is a point in 40-dimensional vector space.1 Fortunately, clever algorithms for this matching problem have been found, and, for problems such as this one, useful approximations to the optimal allocation can be calculated relatively quickly. For example, Dantzig (1951) showed how such problems can be cast as a linear program, which we discuss below. Further progress has been
1 Readers familiar with high-performance computing techniques might suggest that the curse of
dimensionality is no cause for concern for the matching problem, since the search algorithm can be parallelized. Unfortunately, even the best parallelization methods cannot save the workstation from being vaporized by the sun with the calculation incomplete. The best-case scenario is that adding another execution thread doubles effective computations per second and hence halves execution time. However, even with 1010 such threads (an enormous number), the execution time would still be 2.5 × 1020 years.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.2 Linear Programming and Duality
101
made in recent years by adding regularization terms to the optimization problem that admit derivative-based methods. In the sections that follow, we place matching problems in a more general setting and show how they can be solved efficiently. Our first step is to review the basics of linear programming.
3.2.2
Linear Programming A linear program is an optimization problem with a linear objective function and linear constraints. If your prior belief is that all interesting problems are nonlinear, then let us reassure you that linear programming is applicable to a vast array of interesting applications. One of these is, somewhat surprisingly, the assignment problem in §3.2.1, as famously demonstrated by the American mathematician George Bernard Dantzig (1914–2005) in Dantzig (1951). Other applications include optimal flows on networks and optimal transport problems, which in turn have diverse applications in economics, finance, engineering, and machine learning. We explain the key ideas below, beginning with an introduction to linear programming.
3.2.2.1
A Firm Problem One way to define linear programs is in terms of what open source and commercial solvers for linear programming problems handle. Typically, for these solvers, the problem takes the form min c> x
(3.8)
x∈Rn
subject to A1 x = b1, A2 x 6 b2, and d` 6 x 6 du .
(3.9)
Here each Ai is a matrix with n columns, and c,b1,b2,d` , and du are conformable column vectors. To illustrate, let’s consider a simple example, which concerns a firm that fabricates products labeled 1, . . . ,n. To make each product requires machine hours and labor. Product i requires m i machine hours and `i labor hours per unit of output, as shown in the table below product 1 .. . n
machine hours m1 .. . mn
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
labor hours `1 .. . `n
unit price p1 .. . pn
102
Optimal Flows
A total of M machine hours and L labor hours are available. Letting qi denote output of product i, the firm’s problem is max π(q1, . . . ,qn ) :=
q1,...,qn
n X
pi qi − wL − r M
i=1
subject to n X
m i qi 6 M,
i=1
n X
`i qi 6 L and q1, . . . ,qn > 0.
(3.10)
i=1
Here π is profits, and w and r are the wage rate and rental rate of capital. We are taking these values as fixed, along with L and M, so choosing the q ∈ Rn+ that maximizes Pn profits is the same as choosing the q that maximizes revenue i=1 pi qi . This will be our objective in what follows. (Why are total labor supply and machine hours held fixed here? We might think of this problem as one of designing a daily or weekly production plan, which optimally allocates existing resources, given current prices.) Figure 3.9 shows an illustration of a simple case with two products. Consistent with Exercise 3.2.3, the feasible set is a polyhedron, shaded in blue. The green lines are contour lines of the revenue function (q1,q2 ) 7→ p1 q1 + p2 q2 , with p1 = 3 and p2 = 4. By inspecting this problem visually and recognizing that the contour lines are increasing as we move to the northeast, it is clear that the maximum is obtained at the extreme point indicated in the figure. P Maximizing revenue is equivalent to minimizing i (− pi )qi , so with c = (− p1, − p2 ), we have a linear programming problem to which we can apply a solver.
4q1 + 2q2 ≤ 20
optimal solution
2q1 + 5q2 ≤ 30
q2 ≥ 0
revenue = 3q1 + 4q2 q1 ≥ 0 Figure 3.9 Revenue maximizing quantities
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.2 Linear Programming and Duality
3.2.2.2
103
A Python Implementation Let’s look at one option for solving this problem with Python, via SciPy’s opensource solver linprog. For the simple two-product firm problem, we ignore the unnecessary equality constraint in (3.9) and set ! ! m1 m2 M and b2 = . A2 = `1 `2 L The bound 0 6 q is imposed by default, so we do not need to specify d` and du . We apply the numbers in Figure 3.9, so the maximization version of the problem is
max 3q1 + 4q2 s.t. q1 > 0, q2 > 0, 2q1 + 5q2 6 30 and 4q1 + 2q2 6 20. (3.11)
q1,q2
Now we set up primitives and call linprog as follows: A = ((2, (4, b = (30, c = (-3,
5), 2)) 20) -4)
# minus in order to minimize
from scipy.optimize import linprog result = linprog(c, A_ub=A, b_ub=b) print(result.x) The output is [2.5, 5.0], indicating that we should set q1 = 2.5 and q2 = 5.0. The result is obtained via the simplex algorithm, discussed in §3.2.2.8. Exercise 3.2.1. As a way to cross-check the solver’s output, try to derive the solution q = (2.5,5.0) in a more intuitive way, by examining Figure 3.9. Exercise 3.2.2. Consider the same problem with the same parameters, but suppose now that, in addition to the previous constraints, output of q2 is bounded above by 4. Use linprog or another numerical linear solver to obtain the new solution.
3.2.2.3
A Julia Implementation When solving linear programs, one option is to use a domain-specific modeling language to set out the objective and constraints in the optimization problem. In Python this can be accomplished using open source libraries, such as Pyomo and Google’s OR-Tools. In Julia we can use JuMP. The following code illustrates the Julia case, using JuMP, applied to the firm problem (3.11). using JuMP using GLPK
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
104
Optimal Flows
m = Model() set_optimizer(m, GLPK.Optimizer) @variable(m, q1 >= @variable(m, q2 >= @constraint(m, 2q1 @constraint(m, 4q1 @objective(m, Max,
0) 0) + 5q2 0} for the linear program (3.12) is a polyhedron. Standard equality form is more general than it first appears. In fact the original formulation (3.8)–(3.9) can be manipulated into standard equality form via a sequence of transformations. Hence, when treating the theory below, we can specialize to standard equality form without losing generality. Although we omit full details on the set of necessary transformations (which can be found in Bertsimas and Tsitsiklis (1997) and many other sources), let’s gain some understanding by converting the firm optimization problem into standard equality form. To simplify notation, we address this task when n = 3, although the general case is almost identical. As above, we switch to minimization of a linear constraint by using the fact that P maximizing revenue is equivalent to minimizing i (− pi )qi . Next, we need to convert the two inequality constraints (3.10) into equality constraints. We do this by introducing slack variables sm and s` and rewriting the constraints as
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.2 Linear Programming and Duality
3 X
3 X
m i qi + sm = M,
i=1
`i qi + s` = L
105
and q1,q2,q3,sm ,s` > 0.
i=1
P3 Indeed, we can see that requiring i=1 m i qi + sm = M and sm > 0 is the same as P3 imposing i=1 m i qi 6 M, and the same logic extends to the labor constraint. Setting x := (q1,q2,q3,sm ,s` ), we can now express the problem as min c> x, x
where c> := (− p1, − p2, − p3,0,0)
subject to
m1 `1
m2 `2
m3 `3
q1 ! q 2 1 0 q3 = 0 1 sm s`
M L
! and
x > 0.
This is a linear program in standard equality form.
3.2.2.5
Duality for Linear Programs One of the most important facts concerning linear programming is that strong duality always holds. Let us state the key results. The dual problem corresponding to the standard equality form linear program (3.12) is D = max b> θ subject to A> θ 6 c. θ∈Rm
(3.13)
Readers who have covered §A.7 in the appendix will be able to see the origins of this expression. In particular, by formula (A.19) in the appendix, the dual problem corresponding to the standard equality form linear program (3.12) can be expressed as D = max min L(x,θ), where L(x,θ) := c> x + θ> (b − Ax) θ∈Rm x∈E
(3.14)
and E = Rn+ . (We can also treat the inequality x > 0 via a multiplier, but this turns out to be unnecessary.) Now observe that ( b> θ if A> θ 6 c > > > min L(x,θ) = b θ + min x (c − A θ) = . x∈E x>0 −∞ otherwise Since the dual problem is to maximize this expression over θ ∈ Rn , we see immediately that a θ violating A> θ 6 c will never be chosen. Hence the dual to the primal problem (3.12) is (3.13).
3.2.2.6
Strong Duality As shown in §A.7.1 of the appendix, the inequality D 6 P always holds, where P is the primal value in (3.12). This is called weak duality. If P = D, then strong
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
106
Optimal Flows
duality is said to hold. Unlike weak duality, strong duality requires conditions on the primitives. The next theorem states that, for linear programs, strong duality holds whenever a solution exists. A proof can be obtained either through Dantzig’s simplex method or via Farkas’ Lemma. See, for example, chapter 4 of Bertsimas and Tsitsiklis (1997) or chapter 6 of Matousek and Gärtner (2007). theorem 3.2.1 (Strong duality for linear programs) The primal problem (3.12) has a finite minimizer x ∗ if and only if the dual problem (3.13) has a finite maximizer θ∗ . If these solutions exist, then c> x ∗ = b> θ∗ . Strong duality of linear programs has many important roles. Some of these are algorithmic: Duality can be used to devise efficient solution methods for linear programming problems. Another way that duality matters for economists is that it provides deep links between optimality and competitive equilibria, as we show below.
3.2.2.7
Complementary Slackness We say that x ∗ > 0 and θ∗ ∈ Rm satisfy the complementary slackness conditions for the linear program (3.12) when n X θi∗ bi − ai j x ∗j = 0 for all i ∈ [m] (3.15) j=1
x ∗j
cj −
m X
! ai j θi∗
=0
for all j ∈ [n].
(3.16)
i=1
While it is possible to derive these expressions from the complementary slackness in the KKT conditions in §A.7.3, a better approach is to connect them directly to the saddle-point condition. To see how this works, suppose that x ∗ > 0 is feasible for the primal problem, and θ∗ ∈ Rm is feasible for the dual problem. If (x ∗,θ∗ ) is a saddle point of L, then the complementary slackness conditions (3.15)–(3.16) must hold. Indeed, (3.15) is trivial when x ∗ is feasible, since Ax ∗ = b. At the same time, (3.16) must be true because violation implies that ! m X x ∗j c j − ai j θi∗ > 0 for some j ∈ [n], i=1
due to dual feasibility (i.e., A> θ∗ 6 c) and x ∗ > 0. But then (x ∗,θ∗ ) is not a saddle point of L, since changing the j-th element of x ∗ to zero strictly reduces the Lagrangian L(x,θ) = c> x + θ> (b − Ax) = x > (c − A> θ) + θ> b.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
107
By sharpening this argument, it is possible to show that, for linear programs, the complementary slackness conditions are the exact necessary and sufficient conditions for a saddle point of the Lagrangian. This leads to the next theorem. theorem 3.2.2 If x ∗ > 0 is feasible for the primal problem and θ∗ is feasible for the dual problem, then the following statements are equivalent: (i) x ∗ is optimal for the primal problem and θ∗ is optimal for the dual problem. (ii) The pair (x ∗,θ∗ ) obeys the complementary slackness conditions (3.15)–(3.16). Chapter 4 of Bertsimas and Tsitsiklis (1997) provides more discussion and a full proof of Theorem 3.2.2. Below, we illustrate some of the elegant connections between complementary slackness and equilibria in competitive economic environments.
3.2.2.8
The Simplex Algorithm Linear programming is challenging in high-dimensional settings, partly because the linear objective function implies that solutions are not interior. The first efficient solution methods for linear programs appeared in the 1930s and 1940s, starting with the simplex method of Kantorovich and Dantzig. As the simplex method began to prove its worth, linear programming grew into a technique of enormous practical importance. Operations research, communication, and production systems began to make heavy use of linear programs. The simplex algorithm makes use of the following result, which is proved in Theorem 2.7 of Bertsimas and Tsitsiklis (1997). theorem 3.2.3 If the linear program (3.12) has an optimal solution, then it also has an optimal solution that is an extreme point of the feasible set. (An extreme point of a polyhedron was defined in §A.5.1. The feasible set was shown to be a polyhedron in Exercise 3.2.3.) The simplex algorithm makes use of Theorem 3.2.3 by walking along the edges of the polyhedron that forms the feasible set, from one extreme point to another, seeking at each step a new extreme point (which coincides with a vertex of the polyhedron) that strictly lowers the value of the objective function. Details can be found in Bertsimas and Tsitsiklis (1997) and Matousek and Gärtner (2007).
3.3
Optimal Transport Next we turn to optimal flows across networks. One simple – but computationally nontrivial – example of a network flow problem is the linear assignment problem we analyzed in §3.2.1. There, the vertices are either workers or jobs, and the edges are assignments, chosen optimally to minimize aggregate cost. More general network flow problems extend these ideas, allowing endogenous formation of networks in more
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
108
Optimal Flows
sophisticated settings. The general structure is that vertices are given, while edges and weights are chosen to optimize some criterion. There are natural applications of these ideas in trade, transportation, and communication, as well as less obvious applications within economics, finance, statistics, and machine learning. In our study of network flows, we begin with the optimal transport problem, which is the most important special case of the general network flow problem. (In fact, as we show in §3.3.4.3, there exists a technique by which the general network flow problem can always be reduced to an optimal transport problem.)
3.3.1
The Monge–Kantorovich Problem Optimal transport is a classic problem dating back to the work of Gaspard Monge (1746–1818), who studied, among many other things, the transport of earth for the construction of forts. This simple-sounding problem – how to transport a pile of a given shape into a new pile of a given shape at minimum cost – can, after normalization, be identified with the problem of least-cost transformation of one distribution into another distribution. Figure 3.10 gives a visualization of transforming one distribution into another in one dimension (although the cost function is not specified). It turns out that, by varying the notion of cost, this transportation problem provides a highly flexible method for comparing the distance between two distributions, with the essential idea being that distributions are regarded as “close” if one can be transformed into the other at low cost. The resulting distance metric finds wide-ranging and important applications in statistics, machine learning, and various branches of applied mathematics.2 2.5 2.0
transform
1.5 1.0 0.5 0.0 0.5
1.0
1.5
2.0
2.5
3.0
3.5
4.0
Figure 3.10 Transforming distribution ϕ into distribution ψ 2 For example, in image processing, two images might be regarded as close if the cost of transforming one
into the other by altering individual pixels is small. Even now, in image processing and some branches of machine learning, one of the metrics over the set of probability distributions arising from optimal transport methods is referred to as “earth mover’s distance” in honor of the work of Monge.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
109
3.3 Optimal Transport
In economics, optimal transport has important applications in transportation and trade networks, as well as in matching problems, econometrics, finance, and so on (see, e.g., Galichon (2018)). As such, it is not surprising that economists have contributed a great deal to the optimal transport problem, with deep and fundamental work being accomplished by the great Russian mathematical economist Leonid Kantorovich (1912–1986), as well as the Dutch economist Tjalling Koopmans (1910–1985), who shared the Nobel Prize with Kantorovich in 1975 for their work on linear programming and optimal transport.3 We start our discussion with a straightforward presentation of the mathematics. Then, in §3.3.3, we will connect the mathematics to economic problems, and show the deep connections between transport, duality, complementary slackness, and competitive equilibria.
3.3.1.1
Monge’s Formulation We start with the classical problem of Monge, which is simple to explain. We take as given two finite sets X and Y, paired with distributions ϕ ∈ 𝒟(X) and ψ ∈ 𝒟(Y). Elements of X and Y are called locations. To avoid tedious side cases, we assume throughout that ϕ and ψ are strictly positive on their domains. In addition, we are supplied with a cost function c : X × Y → R+ . Our goal is to “transport” ϕ into ψ at minimum cost. That is, we seek to solve X min c(x,T (x)) (3.17) T
x
over the set of all maps T from X onto Y satisfying X ϕ(x)1{T (x) = y} = ψ(y) for all y ∈ Y.
(3.18)
x
The constraint says T must be such that, for each target location y, the sum of all P probability mass sent to y is equal to the specified quantity ψ(y). The symbol x is P short for x∈X . In this context, T is often called a Monge map. Exercise 3.3.1. While we required T to map X onto Y, meaning that every y ∈ Y has some preimage, this condition is already implied by (3.18). Explain why. The problem is easily illustrated in the current discrete setting. Figure 3.11 gives a visualization when locations are enumerated as X = {x1, . . . ,x7 } and Y = {y1, y2, y3, y4 }, with both X and Y being subsets of R2 . For simplicity, ϕ(xi ) is written as ϕi and similarly for ψ(y j ). Vertex size is proportional to probability mass assigned to the vertex. The edges represent one feasible Monge map.
3 The optimal transport problem continues to attract the interest of many brilliant mathematicians and
economists, with two recent Fields Medals being awarded for work on optimal transport. The first was awarded to Cedric Villani in 2010, while the second was to Alessio Figalli in 2018. Note that the Fields Medal is only awarded every four years (unlike the Nobel Prize, which is annual).
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
110
Optimal Flows
ϕ1
ψ2
ϕ6
ϕ5
ψ4
ϕ7
ψ1 ϕ2
ϕ3
ϕ4
ψ3
Figure 3.11 A Monge map transporting ϕ to ψ
Discreteness and lack of convexity in the constraint (3.18) imply that the Monge problem is, in general, hard to solve. Truly fundamental progress had to wait until Kantorovich showed how convexification can greatly simplify the problem. The convexification process requires shifting the problem to a higher-dimensional space, but the cost of higher dimensions is outweighed by the regularization provided by convexity and lack of discreteness. We study the Kantorovich formulation in §3.3.1.3. Exercise 3.3.2. Another issue with the Monge formulation of optimal transport is that existence of a solution can easily fail. Provide an example where no Monge map exists in the setting where X and Y are finite.
3.3.1.2
Assignment as Optimal Transport The linear assignment problem studied in §3.2.1, with cost c(i, j) of training worker i for job j, is a special case of optimal transport. All we have to do is set X = Y = [n] and take ϕ and ψ to be discrete uniform distributions on [n]. Exercise 3.3.3. Show that, in this setting, T is a Monge map if and only if T is a bijection from [n] to itself. Since T must be a bijection on [n], which is also a permutation of [n], the objective of the optimal transport problem under the current configuration is min
T ∈𝒫
n X
c(i,T (i)),
(3.19)
i=1
where 𝒫 is the set of all permutations of [n]. This is the same optimization problem as the linear assignment problem in (3.7).
3.3.1.3
Kantorovich’s Relaxation of the Monge Problem The basic idea in Kantorovich’s relaxation of the Monge problem is to allow mass located at arbitrary x ∈ X to be mapped to multiple locations in Y, rather than just one. This means that we are no longer seeking a function T , since, by definition, a
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
ϕ1
ψ1
ψ2
ϕ3
ϕ6
ϕ5
ψ4
ϕ7 ψ3
ϕ2
111
ϕ4
Figure 3.12 Kantorovich relaxation of the Monge problem
function can map a given point to only one image. Instead, we seek a “transport plan” that sends some fraction π(x, y) of the mass at x to y. The plan is constrained by the requirement that, for all x and y, (i) total probability mass sent to y is ψ(y) and (ii) total probability mass sent from x is ϕ(x). These constraints on this transport plan mean that it takes the form of a “coupling,” which we define below. Figure 3.12 illustrates a feasible transport plan in the discrete setting. As with Figure 3.11, ϕ(xi ) is written as ϕi and similarly for ψ(y j ), while vertex size is proportional to probability mass. Unlike the Monge setting of Figure 3.11, the mass at each vertex ϕi can be shared across multiple ψ j , as long as the constraints are respected. Let’s write the constraints more carefully. We recall that, in probability theory, a coupling is a joint distribution with specific marginals. More precisely, given ϕ in 𝒟(X) and ψ in 𝒟(Y), a coupling of (ϕ,ψ) is an element π of 𝒟(X × Y) with marginals ϕ and ψ. This restriction on marginals means that X π(x, y) = ϕ(x) for all x ∈ X and (3.20) y
X
π(x, y) = ψ(y)
for all y ∈ Y
(3.21)
x
The constraints in (3.20)–(3.21) require that (i) for any x ∈ X, the total amount of probability mass flowing out of x is ϕ(x) and (ii) for any y ∈ Y, the total amount of probability mass flowing into y is ψ(y). In the present setting, a coupling is also called a transport plan. Exercise 3.3.4. The constraints (3.20)–(3.21), which define a coupling π of ϕ and ψ, generalize the Monge constraint in (3.18). To see this, let T be a map satisfying (3.18), and set π(x, y) = ϕ(x)1{T (x) = y}
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
112
Optimal Flows
on X × Y, so that π is the joint distribution that puts all mass on the image of T . Prove that (3.20)–(3.21) both hold. Let 5(ϕ,ψ) be the set of all couplings of ψ and ϕ. Taking ϕ,ψ and the cost function c as given, the general Monge–Kantorovich problem, also called the optimal transport problem, is to solve P := min hc,πi F
subject to
π
π ∈ 5(ϕ,ψ),
(3.22)
where hc,πi F :=
XX x
c(x, y)π(x, y)
y
is the Frobenius inner product of c and π, treated as |X| × |Y| matrices. The sum in hc,πi F measures the total cost of transporting ϕ into ψ under the plan π. There is linearity embedded in this cost formulation, since doubling the amount sent from x to y scales the associated cost at rate c(x, y). We call any π solving (3.22) an optimal plan. Since we are maximizing over a finite set, at least one such plan exists. remark 3.3.1 The problem (3.22) is sometimes expressed in terms of random variables, as follows. In this setting, a coupling π in 5(ϕ,ψ) is identified with a pair of d
d
random elements (X,Y ) such that X = ϕ and Y = ψ. We can then write d
d
P = min E c(X,Y ) subject to (X,Y ) ∈ 𝒟(X × Y) with X = ϕ and Y = ψ. (X,Y )
Exercise 3.3.5. One of the most important features of the Kantorovich relaxation is that, for given ϕ and ψ, the constraint set is convex. To verify this, we let n = |X| and m = |Y|, associate each x ∈ X with some i ∈ [n], associate each y ∈ Y with some j ∈ [m], and treat c and π as n × m matrices, with typical elements ci j and πi j . The constraints are π1m = ϕ
and
π > 1n = ψ,
(3.23)
where 1k is a k × 1 vector of ones. With this notation, prove that the set 5(ϕ,ψ) of π ∈ Mn×m satisfying the constraints is convex, in the sense that π, πˆ ∈ 5(ϕ,ψ) and α ∈ [0,1] H⇒ απ + (1 − α)πˆ ∈ 5(ϕ,ψ).
3.3.1.4
Optimal Transport as a Linear Program With some relatively simple manipulations, the general optimal transport problem can be mapped into a standard equality form linear program. This provides two significant benefits. First, we can apply duality theory, which yields important insights. Second, on the computational side, we can use linear program solvers to calculate optimal plans.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
113
3.3 Optimal Transport
To map the optimal transport problem into a linear program, we need to convert matrices into vectors. We will use the vec operator, which takes an arbitrary A ∈ Mn×m and maps it to a vector in Rnm by stacking its columns vertically. For example, a11 ! a a11 a12 21 vec = . a12 a21 a22 a22 In this section we adopt the notational conventions in Exercise 3.3.5. The objective function hc,πi F for the optimal transport problem can now be expressed as vec(c)> vec(π). To rewrite the constraints in terms of vec(π), we use the Kronecker product, which is denoted by ⊗ and defined as follows. Suppose A is an m × s matrix with entries (ai j ) and that B is an n × t matrix. The Kronecker product A ⊗ B of A and B is the mn × st matrix, defined, in block matrix form, by a11 B a12 B . . . a1s B a21 B a22 B . . . a2s B . A⊗B = .. . am1 B
am2 B . . .
ams B
It can be shown that Kronecker products and the vec operator are connected by the following relationship: For conformable matrices A, B, and M, we have vec(AM B) = (B > ⊗ A) vec(M).
(3.24)
Using (3.24) and the symbol Ik for the k × k identity matrix, we can rewrite the first constraint in (3.23) as ϕ = In π1m = vec(In π1m ) = (1> m ⊗ In ) vec(π).
(3.25)
Exercise 3.3.6. Show that the second constraint in (3.23) can be expressed as ψ = (Im ⊗ 1> n ) vec(π). Now, using block matrix notation and setting ! 1> m ⊗ In A := and b := Im ⊗ 1> n
(3.26)
! ϕ , ψ
the optimal transport problem can be expressed as the standard equality form linear program min vec(c)> x x
over x ∈ Rnm + such that Ax = b.
(3.27)
Finally, for a given solution x, the transport plan is recovered by inverting x = vec(π).
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
114
Optimal Flows
3.3.1.5
Implementation Listing 1 is a function that implements the above steps, given flat (one-dimensional) arrays phi and psi representing the distributions over the source and target locations, plus a two-dimensional array c representing transport costs. (The method argument highs-ipm tells linprog to use a particular interior point method, details of which can be found in the linprog documentation. Simplex and other methods give similar results.) import numpy as np from scipy.optimize import linprog def ot_solver(phi, psi, c, method=’highs-ipm’): """ Solve the OT problem associated with distributions phi, psi and cost matrix c. Parameters ---------phi : 1-D array Distribution over the source locations. psi : 1-D array Distribution over the target locations. c : 2-D array Cost matrix. """ n, m = len(phi), len(psi) # Vectorize c c_vec = c.reshape((m * n, 1), order=’F’) # Construct A and b A1 = np.kron(np.ones((1, m)), np.identity(n)) A2 = np.kron(np.identity(m), np.ones((1, n))) A = np.vstack((A1, A2)) b = np.hstack((phi, psi)) # Call solver res = linprog(c_vec, A_eq=A, b_eq=b, method=method) # Invert the vec operation to get the solution as a matrix pi = res.x.reshape((n, m), order=’F’) return pi
Listing 1: Function to solve a transport problem via linear programming
Notice that in Listing 1, the reshape order is specified to F. This tells NumPy to reshape with Fortran column-major order, which coincides with the definition of the vec operator described in §3.3.1.4. (The Python vectorize operation defaults to rowmajor order, which concatenates rows rather than stacking columns. In contrast, Julia uses column-major by default.)
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
Let’s call this function for the very simple problem ! ! 0.5 1 1 ϕ= , ψ= , and c = 0.5 0 1
115
! 1 . 1
With these primitives, all mass from ϕ1 and ϕ2 should be sent to ψ1 . To implement this problem, we set phi = np.array((0.5, 0.5)) psi = np.array((1, 0)) c = np.ones((2, 2)) and then call ot_solver via ot_solver(phi, psi, c) The output is as expected: array([[0.5, 0. ], [0.5, 0. ]])
3.3.1.6
Python Optimal Transport In the case of Python, the steps above have been automated by the Python Optimal Transport (POT) package, due to Flamary et al. (2021). For the simple problem from §3.3.1.5, we run import ot ot.emd(phi, psi, c)
# Use simplex method via the emd solver
The output is again equal to array([[0.5, 0. ], [0.5, 0. ]])
Figure 3.13 shows an example of an optimal transport problem solved using the POT package. The interpretation is similar to Figure 3.12, although the number of vertices is larger. In addition, the edges show the optimal transport configuration, in the sense that π ∗ , the optimal transport plan, is treated as the adjacency matrix for the graph. (The figure shows the unweighted graph, with an arrow drawn from ϕi to ψ j whenever πi∗j > 0.) The optimal transport plan is obtained by converting the transport problem into a linear program, as just described, and applying the simplex method. Although there are 32 nodes of each type, the problem is solved by the simplex routine in less than 1 millisecond.
3.3.1.7
Kantorovich Relaxation and Linear Assignment We showed in §3.3.1.2 that the linear assignment problem studied in §3.2.1 is a special case of optimal transport, where ϕ and ψ become discrete uniform distributions on [n]. Moreover, as we have just seen, Kantorovich’s relaxation method allows us to apply linear programming. This leads to fast solutions.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
116
Optimal Flows
Figure 3.13 An optimal transport problem solved by linear programming
In the discussion in §3.2.1 we used n = 40. Let’s start here with n = 4, to illustrate the method, and then try with n = 40. The matrix c(i, j) of costs, which is the only other primitive, will be generated randomly as an independent array of uniform random variables. Then we apply the POT library, as in §3.3.1.6.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
117
Here is our set up: import numpy as np import ot n = 4 phi = np.ones(n) psi = np.ones(n) We have broken the rule that ϕ and ψ should sum to one. This could be fixed easily by using np.ones(n)/n instead of np.ones(n), but the POT library does not care (as long as np.sum(phi) equals np.sum(psi)), and, moreover, the idea of putting unit mass everywhere is natural, since each element of ϕ represents one worker, and each element of ψ represents one job. Now we build the cost matrix: c = np.random.uniform(size=(n, n)) The output is array([[0.03841, [0.91527, [0.96275, [0.40454,
0.32896, 0.24566, 0.44089, 0.87307,
0.55989, 0.26022, 0.79274, 0.43555,
0.41682], 0.64510], 0.93065], 0.54903]])
(For example, the cost of retraining worker 1 for job 2 is 0.32896.) Finally, we call the solver: ot.emd(phi, psi, c) The output is array([[1., [0., [0., [0.,
0., 0., 1., 0.,
0., 1., 0., 0.,
0.], 0.], 0.], 1.]])
This is a permutation matrix, which provides another way to express a permutation of [n]. The first row tells us that worker 1 is assigned to job 1, the second tells us that worker 2 is assigned to job 3, and so on. If we now set n = 40 and rerun the code. The line ot.emd(phi, psi, c), which calls the simplex-based solver, runs in less than 1 millisecond on a mid-range laptop. This is a remarkable improvement on the 2.5× 1030 -year estimate for the brute force solver we obtained in §3.2.1.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
118
Optimal Flows
3.3.1.8
Tight Relaxation Notice that the solution we obtained for the linear assignment problem using the simplex method does not split mass, as permitted by the Kantorovich relaxation. For example, we do not send half of a worker to one job and the other half to another. This is convenient, but why does it hold? While we omit the details, the basic idea is that a general Kantorovich transport plan is a bistochastic matrix, and all such matrices can be formed as convex combinations of permutation matrices. (This is called Birkhoff’s theorem.) In other words, the permutation matrices are extreme points of the set of bistochastic matrices. Moreover, Theorem 3.2.3 tells us that any optimizer of a linear program will be an extreme point – in this case, a permutation matrix.
3.3.2
Kantorovich Duality One of the greatest achievements of Kantorovich was to show that the optimal transport problem can be connected to a dual problem, and how that dual problem can be used to characterize solutions. This work anticipated much of the later development of duality theory for arbitrary linear programs. Throughout this section, in stating the main results, we use the notation
X f ,ϕ = f (x)ϕ(x)
for f ∈ RX and ϕ ∈ 𝒟(X).
x
This is just the usual inner product, when we think of f and ϕ as vectors in R|X| . Also, given a cost function c on X × Y, let ℱc be all pairs (w, p) in RX × RY such that p(y) 6 c(x, y) + w(x) on X × Y.
(3.28)
One part of Kantorovich’s duality results runs as follows. theorem 3.3.1 For all ϕ ∈ 𝒟(X) and ψ ∈ 𝒟(Y), we have P = D, where D := max
(w, p)
p,ψ − w,ϕ
subject to (w, p) ∈ ℱc .
(3.29)
Theorem 3.3.1 can now be understood as a special case of the more general result that strong duality holds for linear programs, which we stated in Theorem 3.2.1. In that spirit, let us verify Theorem 3.3.1 using Theorem 3.2.1, by working with the linear programming formulation of the optimal transport problem provided in §3.3.1.4. To do this, we take that formulation, which is stated in (3.27), and apply the dual formula in (3.13), which yields D = max
θ∈Rn+m
ϕ ψ
!> θ subject to
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
1> m ⊗ In I m ⊗ 1> n
!> θ 6 vec(c).
3.3 Optimal Transport
119
If we write the argument θ ∈ Rn+m as (−w, p), so that we now maximize over the two components −w ∈ Rn and p ∈ Rm , as well as transposing the constraint, we get n o > > > max p > ψ − w> ϕ subject to p > (Im ⊗ 1> n ) − w (1m ⊗ In ) 6 vec(c) , w, p
where w ∈ Rn and p ∈ Rm . By using the definition of the Kronecker product and carefully writing out the individual terms, it can be shown that the constraint in this expression is equivalent to requiring that p j − wi 6 ci j for all (i, j) ∈ [n] × [m]. Recalling that X has been mapped to [n] and Y has been mapped to [m]; this is exactly the same restriction as (3.28). At this point it is clear that (3.29) is nothing but the dual of the linear program formed from the optimal transport problem. The claims in Theorem 3.3.1 now follow directly from the strong duality of linear programs (Theorem 3.2.1). Exercise 3.3.7. Show that
hc,πi > p,ψ − w,ϕ whenever π ∈ 5(ϕ,ψ) and (w, p) ∈ ℱc .
(3.30)
Use this fact to provide a direct proof that weak duality holds for the optimal transport problem, in the sense that D 6 P. (Here P is defined in the primal problem (3.22), and D is defined in the dual problem (3.29).)
3.3.3
Optimal Transport and Competitive Equilibria The other major achievement of Kantorovich in the context of duality theory for optimal transport was to connect optimality of transport plans with the existence of functions w, p from the dual problem such that a version of the complementary slackness conditions holds. Here we present this result, not in the original direct formulation but rather through the lens of a competitive equilibrium problem. In doing so, we illustrate some of the deep connections between prices, decentralized equilibria, and efficient allocations.
3.3.3.1
The Advisor’s Problem We imagine the following scenario. Iron is mined at a finite collection of sites, which we denote by X. We identify an element x ∈ X with a point (a,b) ∈ R2 , which can be understood as the location of the mine in question on a map. At the wish of the queen, who seeks to defend the empire from greedy rivals, this iron is converted to swords by blacksmiths. There are a number of talented blacksmiths in this country, located at sites given by Y. As for X, each y ∈ Y indicates a point in R2 . Henceforth, we refer to “mine x” rather than “the mine at x,” and so on. Each month, mine x produces ϕ(x) ounces of iron ore, while blacksmith y consumes ψ(y) ounces. We take these quantities as fixed. We assume that total supply
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
120
Optimal Flows
P P equals total demand, so that x ϕ(x) = y ψ(y). For convenience, we normalize this sum to unity. As a result, ϕ and ψ are elements of 𝒟(X) and 𝒟(Y), respectively. The cost of transporting from x to y is known and given by c(x, y) per ounce. The queen’s chief advisor is tasked with allocating and transporting iron from the mines to the blacksmiths, such that each blacksmith y receives their desired quantity ψ(y), at minimum cost. A small amount of thought will convince you that the advisor’s problem is a version of the optimal transport problem (3.22). We call this the primal problem in what follows. Operating in the days before Kantorovich, Dantzig, and the electronic computer, the advisor employs a large team of bean counters, instructing them to find the allocation with least cost by trying different combinations. However, after a few days, she realizes the futility of the task. (With infinite divisibility, which corresponds to our mathematical model, the number of allocations is infinite. If we replace infinite divisibility with a finite approximation, the scale can easily be as large as that of the matching problem discussed in §3.2.1, with only a moderate number of mines and blacksmiths.)
3.3.3.2
The Guild’s Problem At this point she has another idea. There is a guild of traveling salespeople, who buy goods in one town and sell them in another. She seeks out the guild master and asks him to bid for the project along the following lines. The guild will pay the queen’s treasury w(x) per ounce for iron ore at mine x. It will then sell the iron at price p(y) per ounce to the queen’s representative at blacksmith y. The difference can be pocketed by the guild, as long as all blacksmiths are provided with their desired quantities. The guild master is asked to propose price functions w and p. The guild master sees at once that p and w must satisfy p(y) − w(x) 6 c(x, y) at each x, y, for otherwise the advisor, who is no one’s fool, will see immediately that money could be saved by organizing the transportation herself. Given this conP straint, the guild master seeks to maximize aggregate profits, which is y p(y)ψ(y)− P x w(x)ϕ(x). At this point it will be clear to you that the problem of the guild master is exactly that of Kantorovich’s dual problem, as given in Theorem 3.3.1. Since the advisor has given up on her team of bean counters, the guild master employs them and asks them to produce the optimal pair of prices. The bean counters set to work, trying different combinations of prices that satisfy the constraints. However, without a systematic methodology to follow or fast computers to turn to, their progress is slow. The advisor begins to fear that the coming war will be over before the guild master replies.
3.3.3.3
Decentralized Equilibrium At this point, it occurs to the advisor that yet another approach exists: privatize the mines, abolish the guild, and let the traveling salespeople, mine owners, and blacksmiths make individual choices in order to maximize their profits. Purchase and sales
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
121
prices, as well as quantities transported from each mine to each blacksmith, will be determined by the free market. Although the advisor predates Kantorovich, she reasons that competition will prevent each salesperson from profiteering, while the desire for profits will encourage high levels of transportation and minimal waste. It turns out that this idea works amazingly well, in the sense that we now describe. For the record, we define a competitive equilibrium for this market as a pair of price vectors (w, p) in RX × RY and a set of quantities π : X × Y → R+ such that the following three conditions hold: For all (x, y) in X × Y, X X π(x,v) = ϕ(x) and π(u, y) = ψ(y) (RE) v∈Y
u∈X
p(y) 6 c(x, y) + w(x) p(y) = c(x, y) + w(x) whenever π(x, y) > 0.
(NA) (IC)
Condition (RE) is a resource constraint that builds in the assumption that no ore is wasted or disposed. Condition (NA) imposes no arbitrage. If it is violated along route (x, y), then another salesperson, of which we assume there are many, will be able to gain business without suffering losses by offering a slightly higher purchase price at x or a slightly lower sales price at y. Finally, condition (IC) is an incentive constraint, which says that, whenever a route is active (in the sense that a nonzero quantity is transported), prices are such that the salespeople do not lose money. We do not claim that a competitive equilibrium will hold immediately and at every instant in time. However, we reason, as the advisor does, that competitive equilibrium has natural stability properties, as described in the previous paragraph. As such, we predict it as a likely outcome of decentralized trade, provided that private property rights are enforced (e.g., bandits are eliminated from the routes) and noncompetitive behaviors are prevented (e.g., collusion by mine owners is met by suitably painful punishments). Taking c, ϕ, and ψ as given, we can state the following key theorem, which states that any competitive equilibrium simultaneously solves both the advisor’s quantity problem and the guild master’s price problem. theorem 3.3.2 then
If prices (w, p) and π ∈ Mn×m form a competitive equilibrium,
(i) π is an optimal transport plan, solving the primal problem (3.22); and (ii) (w, p) solves the Kantorovich dual problem (3.29). To prove the theorem, we will use the results from the next exercise. Exercise 3.3.8. Let A and B be nonempty sets. Let f and g be real-valued on A and B such that f (a) > g(b) for all (a,b) ∈ A × B, and, in addition, mina∈A f (a) = maxb∈B g(b). Prove the following statement: If there exist a¯ ∈ A and b¯ ∈ B such that ¯ then a¯ is a minimizer of f on A, and b¯ is a maximizer of g on B. f (a) ¯ = g(b),
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
122
Optimal Flows
We will use Exercise 3.3.8 in the following way. Let A = 5(ϕ,ψ) and B = ℱc . Let f be the value of the primal and g be the value of the dual. By (3.30), the ordering f (π) > g(w, p) holds over all feasible π ∈ A and (w, p) ∈ B pairs. By strong duality, we also have minπ∈A f (π) = max(w, p)∈B g(w, p). Hence we need only show that, when (w, p) and π form a competitive equilibrium, we have f (π) = g(w, p). Proof of Theorem 3.3.2 Suppose that (w, p) and π form a competitive equilibrium. From (RE) we know that π is feasible for the primal problem. From (NA) we know that (w, p) is feasible for the dual. Since the equality in the (IC) condition holds when π(x, y) > 0, we can multiply both sides of this equality by π(x, y) and sum over all x, y to obtain X X X c(x, y)π(x, y) = p(y)ψ(y) − w(x)ψ(x). (3.31) x, y
y
x
The result of Exercise 3.3.8 now applies, so π attains the minimum in the primal problem, and (w, p) attains the maximum in the dual. We also have the following converse: theorem 3.3.3 If π is an optimal transport plan, then there exists a pair (w, p) ∈ RX × RY such that the quantities determined by π and the prices in (w, p) form a competitive equilibrium. Proof Let π be an optimal plan. To be optimal, π must be feasible, so π ∈ 5(ϕ,ψ), which implies that (RE) holds. By Kantorovich’s duality theorem (Theorem 3.3.1), we can obtain (w, p) ∈ ℱc such that (3.31) holds. Since (w, p) ∈ ℱc , (NA) holds. From (NA) we have c(x, y) + w(x) − p(y) > 0 for all x, y. From this and (3.31) we see that (IC) must be valid. We conclude that π and (w, p) form a competitive equilibrium.
3.3.4
The General Flow Problem We now describe a general network flow problem that can be used to analyze a large range of applications, from international trade to communication and assignment. This general problem includes optimal transport as a special case. Once we have introduced the problem, we show two results. First, the problem can easily be formulated as a linear program and solved using standard linear programming methods. Second, even though optimal transport is a strict subset of the general flow problem, every general flow problem can be solved using a combination of optimal transport and shortest path methods.
3.3.4.1
Problem Statement We are interested in the flow of a good or service across a network with n vertices. This network can be understood as a weighted directed graph (V , E,c). To simplify
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
123
Figure 3.14 The Silk Road (Source: Wikimedia Commons)
notation, we label the nodes from 1 to n and let V = [n]. Existence of an edge e = (i, j) ∈ E with weight c(i, j) indicates that the good can be shipped from i to j at cost c(i, j). We recall from §1.4.1 that ℐ(i) is the set of direct predecessors of vertex i (all u ∈ V such that (u,i) ∈ E) and 𝒪(i) is the set of direct successors (all j ∈ V such that (i, j) ∈ E). A classic example is the famous Silk Road of antiquity, part of which is illustrated in Figure 3.14. Silk was produced in Eastern cities such as Loyang and Changan, and then transported westward to satisfy final demand in Rome, Constantinople, and Alexandria. Towns such as Yarkand acted as trade hubs. Rather than covering the whole route, traders typically traveled backward and forward between one pair of hubs, where they knew the language and customs.4 Returning to the model, we allow for both initial supply of and final demand for the good at every node (although one or both could be zero). Let s(i) and d(i) be supply and demand at node i, respectively. Aggregate supply and demand over the network are assumed to be equal, so that X X s(i) = d(i). (3.32) i∈V
i∈V
This can be understood as an equilibrium condition: Prices have adjusted to equalize initial supply and final demand in aggregate. We assume throughout that the vectors s and d are nonnegative with at least one positive element.
4 Our use of the Silk Road as an example of a network flow problem is not original. Galichon (2018)
provides a highly readable treatment in the context of optimal transport.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
124
Optimal Flows
Let q(i, j) be the amount of the good shipped from node i to node j for all i, j ∈ V . The minimum cost network flow problem is to minimize total shipping cost XX c(i, j)q(i, j), (3.33) i∈V j∈V
subject to the restriction that q > 0 and X X s(i) + q(v,i) = d(i) + q(i, j) v∈ℐ(i)
for all i ∈ V .
(3.34)
j∈𝒪(i)
The left-hand side of (3.34) is total supply to node i (initial supply plus inflow from other nodes), while the right-hand side is total demand (final demand plus outflow to other nodes). Exercise 3.3.9. Although we presented them separately, the node-by-node restriction (3.34) implies the aggregate restriction (3.32). Explain why this is the case.
3.3.4.2
Optimality There are several ways to transform the network flow problem into a linear program. We follow the presentation in Bertsimas and Tsitsiklis (1997). We take m = |E| to be the total number of edges and enumerate them (in any convenient way) as e1, . . . ,em . Let’s say that ek leaves node i if ek = (i, j) for some j ∈ [n], and that ek enters node i if ek = (`,i) for some ` ∈ [n]. Then we define the n × m node–edge incidence matrix A by if ek leaves i 1 A = (aik ) with aik := −1 if ek enters i 0 otherwise. Example 3.3.1: Consider the very simple minimum cost flow problem in Figure 3.15. The shipment costs c(i, j) are listed next to each existing edge. Initial supply is 10 at node 1 and zero elsewhere. Final demand is 10 at node 4 and zero elsewhere. We enumerate the edges as E = {e1, . . . ,e4 } = {(1,2),(1,4),(2,3),(3,4)}.
(3.35)
The node–edge incidence matrix is
1 1 0 0 −1 0 1 0 A= . 0 0 −1 1 0 −1 0 −1
Now, returning to the general case, we rearrange q and c into m ×1 vectors (qk ) and (ck ), where qk is the amount shipped along edge k, and ck is the cost. For example, if
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
3.3 Optimal Transport
125
s1 = 10 1 4
1 2 1
4
d4 = 10
1 3
Figure 3.15 A simple network flow problem
ek = (i, j), then qk = q(i, j) and ck = c(i, j). In addition, we set b to be the vector in Rn with i-th element s(i) − d(i), which is net exogenous supply at node i. Exercise 3.3.10. In this set up, show that (3.34) is equivalent to Aq = b in the special case of Example 3.3.1. Exercise 3.3.11. Let (Aq)(i) be the i-th row of Aq. Show that X X (Aq)(i) = q(i, j) − q(v,i). j∈𝒪(i)
(3.36)
v∈ℐ(i)
Equation (3.36) tells us that the i-th row of Aq give us the net outflow from node i P under the transport plan q. Now, with hc,qi := m k=1 ck qk , the minimum cost network flow problem can now be expressed as min hc,qi
s.t.
q > 0 and Aq = b.
(3.37)
This is a linear program in standard equality form, to which we can apply any linear programming solver. For Example 3.3.1, we run the following: A = (( 1, 1, 0, 0), (-1, 0, 1, 0), ( 0, 0, -1, 1), ( 0, -1, 0, -1)) b = (10, 0, 0, -10) c = (1, 4, 1, 1) result = linprog(c, A_eq=A, b_eq=b, method=’highs-ipm’) print(result.x)
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
126
Optimal Flows
The output is [10. 0. 10. 10.]. Recalling the order of the paths in (3.35), this means that the optimal transport plan is q(1,4) = 0 and q(1,2) = q(2,3) = q(3,4) = 10, as our intuition suggests. Exercise 3.3.12. Some network flow problems have capacity constraints, which can be modeled as a map g : E → [0,∞], along with the restriction q(e) 6 g(e) for all e ∈ E. (If g(e) = +∞, there is no capacity constraint over shipping on edge e.) Formulate this as a linear program, and modify the code above, which solves Example 3.3.1, to include the capacity constraint g(1,2) = 5. Solve for the optimal plan. Exercise 3.3.13. Explain how the generic optimal transport problem treated in §3.3.1 is a special case of the minimum cost network flow problem.
3.3.4.3
Reduction to Optimal Transport In Exercise 3.3.13, we saw how every optimal transport problem is a special kind of minimum cost network flow problem. There is a sense in which the converse is also true. In particular, we can use optimal transport methods to solve any network flow problem, provided that we first modify the network flow problem via an application of shortest paths. To explain how this works, we take the abstract network flow problem described in §3.3.4.1, on the weighted digraph (V , E,c), with V = [n], initial supply vector s ∈ Rn+ and final demand vector d ∈ Rn+ . For the purposes of this section, we agree to call a node i with s(i) − d(i) > 0 a net supplier. A node i with d(i) − s(i) > 0 will be called a net consumer. Nodes with s(i) = d(i) will be called trading stations. Example 3.3.2: In the left-hand side of Figure 3.16, nodes 1 and 2 are net suppliers, 3 is a trading station, and 4 and 5 are net consumers.
Example 3.3.3: In the Silk Road application, Rome would be a net consumer, where final demand is large and positive, while initial supply is zero. A city such as Yarkand should probably be modeled as a trading station, with s(i) = d(i) = 0.
1
5
1
4
3
1 3
3
1 2
1
4 2
1 5
2
2
Figure 3.16 Reducing minimum cost optimal flow to optimal transport
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
5
127
3.4 Chapter Notes
The idea behind the reduction is to treat the net supplier nodes as source locations and the net consumer nodes as target locations in an optimal transport problem. The next step is to compute the shortest path (if there are multiple paths, pick any one) from each net supplier i to each net consumer j. Let ρ(i, j) denote this path, represented as a sequence of edges in E. The cost of traversing ρ(i, j) is c(i, ˆ j) :=
m X
ck 1{ek ∈ ρ(i, j)}.
k=1
Now the trading stations are eliminated, and we solve the optimal transport problem with X = the set of net suppliers, Y = the set of net consumers, ϕ(i) = s(i) − d(i) on X, ψ( j) = d( j) − s( j) on Y, and cost function c(i, ˆ j) as defined above.5
• • • • •
After we find the optimal transport plan π, the network minimum cost flow qk along arbitrary edge ek ∈ E is recovered by setting XX qk = π(i, j)1{ek ∈ the shortest path from i to j}. i∈X j∈Y
P
Exercise 3.3.14. Recalling our assumptions on s and d, prove that j∈Y ψ( j) and that this sum is nonzero.
P
i∈X
ϕ(i) =
P P remark 3.3.2 We have not imposed i ϕ(i) = j ψ( j) = 1, as required for the standard formulation of the optimal transport problem. But this normalization is only used for convenience in exposition, and most solvers do not require it. Figure 3.16 illustrates the method. Trading station 3 is eliminated after the shortest paths are computed.
3.4
Chapter Notes Our treatment of shortest paths can be understood as a simplified version of both the Bellman–Ford algorithm and Dijkstra’s algorithm, which are routinely used to solve large shortest path planning problems. Our approach is intended to emphasize recursive solution methods, which are valuable for analyzing a vast range of economic problems, from intertemporal modeling (see, e.g., Lucas and Stokey (1989) or Ljungqvist and Sargent (2018)) to production chains (Kikuchi et al., 2021). 5 If no path exists from i to j, then we set c(i, ˆ j) = ∞. Such settings can be handled in linear
programming solvers by adding capacity constraints. See, for example, Peyré et al. (2019), section 10.3.
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
128
Optimal Flows
Betweenness centrality has been used to quantify the notion of “too connected to fail,” which gained attention after the 2007–2008 global financial crisis. For example, Huang et al. (2016) examine how betweenness centrality affects systemic risk. Betweenness centrality is used to examine liquidity shocks in the inter-bank market by Chiu et al. (2020). Relatedly, Yun et al. (2019) propose a measure of “too central to fail” based on the PageRank algorithm. For a more in-depth treatment of linear programming, we recommend the excellent textbooks by Bertsimas and Tsitsiklis (1997) and Matousek and Gärtner (2007). For bedtime reading, Cook (2011) provides an entertaining introduction to some of the main ideas and applications to network problems, including a review of computation. While §3.2.1 provided a rather whimsical introduction to matching and assignment problems, such problems have great real world importance. Examples include assigning kidney donors to recipients, mothers to maternity wards, doctors to hospitals, students to schools, delivery drivers to orders, and autonomous vehicles to riders.6 A brief history of assignment, matching problems, and combinatorial optimization can be found in Schrijver (2005). Greinecker and Kah (2021) study the existence of stable matchings in a setting with many agents. Villani (2008) and Vershik (2013) provide extensive historical background on the optimal transport problem. Vershik (2013) mentions some of the problems that Kantorovich faced, as a Soviet mathematician working in the time of Stalin and Khrushchev, given that his main duality theorem for optimal transport can be seen as a proof that competitive market equilibria attain the maximal transport plan. In §3.3.2, we mentioned that Kantorovich’s work anticipated much of the later development of duality theory for arbitrary linear programs. In fact, according to Vershik (2013), Kantorovich anticipated much of the general theory of linear programming itself, including providing a version of the simplex algorithm later rediscovered and extended by Dantzig. Optimal transport has a remarkably wide variety of applications, spread across economics, econometrics, finance, statistics, artificial intelligence, machine learning, and other fields. Within economics, Galichon (2018) provides an excellent overview. Charpentier et al. (2019) and Fajgelbaum and Schaal (2020) consider optimal transport in spatial equilibria. Ocampo (2022) applies optimal transport measures to the study of tasks and occupations. Beiglböck et al. (2022) review some of the major milestones of modern finance theory and show their connections via optimal transport. Connections to machine learning are surveyed in Kolouri et al. (2017). The computational theory of optimal transport is now a major field. A high-quality exposition can be found in Peyré et al. (2019). Blanchet et al. (2018) use computational optimal transport to solve for Cournot–Nash equilibria in mean-field-type games.
6 The latter problem occurs in the field of autonomous mobility on demand (AMoD). See, for example,
Ascenzi and Palanza (2021) or Simonetto et al. (2019).
https://doi.org/10.1017/9781009456340.005 Published online by Cambridge University Press
4
Markov Chains and Networks
Markov chains evolving on finite sets are a foundational class of stochastic processes. These processes have been employed in quantitative economics to study stochastic systems ranging from labor income to harvest outputs, firm productivity, stock prices, unemployment dynamics, policy regimes, interest rates, and social mobility. Fortunately, we are now well placed to study Markov chains, since such chains are most naturally viewed as a special kind of weighted digraph. Moreover, graph-theoretic properties such as connectedness and periodicity are key determinants of their dynamics. In this chapter we investigate these ideas.
4.1
Markov Chains as Digraphs We begin with fundamental definitions and then investigate dynamics.
4.1.1
Markov Models A finite Markov model is a weighted directed graph ℳ = (S, E, p), where S is the (finite) set of vertices, E is the set of edges, and p is the weight function, with the additional restriction that X p(x, y) = 1 for all x ∈ S. (4.1) y ∈ 𝒪(x)
Figure 1.15 on page 32 presented an example of such a digraph. The set of vertices S of a finite Markov model ℳ = (S, E, p) is also called the state space of the model, and vertices are called states. The two standard interpretations are (i) S is a set of possible states for some random element (the state), and the weight p(x, y) represents the probability that the state moves from x to y in one step. (ii) S is a set of possible values for some measurement over a large population (e.g., hours worked per week measured across a large cross-section of households), and p(x, y) is the fraction of agents that transition from state x to state y in one unit of time. These two perspectives are related in ways that we explore below.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
130
Markov Chains and Networks
4.1.1.1
Transition Matrices If ℳ is a finite Markov model, then the restriction (4.1) is equivalent to the statement that the adjacency matrix associated with ℳ is stochastic (see §1.3.1.3 for the definition). Identifying S = {poor,middle,rich} with {1,2,3}, the adjacency matrix for this weighted digraph is 0.9 0.1 0.0 Pa = 0.4 0.4 0.2 . (4.2) 0.1 0.1 0.8 Since Pa > 0 and rows sum to unity, Pa is stochastic as required. In the context of finite Markov models, the adjacency matrix of ℳ is also called the transition matrix. Regarding notation, when S has typical elements x, y, it turns out to be convenient to write elements of the transition matrix P as P(x, y) rather than Pi j or similar. We can think of P as extending the weight function p from E to the set of all (x, y) pairs in S × S, assigning zero whenever (x, y) ∈ / E. As such, for every possible choice of (x, y), the value P(x, y) represents the probability of transitioning from x to y in one step. The requirement that P is stochastic can now be written as P > 0 and X P(x, y) = 1 for all x ∈ S. (4.3) y∈S
The restriction in (4.3) just says that the state space is “complete”: after arriving at x ∈ S, the state must now move to some y ∈ S. Using notation from §1.3.1, to say that P is stochastic is the same as requiring that each row of P is in 𝒟(S). Example 4.1.1: A Markov model is estimated in the international growth dynamics study of Quah (1993). The state is real GDP per capita in a given country relative to the world average. Quah discretizes the possible values to 0–1/4, 1/4–1/2, 1/2–1, 1–2, and 2–∞, calling these states 1 to 5, respectively. The transitions are over a one-year period. Estimated one-step transition probabilities are represented as a weighted digraph in Figure 4.1, where • S = {1, . . . ,5} is the state space; • the set of edges E is represented by arrows; and • transition probabilities are identified with weights attached to these edges.
0.97
0.92
0.92 0.03
1
0.03 3
2 0.05
0.04
0.99
0.94 0.04
0.02 5
4 0.04
Figure 4.1 Cross-country GDP dynamics as a digraph
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
0.01
131
4.1 Markov Chains as Digraphs
0.97
0.90
0.89 0.03
1
0.06 3
2 0.05
0.05
0.99
0.90 0.05
0.04 5
4 0.06
0.01
Figure 4.2 Cross-country GDP dynamics as a digraph, updated data
The transition matrix for the Markov model in Example 4.1.1 is 0.97 0.03 0.00 0.00 0.00 0.05 0.92 0.03 0.00 0.00 PQ = 0.00 0.04 0.92 0.04 0.00 . 0.00 0.00 0.04 0.94 0.02 0.00 0.00 0.00 0.01 0.99
(4.4)
Note the large values on the principal diagonal of PQ . These indicate strong persistence: The state stays constant from period to period with high probability. Quah (1993) estimated PQ by maximum likelihood, pooling transitions over the years 1960–1984. (In this case, maximum likelihood estimation amounts to recording the relative frequency of transitions between states.) Figure 4.2 shows how the numbers change if we repeat the exercise using World Bank GDP data from 1985–2019. The numbers are quite stable relative to the earlier estimate. Below we will examine how long-run predictions are affected. As another example, Benhabib et al. (2019) estimate the following transition matrix for intergenerational social mobility: 0.222 0.222 0.215 0.187 0.081 0.038 0.029 0.006 0.221 0.22 0.215 0.188 0.082 0.039 0.029 0.006 0.207 0.209 0.21 0.194 0.09 0.046 0.036 0.008 0.198 0.201 0.207 0.198 0.095 0.052 0.04 0.009 (4.5) PB := 0.175 0.178 0.197 0.207 0.11 0.067 0.054 0.012 0.2 0.205 0.106 0.062 0.05 0.011 0.182 0.184 0.123 0.125 0.166 0.216 0.141 0.114 0.094 0.021 0.084 0.084 0.142 0.228 0.17 0.143 0.121 0.028 Here the states are percentiles of the wealth distribution. In particular, with the states represented by 1,2, . . . ,8, the corresponding percentiles are 0–20%, 20–40%, 40–60%, 60–80%, 80–90%, 90–95%, 95–99%, 99–100% . Transition probabilities are estimated from US 2007–2009 Survey of Consumer Finances data. Relative to the highly persistent matrix PQ , less weight on the principal diagonal suggests more mixing – the influence of initial conditions is relatively shortlived.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
132
Markov Chains and Networks
8
7
state at time t+ 1
6
5
4
3
2
1 1
2
3
4
5
6
7
8
state at time t Figure 4.3 Contour plot of transition matrix PB
Additional insight about the dynamics can be obtained from a contour plot of the matrix PB , as in Figure 4.3. Here PB is plotted as a heat map after rotating it 90 degrees anticlockwise. The rotation is so that the dynamics are comparable to the 45-degree diagrams often used to understand discrete time dynamic systems. A vertical line from state x corresponds to the next period conditional distribution P(x,·). In this case, we see that, for example, lower states are quite persistent, whereas households in the highest state tend to fall back toward the middle. Exercise 4.1.1. Let ℳ be a finite Markov model with state space S and transition matrix P. Show that U ⊂ S is absorbing (see §1.4.1.3) for the digraph ℳ if and only if X
P(x, y) = 1
for all
x ∈ U.
(4.6)
y∈U
4.1.1.2
Markov Chains Consider a finite Markov model ℳ with state space S and transition matrix P. As before, P(x, y) indicates the probability of transitioning from x to y in one step. Another way to say this is that, when in state x, we update to a new state by choosing it from S via the distribution P(x,·). The resulting stochastic process is called a Markov chain.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.1 Markov Chains as Digraphs
133
We can state this more formally as follows. Let (X t )t∈Z+ be a sequence of random variables taking values in S. We say that (X t ) is a Markov chain on S if there exists a stochastic matrix P on S such that P{X t+1 = y | X 0, X 1, . . . , X t } = P(X t , y)
for all t > 0, y ∈ S.
(4.7)
To simplify terminology, we also call (X t ) P-Markov when it satisfies (4.7) . We call either X 0 or its distribution ψ0 the initial condition of (X t ) depending on context. The definition of a Markov chain says two things: (i) When updating to X t+1 from X t , earlier states are not required. (ii) The matrix P encodes all of the information required to perform the update, given X t . One way to think about Markov chains is algorithmically: Let P be a stochastic matrix and let ψ0 be an element of 𝒟(S). Now generate (X t ) via Algorithm 3. The resulting sequence is P-Markov with initial condition ψ0 . 1 2 3 4 5
set t = 0 and draw X t from ψ0 while t < ∞ do draw X t+1 from the distribution P(X t ,·) let t = t + 1 end Algorithm 3: Generation of P-Markov (X t ) with initial condition ψ0
4.1.1.3
Simulation For both simulation and theory, it is useful to be able to translate Algorithm 3 into a stochastic difference equation governing the evolution of (X t )t>0 . We now outline the procedure, which uses inverse transform sampling (see §1.3.1.2). For simplicity, we assume that S = [n], with typical elements i, j. The basic idea is to apply the inverse transform method to each row of P and then sample by drawing a uniform random variable at each update. To this end, we set F(i,u) :=
n X
j1{q(i, j − 1) < u 6 q(i, j)}
(i ∈ S, u ∈ (0,1)),
j=1
where, for each i, j ∈ S, the value q(i, j) is defined recursively by q(i, j) := q(i, j − 1) + P(i, j)
with q(i,0) = 0.
Let U (0,1) represent the uniform distribution on (0,1), and take X t+1 = F(X t ,Ut+1 ),
iid
where (Ut ) ∼ U (0,1).
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
(4.8)
134
Markov Chains and Networks
PB 8 state
6 4 2 0
20
40
60
80
100
60
80
100
time
PQ 5 state
4 3 2 1 0
20
40 time
Figure 4.4 Wealth percentile over time
If X 0 is an independently drawn random variable with distribution ψ0 on S, then (X t ) is P-Markov on S with initial condition ψ0 , as Exercise 4.1.2 asks you to show. Exercise 4.1.2. Conditional on X t = i, show that, for given j ∈ S, (i) X t+1 = j if and only if Ut+1 lies in the interval (q(i, j − 1),q(i, j)]. (ii) This event has probability P(i, j). Conclude that X t+1 in (4.8) is a draw from P(i,·). Each subfigure in Figure 4.4 shows realizations of two Markov chains, both generated using the stochastic difference equation (4.8). Each sequence is generated with its own independent sequence of draws (Ut ). The underlying transition matrices are PB from (4.5) in the top panel and PQ from (4.4) in the bottom panel. In both panels, one chain starts from the lowest state and the other from the highest. Notice that time series generated by PB mix faster than those generated by PQ : The difference in initial states is not a strong predictor of outcomes after an initial “burn in” period. We discuss mixing and its connection to stability below.
4.1.1.4
Higher-Order Transition Matrices Given a finite Markov model ℳ with state space S and transition matrix P, define (P k )k∈N by P k+1 = P P k for all k, with the understanding that P 0 = I = the identity matrix. In other words, for each k, the matrix P k is the k-th power of P. If we spell out the matrix product P k+1 = P P k element-by-element, we get X P(x,z)P k (z, y) (x, y ∈ S, k ∈ N). (4.9) P k+1 (x, y) := z
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.1 Markov Chains as Digraphs
135
Exercise 4.1.3. Prove that P k is a stochastic matrix on S for all k ∈ N. In this context, P k is called the k-step transition matrix corresponding to P. The k-step transition matrix has the following interpretation: If (X t ) is P-Markov, then, for any t,k ∈ N and x, y ∈ S, P k (x, y) = P{X t+k = y | X t = x}.
(4.10)
In other words, P k provides the k-step transition probabilities for the P-Markov chain (X t ), as suggested by its name. This claim can be verified by induction. Fix t ∈ N and x, y ∈ S. The claim is true by definition when k = 1. Suppose the claim is also true at k, and now consider the case k + 1. By the law of total probability, we have P{X t+k+1 = y | X t = x} =
X
P{X t+k+1 = y | X t+k = z}P{X t+k = z | X t = x}.
z
The induction hypothesis allows us to use (4.10), so the last equation becomes P{X t+k+1 = y | X t = x} =
X
P(z, y)P k (x,z) = P k+1 (x, y).
z
This completes our proof by induction. A useful identity for the higher-order Markov matrices is P j+k (x, y) =
X
P k (x,z)P j (z, y)
((x, y) ∈ S × S),
(4.11)
z
which holds for any j,k in N. This is called the Chapman–Kolmogorov equation. Note that • (4.9) is a special case of (4.11); and • (4.11) is a special case of (1.27) on page 36, written with different notation. To provide probabilistic intuition for the validity of the Chapman–Kolmogorov equation, let X 0 = x and let y ∈ S be given. Using the law of total probability again, we have P{X j+k = y | X 0 = x} =
X
P{X j+k = y | X 0 = x, X k = z}P{X k = z | X 0 = x}.
z
By Markov property (4.7), the future and past are independent given the present, so X
P{X j+k = y | X 0 = x, X k = z} =
z
X
P{X j+k = y | X k = z}.
z
As a result of this fact and (4.10), the equation before this one can be rewritten as (4.11).
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
136
Markov Chains and Networks
4.1.2
Distribution Dynamics Let ℳ be a finite Markov model with state space S and transition matrix P. Let (X t ) be P-Markov, and, for each t > 0, let ψt ∈ 𝒟(S) be defined by ψt := P{X t = ·} = the distribution of X t . The vector ψt is called the marginal distribution of X t . While (X t ) is random, the sequence (ψt ) is deterministic. In this section we investigate its dynamics.
4.1.2.1
Updating Marginal Distributions The key idea for this section is that there is a simple link between successive marginal distributions: By the law of total probability, we have X P{X t+1 = y} = P{X t+1 = y | X t = x} · P{X t = x}, x
which can be rewritten as ψt+1 (y) =
X
P(x, y)ψt (x)
(y ∈ S).
(4.12)
x
This fundamental expression tells us how to update marginal distributions given the transition matrix P. When each ψt is interpreted as a row vector, we can write (4.12) as ψt+1 = ψt P.
(4.13)
(Henceforth, in expressions involving matrix algebra, distributions are row vectors unless otherwise stated). Some authors refer to (4.13) as the forward equation associated with P, while ψ 7→ ψ P is called the forward operator, by analogy with the Kolmogorov forward equation from continuous time. Think of (4.13) as a difference equation in distribution space. Iterating backwards, ψt = ψt−1 P = (ψt−2 P)P = ψt−2 P 2 = · · · = ψ0 P t . Given any ψ0 ∈ 𝒟(S) and t ∈ N, we have d
ψ0 P t = the distribution of X t given X 0 = ψ0 . Example 4.1.2: As an illustration, let’s take the matrix PQ estimated by Quah (1993) using 1960–1984 data and use PQt to update the 1985 distribution t = 2019 − 1985 = 34 times, in order to obtain a prediction for the countrywide income distribution in 2019. Figure 4.5 shows how this prediction fares compared to the realized 2019 distribution, calculated from World Bank GDP data.1 1 Example 4.1.2 is intended as an illustration of the mechanics of updating distributions. While the
methodology in Quah (1993) is thought-provoking, it struggles to make plausible long-run predictions about something as complex as the countrywide income distribution. Indeed, the Kullback–Leibler deviation between the predicted and realized 2019 distributions is actually larger than the
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.1 Markov Chains as Digraphs
137
Figure 4.5 Predicted vs. realized cross-country income distributions for 2019
4.1.2.2
Trajectories in the Long Run One of the main subfields of Markov chain analysis is asymptotics of distribution sequences. This topic turns out to be important for network theory as well. In §4.2.2 we will investigate asymptotics in depth. In this section we build some intuition via simulations. Figure 4.6 shows the trajectory (ψ Pat ) when S = {1,2,3}, ψ = (0,0,1), and Pa is the transition matrix displayed in (4.2). The blue triangle is the unit simplex in R3+ , consisting of all row vectors ψ ∈ R3 such that ψ > 0 and ψ1 = 1. The unit simplex can be identified with 𝒟(S) when S = {1,2,3}. Red dots in the figure are distributions in the sequence (ψ Pat ) for t = 0, . . . ,20. Figure 4.7 shows distribution dynamics for Pa that start from initial condition ψ = (0,1/2,1/2). It seems that both of the sequences are converging. This turns out to be the case – the black dot in the figures is the limit of both sequences, and, moreover, this point is a stationary distribution for Pa , as defined in §1.3.1.3. In fact we can – and will – also show that no other stationary distribution exists and that ψ Pat converges to the stationary distribution regardless of the choice of ψ ∈ 𝒟(S). This is due to certain properties of Pa , related to connectivity and aperiodicity. Figure 4.8 provides another view of a distribution sequence, this time generated from the matrix PB in (4.5). The initial condition ψ0 was uniform. Each distribution shown was calculated as ψ PQt for different values of t. The distribution across wealth classes converges rapidly to what appears to be a long-run limit. Below we confirm Kullback–Leibler deviation between the 1985 and 2019 distributions. Evidently, a naive estimate “nothing will change” model predicts better than Quah’s. Most of the focus in this text is on short-term forecasts and scenarios, where the system is approximately stationary after suitable transformations, rather than heroic long-term predictions where nonstationary change is hard to quantify.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
138
Markov Chains and Networks
(0, 0, 1)
(1, 0, 0) (0, 1, 0)
Figure 4.6 A trajectory from ψ0 = (0,0,1)
that this is so and that the limit is independent of the initial condition. The rapid rate of convergence is due to the high level of mixing in the transition dynamics.
4.1.3
Stationarity In this section we examine stationary distributions and their properties. As we will see, stationary distributions can be regarded as steady states for the evolution of the sequence of marginal distributions. (Later, when we study ergodicity, stationary distributions will acquire another important interpretation.)
4.1.3.1
Stationary Distributions Recall from §1.3.1.3 that if P is a stochastic matrix and ψ ∈ Rn+ is a row vector such that ψ1 = 1 and ψ P = ψ, then ψ is called stationary for P. So now let ℳ be a finite Markov model with state space S and transition matrix P. Translating to the notation of Markov chains, a distribution ψ∗ ∈ 𝒟(S) is stationary for ℳ if X ψ∗ (y) = P(x, y)ψ∗ (x) for all y ∈ S. x∈S
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.1 Markov Chains as Digraphs
139
(0, 0, 1)
(1, 0, 0) (0, 1, 0)
Figure 4.7 A trajectory from ψ0 = (0,1/2,1/2) t =0
0.25
t =1
0.25
t =2
0.25
0.20
0.20
0.20
0.20
0.15
0.15
0.15
0.15
0.10
0.10
0.10
0.10
0.05
0.05
0.05
0.05
0.00
0.00 1
8 Quantile
0.00 1
8
t = 100
0.25
0.00 1
Quantile
8 Quantile
Figure 4.8 Distribution projections from PB
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
1
8 Quantile
140
Markov Chains and Networks
We also write this expression as ψ∗ = ψ∗ P and understand ψ∗ as a fixed point of the map ψ 7→ ψ P that updates distributions (cf. Equation (4.13)). d
d
If X t = ψ∗ , then, for any j ∈ N, the fixed point property implies that X t+ j = ψ∗ P j = ψ∗ . Hence d
d
X t = ψ∗ H⇒ X t+ j = ψ∗ for all j ∈ N. Example 4.1.3: Suppose workers are hired at rate α and fired at rate β, transitioning between unemployment and employment according to ! 1−α α Pw = . (4.14) β 1−β In §1.2.3.3 we showed that α+β > 0 implies ψ = (β/(α+β),α/(α+β)) is a dominant left eigenvector for Pw . Since r (Pw ) = 1, the Perron–Frobenius theorem tells us that ψ is stationary for Pw . One implication is that, if the distribution of workers across the two employment states is given by ψ, and updates obey the dynamics encoded in Pw , then no further change is observed in the unemployment rate. Example 4.1.4: The black dot in each of Figures 4.6 and 4.7, indicating the limit of the marginal sequences, is a stationary distribution for the Markov matrix Pa displayed in (4.2), page 130. We discuss its calculation in §4.1.3.4. Exercise 4.1.4. Let ℳ be a finite Markov model with state space |S| = n and transition matrix P. Let ψ ≡ 1/n be the uniform distribution on S. Prove that ψ is stationary for P if and only if P is doubly stochastic (i.e., has unit column sums as well as unit row sums). In Figures 4.6 and 4.7, all trajectories converge toward the stationary distribution. Not all stationary distributions have this “attractor” property, and in general there can be many stationary distributions. The next example illustrates. Exercise 4.1.5. Let ℳ = (S, E, p) be a finite Markov model with (x, y) ∈ E if and only if x = y. Describe the implied weight function and corresponding transition matrix. Show that every distribution in 𝒟(S) is stationary for ℳ.
4.1.3.2
Existence and Uniqueness From the Perron–Frobenius theorem we easily obtain the following fundamental result. theorem 4.1.1 (Existence and Uniqueness of Stationary Distributions) Every finite Markov model ℳ = (S, E, p) has at least one stationary distribution ψ∗ in 𝒟(S). If
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.1 Markov Chains as Digraphs
141
the digraph (S, E) is strongly connected, then ψ∗ is unique and everywhere positive on S. Proof Let ℳ be a finite Markov model. Since the corresponding adjacency matrix P is stochastic, existence follows from Exercise 1.3.7 in §1.3.1.3. By Theorem 1.4.3 on page 36, strong connectedness of ℳ implies irreducibility of P. When P is irreducible, uniqueness and everywhere positivity of the stationary distribution follows from the Perron–Frobenius theorem (page 13). The basic idea behind the uniqueness part of Theorem 4.1.1 is as follows: Suppose to the contrary that ℳ is strongly connected and yet two distinct stationary distributions ψ∗ and ψ∗∗ exist in 𝒫(S). Since a P-Markov chain started at ψ∗ always has marginal distribution ψ∗ and likewise for ψ∗∗ , different initial conditions lead to different long-run outcomes. This contradicts strong connectedness in the following way: Strong connectedness implies that both chains traverse the whole state space. Moreover, being Markov chains, they forget the past once they arrive at any state, so the starting draws should eventually be irrelevant. (Actually, the story in the last paragraph is incomplete. Initial conditions can determine long-run outcomes under strong connectedness in one sense: A “periodic” Markov model can traverse the whole space but only at specific times that depend on the starting location. If we rule out such periodicity, we get results that are even stronger than Theorem 4.1.1. This topic is treated in §4.2.2.)
4.1.3.3
Brouwer’s Theorem Another way to prove the existence claim in Theorem 4.1.1 is via the famous fixed point theorem of L. E. J. Brouwer (1881–1966). theorem 4.1.2 (Brouwer) If C is a convex compact subset of Rn and G is a continuous self-map on C, then G has at least one fixed point in C. The proof of Theorem 4.1.2 in one dimension is not difficult, while the proof in higher dimensions is challenging. See, for example, Aliprantis and Border (1999). Exercise 4.1.6. Prove Brouwer’s fixed point theorem for the case C = [0,1] by applying the intermediate value theorem. One advantage of Brouwer’s fixed point theorem is that its conditions are quite weak. One disadvantage is that it provides only existence, without uniqueness or stability. Figure A.4 provides an example of how multiple fixed points can coexist under the conditions of the theorem.2 Exercise 4.1.7. Prove the first part of Theorem 4.1.1 (existence of a stationary distribution) using Brouwer’s fixed point theorem. 2 There are many useful extensions to Brouwer’s theorem, such as one for set-valued functions due
to Kakutani (1941). These results have many applications in economics (see, for example, Nash (1950)). Another paper, due to Schauder (1930), extends Brouwer’s result to infinite-dimensional spaces.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
142
Markov Chains and Networks
4.1.3.4
Computation Let’s consider how to compute stationary distributions. While ψ∗ P = ψ∗ is a finite set of linear equations that we might hope to solve directly for ψ∗ , there are problems with this idea. For example, ψ∗ = 0 is a solution that fails to lie in 𝒟(S). To restrict the solution to 𝒟(S), we proceed as follows: Suppose |S| = n, and note that row vector ψ ∈ 𝒟(S) is stationary if and only if ψ(I − P) = 0, where I is the n × n identity matrix. Let 1n be the 1 × n row vector (1, . . . ,1). Let 1n×n be the n × n matrix of ones. Exercise 4.1.8. Consider the linear system 1n = ψ(I − P + 1n×n ),
(4.15)
where ψ is a row vector. Show that (i) every solution ψ of (4.15) lies in 𝒟(S); and (ii) ψ is stationary for P if and only if (4.15) holds. Solving the linear system (4.15) produces a stationary distribution in any setting where the stationary distribution is unique. When this is not the case, problems can arise. Exercise 4.1.9. Give a counterexample to the claim that (I − P + 1n×n ) is always nonsingular when P is a stochastic matrix. There are also graph-theoretic algorithms for computing all of the stationary distributions of an arbitrary stochastic matrix. (The Python and Julia libraries QuantEcon.py and QuantEcon.jl have efficient implementations of this type.)
4.2
Asymptotics In this section we turn to long-run properties of Markov chains, including ergodicity. With these ideas in hand, we will then investigate the evolution of information over social networks.
4.2.1
Ergodicity Let’s begin with the fascinating and important topic of ergodicity. The simplest way to understand ergodicity is as an extension of the law of large numbers from iid sequences to more general settings, where the iid property holds only in a limiting sense.
4.2.1.1
Harmonic Functions Let ℳ be a finite Markov model with state space S and transition matrix P. Fix h ∈ R S , and let
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
Ph(x) :=
X
P(x, y)h(y)
(x ∈ S).
143
(4.16)
y∈S
If h is understood as a column vector in R|S| , then Ph(x) is just element x of the vector Ph. The map h 7→ Ph is sometimes called the “conditional expectation operator,” since, given that P(x, y) = P{X t+1 = y | X t = x}, we have X P(x, y)h(y) = E[h(X t+1 ) | X t = x]. y∈S
A function h ∈ R S is called P-harmonic if Ph = h pointwise on S. Thus, Pharmonic functions are fixed points of the conditional expectation operator h 7→ Ph. If h is P-harmonic and (X t ) is P-Markov, then E [h(X t+1 ) | X t ] = (Ph)(X t ) = h(X t ).
(4.17)
(A stochastic process with this property – i.e., that the current value is the best predictor of next period’s value – is called a martingale. Martingales are one of the foundational concepts in probability, statistics, and finance.) Example 4.2.1: Let ℳ be a finite Markov model with state space S and transition matrix P. If A ⊂ S and Ac := S \ A are both absorbing for ℳ, then 1 A and 1 Ac are both P-harmonic. To see this, we apply Exercise 4.1.1 to obtain ( X X 1 if x ∈ A (P1 A )(x) = P(x, y)1 A (y) = P(x, y) = 0 if x ∈ Ac . y∈S y∈A In other words, P1 A = 1 A . A similar argument gives P1 Ac = 1 Ac . Exercise 4.2.1. Let ℳ be a finite Markov model with state space S and transition matrix P. Show that every constant function in R S is P-harmonic.
4.2.1.2
Definition and Implications Let ℳ be a finite Markov model with state space S and transition matrix P. We know that every constant function in R S is P-harmonic. We call ℳ ergodic if the only P-harmonic functions in R S are the constant functions. Example 4.2.2: If P(x, y) = ϕ(y) for all x, y in S, where ϕ is some fixed distribution on S, then P generates an iid Markov chain, since the next period draw has no dependence on the current state. Any model ℳ with an adjacency matrix of this type is ergodic. Indeed, if P has this property and h ∈ R S is P-harmonic, then, for any x ∈ S, we have X X h(x) = (Ph)(x) = P(x, y)h(y) = ϕ(y)h(y). y
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
y
144
Markov Chains and Networks
middle class
rich
poor Figure 4.9 A poverty trap
Hence, h is constant. This proves that any P-harmonic function is a constant function. Example 4.2.3: A laborer is either unemployed (state 1) or employed (state 2). In state 1 they are hired with probability α. In state 2 they are fired with probability β. The corresponding Markov model ℳ has state and transition matrix given by ! 1−α α S = {1,2} and Pw = . β 1−β The statement Pw h = h becomes 1−α β
α 1−β
!
! ! h(1) h(1) = . h(2) h(2)
The first row is (1 − α)h(1) + αh(2) = h(1), or αh(1) = αh(2). Thus, ℳ is ergodic whenever α > 0. By a similar argument, ℳ is ergodic whenever β > 0. Example 4.2.4: Let ℳ be any finite Markov model with state space S and transition matrix P. It is immediate from Example 4.2.1 that if S can be partitioned into two nonempty absorbing sets, then ℳ is not ergodic. Hence, the poverty trap model in Figure 4.9 is not ergodic. Similarly, if α = β = 0 in the matrix Pw discussed in Example 4.2.3, then Pw = I , and each state is a disjoint absorbing set. Ergodicity fails. The examples discussed above suggest that, for a finite Markov model ℳ, ergodicity depends on the connectivity properties of the digraph. The next result confirms this. proposition 4.2.1 If ℳ is strongly connected, then ℳ is ergodic. Proof Let ℳ be a strongly connected Markov model with state space S and transition matrix P. Let h be P-harmonic, and let x ∈ S be the maximizer of h on S. Let m = h(x). Suppose there exists a y in S with h(y) < m. Since ℳ is strongly connected, we can choose a k ∈ N such that P k (x, y) > 0. Since h is P-harmonic, we have h = P k h, and hence
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
m = h(x) =
X
P k (x,z)h(z) = P k (x, y)h(y) +
z
X
145
P k (x,z)h(z) < m.
z6= y
This contradiction shows that h is constant. Hence ℳ is ergodic. The implication in Proposition 4.2.1 is one way, as the next exercise asks you to confirm. Exercise 4.2.2. Provide an example of a finite Markov model that is ergodic but not strongly connected.
4.2.1.3
Implications of Ergodicity One of the most important results in probability theory is the law of large numbers (LLN). In the finite state setting, the classical version of this theorem states that ( ) k−1 X 1X P lim h(X t ) = h(x)ϕ(x) = 1 k→∞ k t=0
x∈S
when (X t )t>0 is an iid sequence of random variables with common distribution ϕ ∈ 𝒟(S) and h is an arbitrary element of R S . This version of the LLN is classical in the sense that the iid assumption is imposed. It turns out that the iid assumption can be weakened to allow for a degree of dependence between observations, which leads us to ask whether or not the LLN holds for Markov chains as well. The answer to this question is yes, provided that dependence between observations dies out fast enough. One candidate for this condition is ergodicity. In fact, it turns out that ergodicity is the exact necessary and sufficient condition required to extend the law of large numbers to Markov chains. The next theorem gives details. theorem 4.2.2 Let ℳ be any finite Markov model with state space S and transition matrix P. The following statements are equivalent: (i) ℳ is ergodic. (ii) ℳ has a unique stationary distribution ψ∗ , and, for any P-Markov chain (X t ) and any h ∈ R S , ( ) k−1 X 1X ∗ P lim h(X t ) = h(x)ψ (x) = 1. (4.18) k→∞ k t=0
x∈S
The proof of Theorem 4.2.2 is given in Chapter 17 of Meyn and Tweedie (2009). We skip the proof but provide intuition through the following examples. Example 4.2.5: Recall the iid case from Example 4.2.2. We showed that ℳ is ergodic. By Theorem 4.2.2, the convergence in (4.18) holds with ψ∗ = ϕ. This is consistent with the LLN for iid sequences.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
146
Markov Chains and Networks
Example 4.2.6: Let ℳ be a finite Markov model with S = {1,2} and P = I , the identity matrix. Markov chains generated by P are constant. Since every h ∈ R2 satisfies Ph = h, we see that ℳ is not ergodic. This means that the LLN result in (4.18) fails. But this is exactly what we would expect, since a constant chain (X t ) P implies k1 k−1 t=0 X t = X 0 for all k. In particular, if X 0 is drawn from a nondegenerate distribution, then the sample mean does not converge to any constant value. Example 4.2.7: Consider again the poverty trap model in Figure 4.9. Say that h(x) is earnings in state x and that h(poor) = 1, h(middle) = 2, and h(rich) = 3. P Households that start with X 0 = poor will always be poor, so k1 k−1 t=0 h(X t ) = 1 for all k. Households that start with X 0 in {middle, rich} remain in this absorbing set P forever, so k1 k−1 t=0 h(X t ) > 2 for all k. In particular, the limit of the sum depends on the initial condition. This violates part (ii) of Theorem 4.2.2, which states that the limit is independent of the distribution of X 0 .
4.2.1.4
Reinterpreting the Stationary Distribution Ergodicity has many useful implications. One is a new interpretation for the stationary distribution. To illustrate this, let ℳ be an ergodic Markov model with state space S and transition matrix P. Let (X t ) be a P-chain, and let k
1X 1{X t = y} ψˆ k (y) := k
(y ∈ S).
t=1
The value ψˆ k (y) measures the fraction of time that the P-chain spends in state y over the time interval 1, . . . ,k. Under ergodicity, for fixed y ∈ S, we can use (4.18) with h(x) = 1{x = y} to obtain X ψˆ k (y) → 1{x = y}ψ∗ (x) = ψ∗ (y). (4.19) x∈S
Turning (4.19) around, we see that ψ∗ (y) ≈ the fraction of time that any P-chain (X t ) spends in state y.
(4.20)
Figure 4.10 illustrates this idea for a simulated Markov chain (X t ) generated from the matrix PB introduced in (4.5). The figure compares ψˆ k and ψ∗ for different values of k. As k → ∞, the convergence claimed in (4.19) occurs. Of course, we must remember that (4.20) is only valid under ergodicity. For example, if P = I , the identity, then every distribution is stationary, every P-Markov chain is constant, and (4.20) does not hold. Notice that, in view of Theorem 4.2.2, the convergence in (4.18) occurs for any initial condition. This gives us, under ergodicity, a way of computing the stationary distribution via simulation (and (4.19)). While this method is slower than algebraic
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
147
4.2 Asymptotics
0:5
0:5
ψ∗ ψˆk with k = 10
0:3 0:2
ψ∗ ψˆk with k = 100
0:4
prob.
prob.
0:4
0:1
0:3 0:2 0:1
0:0
0:0
state
state
0:5
0:5
ψ∗ ψˆk with k = 1000
0:3 0:2
ψ∗ ψˆk with k = 10000
0:4
prob.
prob.
0:4
0:1
0:3 0:2 0:1
0:0
0:0 1
2
3
4
5
6
7
8
1
2
3
state
4
5
6
7
8
state
Figure 4.10 Convergence of the empirical distribution to ψ ∗
techniques (see, e.g., §4.1.3.4) for small problems, it can be the only feasible option when |S| is large.
4.2.2
Aperiodicity and Stability In §4.2.1 we discussed sample path properties of Markov chains, finding that strong connectivity is sufficient for the stability of time series averages. Next we turn to marginal distributions of the chain and their long-run properties, which we examined informally in §4.1.2.2. We will see that, to guarantee convergence of these sequences, we also need a condition that governs periodicity.
4.2.2.1
Convergence of Marginals Let ℳ be a finite Markov model with state space S and transition matrix P. We call ℳ globally stable if there is only one stationary distribution ψ∗ in 𝒟(S), and, moreover, lim ψ P t = ψ∗
t→∞
for all ψ ∈ 𝒟(S).
(4.21)
In other words, marginal distributions of every P-Markov chain converge to the unique stationary distribution of the model. There is a useful connection between global stability and absorbing sets. Intuitively, if ℳ is globally stable and has an absorbing set A that can be reached from any x ∈ S, then any Markov chain generated by these dynamics will eventually arrive in A and
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
148
Markov Chains and Networks
never leave. Hence, the stationary distribution must put all of its mass on A. The next exercise asks you to confirm this. Exercise 4.2.3. Let ℳ be a finite Markov model with state space S and transition matrix P. Let A be a nonempty absorbing subset of S. Assume that (a) ℳ is globally stable with unique stationary distribution ψ∗ ; and (b) for each x ∈ Ac := S \ A, there exists an a ∈ A such that a is accessible from x. P Show that, under the stated conditions, there exists an ε > 0 such that y∈Ac P n (x, y) 6 1 − ε for all x ∈ S, where n = |S|. Using this fact, show in addition that P ∗ y∈A ψ (y) = 1.
4.2.2.2
A Key Theorem From Theorem 4.1.1 we saw that strong connectedness is sufficient for uniqueness of the stationary distribution. One might hope that strong connectedness is enough for global stability too, but this is not true. To see why, suppose for example that S = {0,1} and E = {(0,1),(1,0)}. The transition matrix is ! 0 1 Pd = . (4.22) 1 0 While this model is strongly connected, global stability fails. Indeed, if (X t ) is Pd Markov and starts at 0, then (X t ) will visit state 1 on odd dates and state 0 on even dates. That is, Pdt δ0 = δ t mod 2 . This sequence does not converge. The issue with Pd is that, even though the chain traverses the whole state space, the distribution of X t will affect that of X t+ j for all j due to periodicity. This causes stability to fail. If, however, we rule out periodicity, then we have enough for stability to hold. This line of reasoning leads to the following famous theorem. theorem 4.2.3 Let ℳ be a finite Markov model. If ℳ is strongly connected and aperiodic, then ℳ is globally stable. Proof Let ℳ be a finite Markov model with state S and transition matrix P. Suppose ℳ is aperiodic and strongly connected. Let ψ∗ be the unique stationary distribution of ℳ. By Theorem 1.4.4, P is primitive. Hence we can apply the last part of the Perron–Frobenius theorem (see page 13). Using r (P) = 1, this result tells us that P t → er e`> as t → ∞, where er and e` are the unique right and left eigenvectors of P corresponding to the eigenvalue r (P) = 1 that also satisfy the normalization he`,er i = 1. Now observe that ψ∗ obeys ψ∗ = ψ∗ P and, in addition, P1 = 1. Hence ψ∗ and
1 are left and right eigenvectors corresponding to r (P) = 1. Moreover, ψ∗,1 = 1. Hence er = 1 and e`> = ψ∗ .
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
149
Combining these facts leads to lim P t = P ∗,
where
t→∞
P ∗ := 1ψ∗ .
(4.23)
If we pick any ψ ∈ 𝒟(S), then, by (4.23), we get ψ P t → ψ,1 ψ∗ = ψ∗ . Hence global stability holds.
Example 4.2.8: The Markov models PQ and PB in §4.1.1 are both aperiodic by the results in §1.4.1.4. Being strongly connected, they are also globally stable. The aperiodicity condition in Theorem 4.2.3 is, in general, not stringent. On the other hand, the strong connectedness requirement is arguably quite strict. Weaker conditions for global stability are available, as we shall see in §4.2.3.
4.2.2.3
Rates of Convergence: Spectral Gap While global stability is a very useful property, the implications are qualitative rather than quantitative. In practice, we usually want to know something about the rate of convergence. There are several ways of looking at this. We cover the two most common in this section and the next. As a first step, fixing a Markov model ℳ with state space S and transition matrix P, we use (1.5) on page 10 to write P t as Pt =
n−1 X
λit ei εi> + 1ψ∗,
(4.24)
i=1
where each λi is an eigenvalue of P, and ei and εi are the right and left eigenvectors corresponding to λi . We have also ordered the eigenvalues from smallest to largest and used the Perron–Frobenius theorem to infer that λ n = r (P) = 1, as well as the arguments in the proof of Theorem 4.2.3 that showed en = 1 and εn> = ψ∗ . Premultiplying P t by arbitrary ψ ∈ 𝒟(S) and rearranging now gives ψ P t − ψ∗ =
n−1 X
λit ψei εi> .
(4.25)
i=1
Recall that eigenvalues are ordered from smallest to largest. Moreover, by the Perron– Frobenius theorem, λi < 1 for all i < n when P is primitive (i.e., ℳ is strongly connected and aperiodic). Hence, after taking the Euclidean norm deviation, we obtain kψ P t − ψ∗ k = O(ηt ),
where
η := |λ n−1 | < 1.
(4.26)
Thus, the rate of convergence is governed by the modulus of the second-largest eigenvalue. The difference between the largest and second-largest eigenvalue of a nonnegative matrix is often called the spectral gap. For this reason, we can also say that, for
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
150
Markov Chains and Networks
primitive stochastic matrices, the rate of convergence is determined by the (nonzero) spectral gap. Example 4.2.9: When studying the worker model with hiring rate α and firing rate β in §1.2.1.3, we found that the eigenvalues of the transition matrix Pw are λ 1 = 1 − α − β and λ 2 = 1. Hence the spectral gap is α + β and the rate of convergence is O((1 − α − β)t ). High hiring and firing rates both produce faster convergence. In essence, this is because higher hiring and firing rates mean workers do not stay in any state for long, so initial conditions die out faster.
4.2.3
The Markov–Dobrushin Coefficient The rate of convergence of ψ P t to ψ∗ given in §4.2.2.3 restricts the Euclidean distance between these vectors as a function of t. There are, however, other metrics we could use in studying rates of convergence, and sometimes these other metrics give more convenient results. In fact, as we show in this section, a good choice of metric leads us to a more general stability result than the (better known) aperiodicity-based result in §4.2.2.
4.2.3.1
An Alternative Metric For the purposes of this section, For ϕ,ψ ∈ 𝒟(S), we set X ρ(ϕ,ψ) := kϕ − ψk1 := |ϕ(x) − ψ(x)|, x∈S
which is just the `1 deviation between ϕ and ψ (see §2.3.1.1). Exercise 4.2.4. Show that, for any ϕ,ψ ∈ 𝒟(S), we have (i) ρ(ϕ,ψ) 6 2; (ii) ρ(ϕ P,ψ P) 6 ρ(ϕ,ψ) for any stochastic matrix P. Property (ii) is called the nonexpansiveness property of stochastic matrices under the `1 deviation. As we will see, we can tighten this bound when P satisfies certain properties. As a first step we note that, for the `1 deviation, given any stochastic matrix P, we have ρ(ϕ P,ψ P) 6 (1 − α(P))ρ(ϕ,ψ),
(4.27)
X α(P) := min [P(x, y) ∧ P(x 0, y)] : (x,x 0 ) ∈ S × S .
(4.28)
where
y∈S
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
151
Here a ∧ b := min{a,b} when a,b ∈ R. We call α(P) the Markov–Dobrushin coefficient of P, although other names are also used in the literature. A proof of the bound in (4.27) can be found in Stachurski (2022a) or Seneta (2006a).3 Exercise 4.2.5. Consider the stochastic matrix 1−α Pw = β
! α . 1−β
Show that α(Pw ) = 0 if and only if α = β = 0 or α = β = 1. How should the Markov–Dobrushin coefficient be understood? The coefficient is large when the rows of P are relatively similar. For example, if rows P(x,·) and P P(x 0,·) are identical, the y∈S [P(x, y) ∧ P(x 0, y)] = 1. Similarity of rows is related to stability. The next exercise helps to illustrate this. Exercise 4.2.6. Let P be such that all rows are identical and equal to ϕ ∈ 𝒟(S). Prove that global stability holds in one step, in the sense that ϕ is the unique stationary distribution, and ψ P = ϕ for all ψ ∈ 𝒟(S). Exercise 4.2.7. Using (4.27), show that, for any ϕ,ψ ∈ 𝒟(S), we have ρ(ϕ P t ,ψ P t ) 6 (1 − α(P))t ρ(ϕ,ψ)
for all t ∈ N.
(4.29)
Since powers of stochastic matrices are again stochastic, and since (4.27) is valid for any stochastic matrix, the bound in (4.29) can be generalized by replacing P with P k for any given k ∈ N, which gives (with t replaced by τ) ρ(ϕ P τk ,ψ P τk ) 6 (1 − α(P k ))τ ρ(ϕ,ψ)
for all τ ∈ N.
Now observe that, for any t ∈ N, we can write t = τk + j, where τ ∈ Z+ and j ∈ {0, . . . ,k − 1}. Fixing t and choosing j to make this equality hold, we get ρ(ϕ P t ,ψ P t ) = ρ(ϕ P τk+ j ,ψ P τk+ j ) 6 ρ(ϕ P τk ,ψ P τk ) 6 (1 − α(P k ))τ ρ(ϕ,ψ), where the second inequality is due to the nonexpansive property of stochastic matrices (Exercise 4.2.4). Since τ is an integer satisfying τ = bt/kc, where b·c is the floor function, we can now state the following. theorem 4.2.4 Let ℳ be a finite Markov model with state space S and transition matrix P. For all ϕ,ψ ∈ 𝒟(S) and all k,t ∈ N, we have ρ(ϕ P t ,ψ P t ) 6 (1 − α(P k ))bt/kc ρ(ϕ,ψ).
(4.30)
In particular, if there exists a k ∈ N such that α(P k ) > 0, then ℳ is globally stable.
3 Seneta (2006a) also discusses the history of Andrey Markov’s work, from which originated the kinds of
contraction-based arguments used in this section.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
152
Markov Chains and Networks
To see why the global stability implication stated in Theorem 4.2.4 holds, suppose there exists a k ∈ N such that α(P k ) > 0. Now substitute arbitrary ψ ∈ 𝒟(S) and any stationary distribution ψ∗ for P into (4.30) to obtain ρ(ψ P t ,ψ∗ ) 6 (1 − α(P k ))bt/kc ρ(ψ,ψ∗ ) 6 2(1 − α(P k ))bt/kc
(4.31)
for all t ∈ N, where the second bound is due to Exercise 4.2.4. Exercise 4.2.8. In the preceding discussion, the distribution ψ∗ was taken to be any stationary distribution of P. Using (4.31), prove that P has only one stationary distribution when α(P k ) > 0. One of the major advantages of Theorem 4.2.4 is that strong connectivity of ℳ is not required. In the next section we will see an example of a finite Markov model ℳ where (i) strong connectivity fails but (ii) the conditions of Theorem 4.2.4 are satisfied.4 Exercise 4.2.9. Let ℳ be a finite Markov model with state space S and transition matrix P. Prove the existence of a k ∈ N with α(P k ) > 0 whenever ℳ is strongly connected and aperiodic.
4.2.3.2
Sufficient Conditions While the Markov–Dobrushin coefficient α(P k ) can be calculated for any given k on a computer by stepping through all pairs of rows in P k , this calculation is computationally intensive when S is large. When applicable, the following lemma simplifies the problem by providing a sufficient condition for α(P k ) > 0. lemma 4.2.5 Let k be a natural number, and let ℳ be a finite Markov model with state space S and transition matrix P. If there is a state z ∈ S such that, for every x ∈ S, there exists a directed walk from x to z of length k, then α(P k ) > 0. Proof Let k ∈ N and z ∈ S be such that, for every x ∈ S, there exists a directed walk from x to z of length k. By Proposition 1.4.2, we then have r := minx∈S P k (x,z) > 0. Since, for any x,x 0 ∈ S, X [P k (x, y) ∧ P k (x 0, y)] > P k (x,z) ∧ P k (x 0,z) > r > 0, y∈S
strict positivity of α(P k ) now follows from the definition of the Markov–Dobrushin coefficient. Example 4.2.10: Consider the digraph in Figure 4.11. This digraph is not strongly connected because node 4 is not accessible from anywhere. However, there exists a 4 It can be shown that the condition α(P k ) > 0 for some k ∈ N is both necessary and sufficient for global
stability of a finite Markov model. Hence the conditions of Theorem 4.2.4 are strictly weaker than strong connectedness plus aperiodicity, as used in Theorem 4.1.1.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
153
1
2
4
3 Figure 4.11 A digraph with walk of length 2 from any node to 1
directed walk from any vertex to vertex 1 in k = 2 steps. For example, from node 2 we can choose 2 → 1 and then 1 → 1, from node 1 we can choose 1 → 1 and then 1 → 1, etc. Hence, if Figure 4.11 is the digraph of a finite Markov model with transition matrix P, then α(P 2 ) > 0. Example 4.2.11: Consider the Markov dynamics suggested in Figure 1.10 on page 25. Although there are no weights, we can see that poor is accessible from every state in one step, so ℳ must be globally stable. In addition, poor is, by itself, an absorbing set. Hence, by Exericse 4.2.3, for any choice of weights compatible with these edges, the stationary distribution will concentrate all its mass on poor. remark 4.2.1 As was pointed out in the proof of Lemma 4.2.5, under the conditions of that lemma, we have P k (x,z) > 0 for all x ∈ S. This means that α(P k ) > 0 whenever P k has a strictly positive column.
4.2.3.3
Application: PageRank In §1.4.3 we discussed centrality measures for networks. Centrality measures provide a ranking of vertices in the network according to their “centrality” or “importance.” One of the most important applications of ranking of vertices in a network is ranking the importance of web pages on the internet. Historically, the most prominent example of a ranking mechanism for the internet is PageRank, which transformed Google from a minor start-up to a technology behemoth. In this section we provide a simple introduction to the original form of PageRank and connect it to previously discussed measures of centrality. Consider a finite collection of web pages W , and let L be the hyperlinks between them. We understand (W, L) as a digraph 𝒢, where W is the set of vertices and L is
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
154
Markov Chains and Networks
1
2
4
3 Figure 4.12 A digraph with walk of length 2 from any node to 1
the set of edges. Let A be the associated adjacency matrix, so that A(u,v) = 1 if there is a link from u to v and zero otherwise. We set n = |W |, so that A is n × n. To start our analysis, we consider the case where 𝒢 is strongly connected, such as the small network in Figure 4.12. Furthermore, we introduce a second matrix P in which each row of A has been normalized so that it sums to one. For the network in Figure 4.12, this means that 0 1/3 1/3 1/3 0 1 1 1 0 0 0 0 1 0 1 0 A= and P = . 0 0 0 0 0 1 0 1 1 0 0 0 1 0 0 0 Now consider an internet surfer who, once per minute, randomly clicks on one of the k outgoing links on a page, each link selected with uniform probability 1/k. The idea of PageRank is to assign to each page u ∈ W a value g(u) equal to the fraction of time that this surfer spends on page u over the long run. Intuitively, a high value for g(u) indicates a heavily visited and hence important site. The vector g is easy to compute, given our knowledge of Markov chains. Let ℳ be the finite Markov model associated with the random surfer, with state space W and adjacency matrix given by P. Since ℳ is strongly connected, the ergodicity theorem (page 145) tells us that P has a unique stationary distribution ψ∗ , and that the fraction of time the surfer spends at page u is equal to the probability assigned to u under the stationary distribution (see, in particular, (4.20)). Hence g = ψ∗ . As g is stationary and r (P) = 1, we can write g = (1/r (P))g P. Taking transposes gives g > = (1/r (P))P > g > . Comparing with (1.34) on page 43, we see that, for this simple case, the PageRank vector g is just the authority-based eigenvector centrality measure of ℳ. Thus, PageRank gives high ranking to pages with many inbound links, attaching high value to inbound links from pages that are themselves highly ranked. There are two problems with the preceding analysis. First, we assumed that the internet is strongly connected, which is clearly violated in practice (we need only one page with no outbound links). Second, internet users sometimes select pages without using hyperlinks, by manually entering the URL.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
155
The PageRank solution to this problem is to replace P with the so-called Google matrix 1 G := δ P + (1 − δ) 1, n where 1 is the n × n matrix of ones. The value δ ∈ (0,1) is called the damping factor. Exercise 4.2.10. Prove that G is a stochastic matrix for all δ ∈ (0,1). The Markov dynamics embedded in the stochastic matrix G can be understood as follows: The surfer begins by flipping a coin with heads probability δ. (See Exercise 1.3.6 and its solution for the connection between convex combinations and coin flips.) If the coin is heads, then the surfer randomly selects and follows one of the links on the current page. If not, then the surfer randomly selects and moves to any page on the internet. For given δ, the PageRank vector for this setting is adjusted to be the stationary distribution of the Google matrix G. Exercise 4.2.11. Verify that the digraph associated with the transition probabilities in G is always strongly connected (assuming, as above, that δ ∈ (0,1)). As a result of Exercise 4.2.11, we can always interpret the stationary of G as telling us the fraction of time that the surfer spends on each page in the long run. Exercise 4.2.12. Use (4.31) to obtain a rate of convergence of ψG t to the adjusted PageRank vector g ∗ (i.e., the unique stationary distribution g ∗ of G), where ψ is an arbitrary initial distribution on W . (Set k = 1.)
4.2.4
Information and Social Networks In recent years, the way that opinions spread across social networks has become a major topic of concern in many countries around the globe. A well-known mathematical model of this phenomenon is DeGroot learning, which was originally proposed in DeGroot (1974). This mechanism has linear properties that make it relatively easy to analyze (although large and complex underlying networks can cause significant challenges). In DeGroot learning, a group of agents, labeled from 1 to n, is connected by a social or information network of some type. Connections are indicated by a trust matrix T , where, informally, T (i, j) = amount that i trusts the opinion of j. In other words, T (i, j) is large if agent i puts a large positive weight on the opinion of agent j. The matrix T is assumed to be stochastic. We can view the trust matrix as an adjacency matrix for a weighed digraph 𝒮 with vertex set V := [n] and edges
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
156
Markov Chains and Networks
1.0
0.8
1
1 0.5
0.5 0.1
2
0.4
0.5
0.5 0.2
0.1
3
0.1
2
0.4
0.4
3
0.1
0.4
0.5
0.5
4
4
0.5
0.5
(a) Social network 𝒮a
(b) Social network 𝒮b
Figure 4.13 Two social networks
E = {(i, j) ∈ V × V : T (i, j) > 0}. Figure 4.13 shows two social networks 𝒮a and 𝒮b with trust matrices given by 0.8 0 0 0.2 1 0 0 0 0.5 0.1 0.4 0 0.5 0.1 0.4 0 Ta = , and Tb = 0.5 0.4 0.1 0 0.5 0.4 0.1 0 0 0.5 0 0.5 0 0.5 0 0.5 respectively. In network A, agent 1 places no trust in anyone’s opinion but their own. In network B, they place at least some trust in the opinion of agent 4. Below we show how these differences matter for the dynamics of beliefs.
4.2.4.1
Learning At time zero, all agents have an initial subjective belief concerning the validity of a given statement. Belief takes values in [0,1], with 1 indicating complete (subjective) certainty that the statement is true. Let b0 (i) be the belief of agent i at time zero. An agent updates beliefs sequentially based on the beliefs of others, weighted by the amount of trust placed in their opinion. Specifically, agent i updates their belief P after one unit of time to nj=1 T (i, j)b0 ( j). More generally, at time t + 1, beliefs update to bt+1 (i) =
n X
T (i, j)bt ( j)
(i ∈ V ).
(4.32)
j=1
In matrix notation this is bt+1 = T bt , where each bt is treated as a column vector. (Notice that this update rule is similar but not identical to the marginal distribution updating rule for Markov chains (the forward equation) discussed on page 136. Here we are postmultiplying by a column vector rather than premultiplying by a row vector.)
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.2 Asymptotics
157
Exercise 4.2.13. If some subgroup of agents U ⊂ V is an absorbing set for the digraph 𝒮, indicating that members of this group place no trust in outsiders, then the initial beliefs {b0 (i)}i∈U c of the outsiders (members of U c = V \ U ) have no influence on the beliefs of the insiders (members of U ) at any point in time. Prove that this is true.
4.2.4.2
Consensus A social network 𝒮 is said to lead to consensus if |bt (i) − bt ( j)| → 0 as t → ∞ for all i, j ∈ V . Consensus implies that all agents eventually share the same belief. An important question is, what conditions on the network lead to a consensus outcome? proposition 4.2.6 If there exists a k ∈ N such that α(T k ) > 0, then consensus is obtained. In particular, |bt (i) − bt ( j)| 6 2(1 − α(T k ))bt/kc
for all t ∈ N and i, j ∈ V .
(4.33)
Proof Fix i, j ∈ V and t ∈ N. Let b = b0 . For any ϕ,ψ ∈ 𝒟(V ), an application of the triangle inequality gives X X X (ϕT t )( j) − (ψT t )( j) , |ϕT t b−ψT t b| = (ϕT t )( j)b( j) − (ψT t )( j)b( j) 6 j j j where we have used the fact that |b( j)| = b( j) 6 1. Applying the definition of the `1 deviation and (4.30), we obtain the bound |ϕT t b − ψT t b| 6 (1 − α(T k ))bt/kc ρ(ϕ,ψ) 6 2(1 − α(T k ))bt/kc .
(4.34)
Since this bound is valid for any choice of ϕ,ψ ∈ 𝒟(V ), we can specialize to ϕ = δi and ψ = δ j and, applying T t b = bt , we get |bt (i) − bt ( j)| = |δi T t b − δ j T t b| 6 2(1 − α(T k ))bt/kc . Proposition 4.2.6 can be applied to the two social networks 𝒮a and 𝒮b in Figure 4.13. For example, in network 𝒮a , for every node i, there exists a walk of length 2 from node i to node 1. Hence, by Lemma 4.2.5, we have α(T 2 ) > 0. In network 𝒮b , the same is true. Exercise 4.2.14. Let 𝒮 be a social network with trust (and adjacency) matrix T . Use Proposition 4.2.6 to show that 𝒮 leads to consensus whenever 𝒮 is strongly connected and aperiodic.
4.2.4.3
Influence of Authorities Now let’s consider what beliefs converge to when consensus emerges. In particular, we are interested in discovering whose opinions are most influential under DeGroot learning, for a given trust matrix.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
158
Markov Chains and Networks
To answer the question, let 𝒮 be a given social network with trust matrix T . Suppose that α(T k ) > 0 for some k ∈ N. By Theorem 4.2.4, the network 𝒮 is globally stable when viewed as a finite Markov model. Let ψ∗ be the unique stationary distribution, so that ψ∗ = ψ∗ T . Applying (4.34) with ϕ = δi and ψ = ψ∗ yields bt (i) − b∗ 6 (1 − α(T k ))bt/kc ρ(ϕ,ψ) 6 2(1 − α(T k ))bt/kc, where b∗ :=
X
ψ∗ ( j)b0 ( j).
j∈V
We conclude that the belief of every agent converges geometrically to b∗ , which is a weighted average of the initial beliefs of all agents. In particular, those agents with high weighting under the stationary distribution have a large influence on these equilibrium beliefs. We can interpret this through notions of centrality. Since r (T ) = 1, we have (ψ∗ )> = (1/r (T ))T > (ψ∗ )> , so ψ∗ is the authority-based eigenvector centrality measure on 𝒮. Thus, the influence of each agent on long-run beliefs is proportional to their authority-based eigenvector centrality. This makes sense because such agents are highly trusted by many agents who are themselves highly trusted. Exercise 4.2.15. For network 𝒮a in Figure 4.13, show that b∗ = b0 (1). That is, all agents’ beliefs converge to the belief of agent 1. Exercise 4.2.16. Using a computer, show that the stationary distribution for 𝒮b , rounded to two decimal places, is ψ∗ = (0.56,0.15,0.07,0.22). (Notice how the relatively slight change in network structure from 𝒮a to 𝒮b substantially reduces the influence of agent 1.)
4.3
Chapter Notes High quality treatments of finite-state Markov dynamics include Norris (1998), Häggström et al. (2002), and Privault (2013). For the general state case see Meyn and Tweedie (2009). A review of DeGroot learning is available in Jackson (2010). Some interesting extensions related to the “wisdom of crowds” phenomenon are provided in Golub and Jackson (2010). Molavi et al. (2018) provide a theory of social learning that includes DeGroot learning as a special case. Acemoglu et al. (2021a) study misinformation and echo chambers in information networks. Board and Meyer-ter Vehn (2021) analyze learning dynamics in continuous time on large social networks. Shiller (2020) provides an interesting discussion of how ideas spread across social networks and shape economic outcomes. In a large-scale empirical study, Chetty et al. (2022)
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
4.3 Chapter Notes
159
analyze how cross-class friendships influence social mobility. Acemoglu et al. (2023) consider the effect of strong and weak links on Bayesian learning in a social network. Dasaratha et al. (2022) analyze how Bayesian agents learn about a changing state by interacting with their neighbors. While the resulting dynamics are similar to those of the DeGroot model, they are generated as an equilibrium outcome rather than imposed as a behavioral assumption.
https://doi.org/10.1017/9781009456340.006 Published online by Cambridge University Press
5
Nonlinear Interactions
Much of what makes network analysis interesting is how ramifications of choices flow across networks. In general, decisions made at a given node i affect responses of neighboring nodes and, through them, neighbors of neighboring nodes, and so on. As these consequences flow across the network, they in turn affect choices at i. This is a tail-chasing scenario, which can be unraveled through fixed point theory. In some network settings, such as the input–output model in §2.1, interactions are linear, and fixed point problems reduce to a system of linear equations. In other settings, interactions are inherently nonlinear, and, as a result, we need more sophisticated fixed point theory. This chapter is dedicated to the study of networks with nonlinear interactions. We begin with relevant fixed point theory and then apply it to a sequence of problems that arise in the analysis of economic networks, including production models with supply constraints and financial networks.
5.1
Fixed Point Theory Let S be any set. Recall from §A.1.6 that, given a self-map G on S, a point x ∈ S is called a fixed point of G if Gx = x. (A self-map on S is a function G from S to itself. When working with self-maps, it is common to abbreviate G(x) to Gx.) In this chapter, we will say that G is globally stable on S if G has a unique fixed point x ∗ ∈ S, and G k x → x ∗ as k → ∞ for all x ∈ S. In other words, under this property, the fixed point is not only unique but also globally attracting under iteration of G. We have already discussed fixed points, indirectly or directly, in multiple contexts: • In Chapter 2 we studied the equation x = Ax + d, where x is an output vector, A is a matrix of coefficients, and d is a demand vector. A solution x to this equation can also be thought of as a fixed point of the affine map F x = Ax + d. In Chapter 4 we learned that a stationary distribution of a finite Markov model • with state space S and adjacency matrix P is a ψ ∈ 𝒟(S) with ψ = ψ P. In other words, ψ is a fixed point of ψ 7→ ψ P in 𝒟(S). • In Chapter 3 we studied the Bellman equation q(x) = min y∈𝒪(x) {c(x, y) + q(y)} and introduced an operator, the Bellman operator T , with the property that its fixed points exactly coincide with solutions to the Bellman equation.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.1 Fixed Point Theory
161
In each case, when we introduced these fixed point problems, we immediately needed to consider questions of the existence and uniqueness of fixed points. Now we address these same issues more systematically in an abstract setting.
5.1.1
Contraction Mappings In Chapter 2 we studied solutions of the system x = Ax + b that are fixed points of the affine map F x = Ax + b on Rn studied in Example 5.1.1. The Neumann series lemma on page 11 is, in essence, a statement about the existence and uniqueness of fixed points of this map. Here we investigate another fixed point theorem, due to Stefan Banach (1892–1945), that can be thought of as extending the Neumann series lemma to nonlinear systems.
5.1.1.1
Contractions Let S be a nonempty subset of Rn . A self-map F on S is called contracting or a contraction of modulus λ on S if there exist a λ < 1 and a norm k · k on Rn such that kFu − Fvk 6 λku − vk for all u,v ∈ S.
(5.1)
Exercise 5.1.1. Let F be a contraction of modulus λ on S. Show that (i) F is continuous on S and (ii) F has at most one fixed point on S. Example 5.1.1: Let S = Rn , paired with the Euclidean norm k · k. Let F x = Ax + b, where A ∈ Mn×n and b ∈ Rn . If kAk < 1, where k · k is the operator norm on Mn×n , then F is a contraction of modulus kAk, since, for any x, y ∈ S, kAx + b − Ay − bk = kA(x − y)k 6 kAkkx − yk. The next example uses a similar idea but is based on a different norm. Example 5.1.2: In (2.22) we studied the system ρ = A> ρ − ε, where A = (ai j ) is a P matrix of coefficients satisfying i ai j = 1 − α for some α ∈ (0,1), the vector ε is given, and ρ is unknown. Solutions can be viewed as fixed points of the map F : Rn → Rn defined by F p = A> p − ε. Under the k · k∞ norm, F is a contraction of modulus 1 − α on Rn . Indeed, for any p,q ∈ Rn , n n X X kF p − Fqk∞ = max ai j ( pi − qi ) 6 max ai j | pi − qi | . j j i=1
i=1
Since | pi − qi | 6 k p − qk∞ , we obtain kF p − Fqk∞ 6 max j
n X
ai j k p − qk∞ = (1 − α)k p − qk∞ .
i=1
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
162
Nonlinear Interactions
Consider again Example 5.1.1. For the affine map F x = Ax + b, the condition kAk < 1 used to obtain contraction is stronger than the condition r (A) < 1 used to obtain a unique fixed point in the Neumann series lemma (see Exercise 2.3.11 on page 82). Furthermore, the Neumann series lemma provides a geometric series representation of the fixed point. On the other hand, as we now show, the contraction property can be used to obtain unique fixed points when the map in question is not affine.
5.1.1.2
Banach’s Theorem The fundamental importance of contractions stems from the following theorem. theorem 5.1.1 (Banach’s contraction mapping theorem) If S is closed in Rn and F is a contraction of modulus λ on S, then F has a unique fixed point u ∗ in S, and kF n u − u ∗ k 6 λ n ku − u ∗ k for all n ∈ N and u ∈ S.
(5.2)
In particular, F is globally stable on S. We complete a proof of Theorem 5.1.1 in stages. Exercise 5.1.2. Let S and F have the properties stated in Theorem 5.1.1. Fix u 0 ∈ S and let u m := F m u 0 . Show that ku m − u k k 6
k−1 X
λi ku 0 − u 1 k
i=m
holds for all m,k ∈ N with m < k. Exercise 5.1.3. Using the results in Exercise 5.1.2, prove that (u m ) is a Cauchy sequence in Rn (see §A.3.2 for notes on the Cauchy property). Exercise 5.1.4. Using Exercise 5.1.3, argue that (u m ) hence has a limit u ∗ ∈ Rn . Prove that u ∗ ∈ S. Proof of Theorem 5.1.1 In the exercises we proved the existence of a point u ∗ ∈ S such that F m u → u ∗ . The fact that u ∗ is a fixed point of F now follows from Lemma A.3.4 on page 194 and Exercise 5.1.1. Uniqueness is implied by Exercise 5.1.1. The bound (5.2) follows from iteration on the contraction inequality (5.1) while setting v = u∗.
5.1.1.3
Eventual Contractions Let S be a nonempty subset of Rn . A self-map F on S is called eventually contracting if there exists a k ∈ N such that F k is a contraction on S. Significantly, most of the conclusions of Banach’s theorem carry over to the case where F is eventually contracting.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.1 Fixed Point Theory
163
theorem 5.1.2 Let F be a self-map on S ⊂ Rn . If S is closed and F is eventually contracting, then F is globally stable on S. Exercise 5.1.5. Prove Theorem 5.1.2.1 There is a close connection between Theorem 5.1.2 and the Neumann series lemma (NSL). If S = Rn and F x = Ax + b with r (A) < 1, then the NSL implies a unique fixed point. We can also obtain this result from Theorem 5.1.2, since, for any k ∈ N, kF k x − F k yk = kAk x − Ak yk = kAk (x − y)k 6 kAk kkx − yk. As r (A) < 1, we can choose k such that kAk k < 1 (see §2.3.3). Hence F is eventually contracting, and Theorem 5.1.2 applies. As mentioned above, contractions and eventual contractions have much wider scope than the NSL, since they can also be applied in nonlinear settings. At the same time, the NSL is preferred when its conditions hold, since it also gives inverse and power series representations of the fixed point.
5.1.1.4
A Condition for Eventual Contractions The result below provides a useful test for the eventual contraction property. (In the statement, the absolute value of a vector is defined pointwise, as in §A.2.2.) proposition 5.1.3 matrix A,
Let F be a self-map on S ⊂ Rn such that, for some n × n |F x − F y| 6 A|x − y| for all x, y ∈ S.
If, in addition, A > 0 and r (A) < 1, then F is eventually contracting on S with respect to the Euclidean norm. Proof Our first claim is that, under the conditions of the proposition, |F k x − F k y| 6 Ak |x − y| for all k ∈ N and x, y ∈ S.
(5.3)
This is true at k = 1 by assumption. If it is true at k − 1, then |F k x − F k y| 6 A|F k−1 x − F k−1 y| 6 A Ak−1 |x − y|,
(5.4)
where the second inequality uses the induction hypothesis and A > 0 (so that u 6 v implies Au 6 Av). Hence (5.3) holds. It follows from the definition of the Euclidean norm that k|u|k = kuk for any vector u. Also, for the same norm, |u| 6 |v| implies kuk 6 kvk. Hence, for all k ∈ N and x, y ∈ S, kF k x − F k yk 6 kAk |x − y|k 6 kAk ko kx − yk. 1 Hint: Theorem 5.1.1 is self-improving: It implies this seemingly stronger result. The proof is not trivial, but see if you can get it started. You might like to note that F k has a unique fixed point u ∗ in S. (Why?) Now consider the fact that kFu ∗ − u ∗ k = kF F nk u ∗ − u ∗ k for all n ∈ N.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
164
Nonlinear Interactions
In the second inequality, we used k · ko for the operator norm, combined with the fact that kAuk 6 kAko kuk always holds, as discussed in §2.3.2.3. By Gelfand’s lemma (see in particular Exercise 2.3.18 on page 83), we obtain the existence of a λ ∈ (0,1) and a k ∈ N with kAk ko 6 λ < 1. Hence, for this k, kF k x − F k yk 6 λkx − yk. Since λ does not depend on x or y, we have shown that F is an eventual contraction on S with respect to the Euclidean norm.
5.1.2
Shortest Paths Revisited Consider again the shortest path problem introduced in §3.1. One modification that sometimes appears in applications is the addition of discounting during travel between vertices. For example, if the vertices are international ports and travel takes place by sea, then port-to-port travel time is measured in weeks or even months. It is natural to apply time discounting to future costs associated with that travel, to implement the idea that paying a given dollar amount in the future is preferable to paying it now. Exercise 5.1.6. Suppose it is possible to borrow and lend risk-free at a positive interest rate r . Explain why it is always preferable to have $100 now than $100 in a year’s time in this setting. Recall that, without discounting, the Bellman equation for the shortest path problem takes the form q(x) = min y∈𝒪(x) {c(x, y) + q(y)} for all x ∈ V , where c is the cost function, V is the set of vertices, and q is a candidate for the cost-to-go function. We showed that the minimum cost-to-go function q ∗ satisfies the Bellman equation and is the unique fixed point of the Bellman operator. The Bellman equation neatly divides the problem into current costs, embedded in the term c(x, y), and future costs embedded in q(y). To add discounting, we need only discount q(y). We do this by multiplying it by a discount factor β ∈ (0,1). The Bellman equation is then q(x) = min y∈𝒪(x) {c(x, y) + βq(y)} for all x ∈ V , and the Bellman operator is T q(x) = min {c(x, y) + βq(y)} y∈𝒪(x)
(x ∈ V ).
(5.5)
In §3.1.2, without discounting, we had to work hard to show that the Bellman operator has a unique fixed point in U , the set of all q : V → R+ with q(d) = 0. With discounting, the proof is easier, since we can leverage the Banach contraction mapping theorem. In what follows, we identify the vertices in V with integers 1, . . . ,n, where d is identified with n. We then understand U as all nonnegative vectors q in Rn with q(n) = 0. (We continue to write q(x) for the x-th element of the vector q, but now x is in [n].)
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.1 Fixed Point Theory
165
Exercise 5.1.7. Prove that U is a closed subset of Rn . Exercise 5.1.8. Prove that T is order-preserving on U with respect to the pointwise order. Exercise 5.1.9. Prove that, for any q ∈ U and α ∈ R+ , we have T (q + α1) = T q + βα1. Now let k · k∞ be the supremum norm on Rn (see §2.3.1). We claim that T is a contraction on U of modulus β. To see that this is so, fix p,q ∈ U and observe that, pointwise, T q = T ( p + q − p) 6 T ( p + kq − pk∞ 1) 6 T p + βkq − pk∞ 1, where the first inequality is by the order-preserving of T , and the second follows from Exercise 5.1.9. Hence T q − T p 6 βkq − pk∞ 1. Reversing the roles of p and q gives the reverse inequality. Hence |T q(x) − T p(x)| 6 βkq − pk∞ for all x ∈ [n]. Taking the maximum on the left-hand side yields kT q − T pk∞ 6 βkq − pk∞ , which shows that T is a contraction of modulus β. Hence Banach’s theorem applies, and a unique fixed point exists.
5.1.3
Supply Constraints While the input–output model from §2.1.2 has many useful applications, its linear structure can be a liability. One natural objection to linearity is supply constraints: if sector j doubles its orders from sector i, we cannot always expect that sector i will quickly meet this jump in demand. In this section we investigate the impact of supply constraints on equilibrium. These constraints introduce nonlinear relationships between nodes that affect equilibria and make analysis more challenging. We recall from §2.1.2 that di is the final demand for good i, xi is the total sales of sector i, z i j is the inter-industry sales from sector i to sector j, and ai j = z i j /x j is the dollar value of inputs from i per dollar output from j. Departing from our previous formulation of equilibrium in the input–output model, suppose that, in the short run, the total output value of sector i is constrained by a positive constant x(i). ¯ Holding prices fixed (in the short run), this means that sector i has a capacity constraint in terms of unit output. For the purposes of our model, the n vector of capacity constraints x¯ := (x(i)) ¯ i=1 can be any vector in Rn+ .
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
166
Nonlinear Interactions
For each sector i, we modify the accounting identity (2.1) from page 56 to n X xi = min oi j + di , x(i) ¯ ,
(5.6)
j=1
where oi j is the value of orders from sector i made by sector j. Thus, if the capacity constraint in sector i is not binding, then output is the sum of orders from other sectors and orders from final consumers. If x(i) ¯ is less than this sum, however, then sector i produces to capacity x(i). ¯ An equilibrium for this model is one where all orders are met, subject to capacity constraints. The fact that orders are met means that oi j = z i j = ai j x j . Substituting this equality into (5.6) and rewriting as a vector equality, (5.6) can equivalently be formulated as x = Gx,
where
Gx := (Ax + d) ∧ x. ¯
(5.7)
The following exercise is key to solving the fixed point problem (5.7). Exercise 5.1.10. Prove that, for any x, y ∈ Rn+ and k ∈ N, we have |Gx − Gy| 6 A|x − y|.
(5.8)
We are now ready to prove the existence of a unique fixed point under the assumption that every sector has positive value added. proposition 5.1.4 If Assumption 2.1.1 holds, then G is globally stable in Rn+ . In particular, the constrained production model has a unique equilibrium x ∗ ∈ Rn+ . Proof As shown in Exercise 2.1.2, Assumption 2.1.1 yields r (A) < 1. Moreover, A > 0. Hence, by Exercise 5.1.10 and Proposition 5.1.3, G is eventually contracting on R+ . In consequence, a unique equilibrium exists. remark 5.1.1 In Proposition 5.1.4, the weaker conditions on production discussed in §2.3.4.1 can be used in place of Assumption 2.1.1, which requires positive value added in every sector. As explained in §2.3.4.1, for r (A) < 1 it is enough that value added is nonnegative in each sector and, in addition, every sector has an upstream supplier with positive value added.
5.1.4
Fixed Points and Monotonicity Banach’s fixed point theorem and its extensions are foundations of many central results in pure and applied mathematics. For our purposes, however, we need to search a little further, since not all mappings generated by network models have the contraction property. In this section, we investigate two fixed point results that drop contractivity in favor of monotonicity.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.1 Fixed Point Theory
5.1.4.1
167
Existence Without contractivity, one needs to work harder to obtain even existence of fixed points, let alone uniqueness and convergence. This is especially true if the map in question fails to be continuous. If, however, the map is order-preserving, then existence can often be obtained via some variation on the Knaster–Tarski fixed point theorem. Here we present a version of this existence result that is optimized to our setting, while avoiding unnecessary excursions into order theory. In stating the theorem, we recall that a closed order interval in Rn is a set of the form [a,b] := {x ∈ Rn : a 6 x 6 b}, where a and b are vectors in Rn . Also, we call (xk ) ⊂ Rn increasing (resp., decreasing) if xk 6 xk+1 (resp., xk > xk+1 ) for all k. Exercise 5.1.11. Let [a,b] be a closed order interval in Rn , and let G be an orderpreserving self-map on [a,b]. Prove the following: (i) (G k a) is increasing and (G k b) is decreasing. (ii) If x is a fixed point of G in [a,b], then G k a 6 x 6 G k b for all k ∈ N. For a self-map G on S ⊂ Rn , we say that x ∗ is a least fixed point (resp., greatest fixed point) of G on S if x ∗ is a fixed point of G in S and x ∗ 6 x (resp., x 6 x ∗ ) for every fixed point x of G in S. Finally, we say that G is • continuous from below if xk ↑ x in S implies Gxk ↑ Gx in S; • continuous from above if xk ↓ x in S implies Gxk ↓ Gx in S. Here xk ↑ x means that (xk ) is increasing and xk → x. The definition of xk ↓ x is analogous. In the next theorem, S := [a,b] is a closed order interval in Rn , and G is a self-map on S. theorem 5.1.5 If G is order-preserving on S, then G has a least fixed point x ∗ and a greatest fixed point x ∗∗ in S. Moreover, (i) if G is continuous from below, then G k a ↑ x ∗ ; and (ii) if G is continuous from above, then G k b ↓ x ∗∗ . remark 5.1.2 As alluded to above, fixed point results for order-preserving maps can be obtained in more general settings than the ones used in Theorem 5.1.5 (see, e.g., Davey and Priestley (2002), Theorem 2.35). Theorem 5.1.5 is sufficient for our purposes, given our focus on finite networks. Proof of Theorem 5.1.5 Under the stated conditions, the existence of least and greatest fixed points x ∗ and x ∗∗ follows from the Knaster–Tarski fixed point theorem. (This holds because [a,b] is a complete lattice. For a definition of complete lattices and a proof of the Knaster–Tarski theorem, see, e.g., Davey and Priestley (2002).)
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
168
Nonlinear Interactions
Regarding claim (i), suppose that G is continuous from below, and consider the sequence (xk ) := (G k a)k>1 . Since G is order-preserving (and applying Exercise 5.1.11), this sequence is increasing and bounded above by x ∗ . Since bounded monotone sequences in R converge, each individual component of the vector sequence x k converges in R. Hence, by Lemma 2.3.1, the vector sequence x k converges in Rn to some x¯ ∈ [a,x ∗ ]. Finally, by continuity from below, we have x¯ = lim G k a = lim G k+1 a = G lim G k a = G x, ¯ k
k
k
so that x¯ is a fixed point. We have now shown that (G k a) converges up to a fixed point x¯ of G satisfying x¯ 6 x ∗ . Since x ∗ is the least fixed point of G in S, we also have x ∗ 6 x. ¯ Hence ∗ x¯ = x . The proof of claim (ii) is similar to that of claim (i) and is hence omitted. remark 5.1.3 In the preceding theorem, x ∗ and x ∗∗ can be equal, in which case G has only one fixed point in S. Exercise 5.1.12. Consider the map Gx = (Ax + d) ∧ x¯ from the constrained production model. In §5.1.3, we showed that G has a unique fixed point in Rn+ when r (A) < 1. Show now that G has at least one fixed point in Rn+ , even when r (A) < 1 fails. (Continue to assume that A > 0, d > 0, and x¯ > 0.)
5.1.4.2
Du’s Theorem Theorem 5.1.5 is useful because of its relatively weak assumptions. At the same time, it fails to deliver uniqueness. Hence its conclusions are considerably weaker than the results we obtained from contractivity assumptions in §5.1.1. In order to recover uniqueness without imposing contractivity, we now consider order-preserving maps that have additional shape properties. In doing so, we use the definition of concave and convex functions in §A.5.2. theorem 5.1.6 (Du) Let G be an order-preserving self-map on order interval S = [a,b] ⊂ Rn . In this setting, if either (i) G is concave and Ga a or (ii) G is convex and Gb b, then G is globally stable on S. A proof of Theorem 5.1.6 was obtained in a more abstract setting in Du (1990). Interested readers can consult that article for a proof. To illustrate how these results can be applied, consider the constrained production model without assuming positive value added, so that r (A) < 1 is not enforced. In Exercise 5.1.12 we obtained existence. With Theorem 5.1.6 in hand, we can also show uniqueness whenever d 0 and x¯ 0.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.2 Financial Networks
169
Indeed, we have already seen that G is a self-map on S := [0, x], ¯ and when this last condition holds, we have G0 = d ∧ x¯ 0. Hence the conclusions of Theorem 5.1.6 will hold if we can establish that G is concave. Exercise 5.1.13. Prove that G is concave on S. [Hint: Review §A.5.2.] Here is a small extension of Du’s theorem that will prove useful soon: corollary 5.1.7 Let G be an order-preserving self-map on S = [a,b]. If G is concave and there exists an ` ∈ N such that G ` a a, then G is globally stable on S. Proof Assume the conditions of Corollary 5.1.7. Since compositions of increasing concave operators are increasing and concave, Theorem 5.1.6 implies that G ` is globally stable on [a,b]. Denote its fixed point by v¯ . Since {G m a}m∈N is increasing and since the subsequence {G m` a}m∈N converges up to v¯ as m → ∞, we must have G m a → v¯ . A similar argument gives G m b → v¯ . For any v ∈ [a,b] we have G m a 6 G m v 6 G m b, so G m v → v¯ as m → ∞. The last step is to show that v¯ is the unique fixed point of G. From Theorem 5.1.5, we know that at least one fixed point exists. Now suppose v ∈ [a,b] is such a point. Then v = G m v for all m. At the same time, G m v → v¯ by the results just established. Hence v = v¯ . The proof is now complete.
5.2
Financial Networks Given the long history of crises in financial markets around the globe, economists and business analysts have developed many tools for assessing the credit-worthiness of banks and other financial institutions. After the major financial crisis of 2007–2008, originating in the subprime market in the USA and the sudden collapse of Lehmann Brothers, it became clear that the financial health of individual institutions cannot be assessed in isolation. Rather, it is essential to analyze solvency and credit-worthiness in terms of the entire network of claims and liabilities within a highly interconnected financial system. In this section, we review financial crises and apply network analysis to study how they evolve.
5.2.1
Contagion Some financial crises have obvious causes external to the banking sector. A prominent example is the hyperinflation that occurred in Weimar Germany around 1921–1923, which was driven by mass printing of bank notes to meet war reparations imposed under the Treaty of Versailles. Here the monetary authority played the central role, while the actions of private banks were more passive. Other crises seem to form within the financial sector itself, driven by interactions between banks, hedge funds, and asset markets. In many cases, the crisis follows a
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
170
Nonlinear Interactions
boom, where asset prices rise and economic growth is strong. Typically, the seeds of the crisis are laid during this boom phase, when banks extend loans and firms raise capital on the basis of progressively more speculative business plans. At some point it becomes clear to investors that these businesses will fail to meet expectations, leading to a rush for the exit. The last phase of this cycle is painful for the financial sector, since rapidly falling asset values force banks and other financial institutions to generate short-term capital by liquidating long-term loans, typically with large losses, as well as selling assets in the face of falling prices, hoarding cash, and refusing to roll over or extend short-term loans to other institutions in the financial sector. The financial crisis of 2007–2008 provides a textbook example of these dynamics. One key aspect of the financial crisis of 2007–2008, as well as other similar crises, is contagion, which refers to the way that financial stress spreads across a network of financial institutions. If one institution becomes stressed, that stress will often spread to investors or counterparties to which this institution is indebted. The result of this process is not easy to predict, since, like equilibrium in the production networks studied in Chapter 2, there is a tail-chasing problem: Stress spreads from institution A to institutions B, C, and D, which may in turn increase stress on A, and so on. In this section we study financial contagion, beginning with a now-standard model of default cascades.
5.2.2
Default Cascades Default cascades are a form of financial contagion, in which default by a node in a network leads to default by some of its counterparties, which then spreads across the network. Below we present a model of default cascades and analyze its equilibria.
5.2.2.1
Network Valuation Consider a financial network 𝒢 = (V , E,w), where V = [n] is a list of n financial institutions called banks, with an edge (i, j) ∈ E indicating that j has extended credit to i. The size of that loan is w(i, j). Thus, an edge points in the direction of a liability, as in Figure 1.17 on page 35: Edge (i, j) indicates a liability for i and an asset for j. As in §1.4.1, the set of all direct predecessors of i ∈ V will be written as ℐ(i), while the set of all direct successors will be denoted 𝒪(i). Banks in the network have both internal and external liabilities, as well as internal and external assets. Internal (i.e., inter-bank) liabilities and assets are given by the weight function w, in the sense that w(i, j) is a liability for i, equal to the size of its loan from j, and also an asset for j. Positive weights indicate the presence of counterparty risk: When j holds an asset of book value w(i, j), whether or not the loan is repaid in full depends on the stress placed on bank i and rules that govern repayment in the event of insolvency.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.2 Financial Networks
171
P
j∈𝒪(i) w(i, j)
We use the following notation for the primitives of the model: xi := is total inter-bank liabilities of bank i, ( w(i, j)/xi if xi > 0 5i j := 0 otherwise
(5.9)
is the matrix of relative inter-bank liabilities, ai is external assets held by bank i, and di is external liabilities. When considering the inter-bank assets of bank j, we need to distinguish between P the book value i∈ℐ( j) w(i, j) of its claims on other banks and the realized value in the face of partial or complete default by its counterparties ℐ( j). To this end, we introduce a clearing vector p ∈ Rn+ , which is a list of proposed payments by each bank in the network. In particular, pi is total payments made by bank i to its counterparties within the banking sector. Under the choice of a particular clearing vector, the actual P payments received by bank j on its internal loan portfolio are i∈V pi 5i j . The last statement is an assumption about the legal framework for the banking sector. It means that the actual payment pi 5i j from i to j is proportional to the amount that i owes j, relative to its total inter-bank obligations. The idea is that all counterparties in the banking sector have equal seniority, so that residual funds are spread across claimants according to the relative size of the claims. Let pˆ j be the amount of funds bank j makes available to repay all of its debts, both inter-bank and external. This quantity is ( ) X pˆ j = min a j + pi 5i j , d j + x j . (5.10) i∈V
The right-hand term inside the min operator is the total debts of bank j. The lefthand side is the amount on hand to repay those debts, including external assets and repayments by other banks. The bank repays up to – but not beyond – its ability to pay. External liabilities are assumed to be senior to inter-bank liabilities, which means that for bank j we also have p j = max{ pˆ j − d j , 0}.
(5.11)
Thus, inter-bank payments by j are a remainder after external debts are settled. If these debts exceed the bank’s ability to pay, the bank becomes insolvent and pays nothing to internal creditors. This is a form of limited liability. Combining (5.10) and (5.11) and rearranging slightly yields ( ( ) ) X p j = max min a j − d j + pi 5i j , x j , 0 . i∈V
Now let’s take p, a, d, and x as row vectors in Rn and write this collection of equations, indexed by j, in vector form. With max and min taken pointwise, and using the symbols ∨ and ∧ for max and min, we get
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
172
Nonlinear Interactions
p = ((a − d + p5) ∧ x) ∨ 0.
(5.12)
A solution to this equation is called an equilibrium clearing vector for the banking system. remark 5.2.1 An equilibrium clearing vector captures the impacts of contagion within the specified banking system, in the sense that it traces out the full network effects of inter-bank lending within the model. We shall study this equilibrium while also recognizing that the model is restrictive in the sense that it assumes a specific form for seniority and implicitly rules out some kinds of nonlinear phenomena. We return to this theme in §5.2.3.
5.2.2.2
Existence and Uniqueness of Fixed Points In order to analyze the existence and uniqueness of equilibria, we introduce the operator T : Rn → Rn defined by T p = ((e + p5) ∧ x) ∨ 0,
(5.13)
where e := a − d represents net external assets. Evidently p ∈ Rn+ is an equilibrium clearing vector if and only if it is a fixed point of T . Exercise 5.2.1. Prove that the operator T is continuous on Rn . Using this operator, establishing the existence of at least one equilibrium clearing vector is not problematic for this model, regardless of the values of the primitives and configuration of the network: Exercise 5.2.2. Show that the banking model described above always has at least one equilibrium clearing vector. What else can you say about equilibria in this general case? While existence is automatic in this model, uniqueness is not: 0 Example 5.2.1: If n = 2, e = (0,0) and (1,1) and 5 = 1 equivalent to ! ! ! p1 p2 1 = ∧ . p2 p1 1
! 1 , then T p = p is 0
Both p = (1,1) and p = (0,0) solve this equation. There are several approaches to proving the uniqueness of fixed points of T . Here is one: Exercise 5.2.3. Prove that T is globally stable on S := [0,x] whenever r (5) < 1.2 2 Here’s a hint, if you get stuck: Show that r (5) < 1 implies T is an eventual contraction on [0,x] using
one of the propositions presented in this chapter.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.2 Financial Networks
173
This leads us to the following result: proposition 5.2.1 Let 𝒢 be a financial network. If, for each bank i ∈ V , there exists a bank j ∈ V with i → j and such that j has zero inter-bank liabilities, then T is globally stable on S, and 𝒢 has a unique equilibrium clearing vector. Proof By construction, the matrix 5 is substochastic. Suppose that 5 is also weakly chained substochastic. Then, by Proposition 2.3.5, we have r (5) < 1, and, by Exercise 5.2.3, T is globally stable on S. Hence the proof will be complete if we can show that, under the stated conditions, 5 is weakly chained substochastic. To see that this is so, let 𝒢 be a financial network that satisfies the conditions of Proposition 5.2.1. Now fix i ∈ V . We know that there exists a bank j ∈ V with i → j and j has no inter-bank liabilities. If w(i, j) > 0, then 5i j > 0, so i → j under digraph 𝒢 implies i → j in the digraph induced by the substochastic matrix 5. Also, since j has no inter-bank liabilities, we have x j = 0, and hence row j of 5 is P identically zero. In particular, k 5 jk = 0. Hence 5 is weakly chained substochastic, as required. remark 5.2.2 The proof of Proposition 5.2.1 also shows that T is eventually contracting, so we can compute the unique fixed point by taking the limit of T k p for any choice of p ∈ S. There are several possible assumptions about the structure of the bank network 𝒢 that imply the conditions of Proposition 5.2.1. For example, it would be enough that 𝒢 is strongly connected and has at least one bank with zero inter-bank liabilities. Below we investigate another sufficient condition, related to cyclicality. Exercise 5.2.4. Let 𝒢 be a financial network. Show that 𝒢 has a unique equilibrium clearing vector whenever 𝒢 is a directed acyclic graph.
5.2.2.3
Nonnegative External Equity In this section we investigate the special case in which (E1) each bank has nonzero inter-bank debt, so that 5 is a stochastic matrix, and (E2) external net assets are nonnegative, in the sense that e = a − d > 0. In view of (E1), we cannot hope to use Proposition 5.2.1, since we always have r (5) = 1 when 5 is stochastic. Nonetheless, we can still obtain global stability under certain restrictions on e and the topology of the network. Here is a relatively straightforward example, which we will later try to refine: Exercise 5.2.5. Let 𝒢 be a financial network such that (E1) and (E2) hold. Using Du’s theorem (page 168), prove that T has a unique fixed point in S := [0,x] whenever e 0.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
174
Nonlinear Interactions
The condition e 0 is rather strict. Fortunately, it turns out that we can obtain global stability under significantly weaker conditions. To this end, we will say that node j in a financial system 𝒢, is cash accessible if there exists an i ∈ V such that i → j and e(i) > 0. In other words, j is downstream in the liability chain from at least one bank with positive net assets outside of the banking sector. Exercise 5.2.6. Prove the following result: If (E1) and (E2) hold and every node in 𝒢 is cash-accessible, then T k 0 0 for some k ∈ N. (This is a relatively challenging exercise.) With the result from Exercise 5.2.6 in hand, the next lemma is easy to establish. lemma 5.2.2 If (E1) and (E2) hold and every node in 𝒢 is cash accessible, then T is globally stable and 𝒢 has a unique clearing vector p ∗ 0. Proof Let 𝒢 be as described. By Corollary 5.1.7, it suffices to show that T is an orderpreserving concave self-map on [0,x] with T k 0 0 for some k ∈ N. The solution to Exercise 5.2.5 shows that T is order-preserving and concave. The existence of a k ∈ N with T k 0 0 was verified in Exercise 5.2.6. Stronger results are available, with a small amount of effort. In fact, under (E1) and (E2), there is a strong sense in which uniqueness of the fixed point is obtained without any further assumptions, provided that we rule out an ambiguity related to what happens when e = 0. That ambiguity is discussed in the next exercise, and further references can be found in §5.3. Exercise 5.2.7. Conditions (E1) and (E2) cannot by themselves pin down outcomes for the extreme case where every firm in the network has zero net external assets. Illustrate this with an example.3 Although Exercise 5.2.7 suggests ambiguity about outcomes when e = 0, it is natural to adopt the convention that the equilibrium clearing vector p ∗ obeys p ∗ = 0 whenever e = 0. If the entire banking sector has no zero net assets, then no positive payment sequence can be initiated (without outside capital). In the next exercise, we say that U ⊂ V is accessible from i ∈ V if there exists a j ∈ U such that j is accessible from i. Exercise 5.2.8. Let P be the set of all nodes in V that are cash accessible. Let A be all i in P c such that P is accessible from i. Let N be all i in P c such that P is not accessible from i. Note that V = P ∪ A ∪ N and that these sets are disjoint. Show that N and P are both absorbing sets.
3 Hint: Every stochastic matrix has at least one stationary distribution.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.2 Financial Networks
5.2.3
175
Equity Cross-Holdings In this section we analyze the model of default cascades constructed by Elliott et al. (2014). The model differs from the one studied in §5.2.2 in several ways. One is that financial institutions are linked by share cross-holdings: Firm i owns a fraction ci j of firm j for i, j ∈ V := [n]. This implies that failure of firm j reduces the market value of firm i, which in turn reduces the market value of other firms, and so on. The second – and ultimately more significant – difference is the introduction of failure costs, which add significant nonlinearities to the model. Failure costs reinforce the impact of each firm failure, leading to greater shock propagation across the network. This feature ties into the intuitive idea that, when many firms are financially stressed, a failure by one firm can trigger a wave of bankruptcies.
5.2.3.1
Book and Market Value We now describe the features of the model. Let C = (ci j )i, j∈V be the matrix of fractional cross-holdings, as mentioned above, with 0 6 ci j 6 1 for all i, j. P assumption 5.2.1 The matrix of cross-holdings satisfies k cki < 1 for all i ∈ V . Assumption 5.2.1 implies that firms are not solely owned by other firms in the network: Investors outside the network hold at least some fraction of firm i for all i. The book value of firm i is given by X bi = ei + ci j b j (i ∈ V ). (5.15) j
Here the first term ei > 0 is the external assets of firm i and the second represents the value of firm i’s cross-holdings. In vector form, the last equation becomes b = e +Cb. Exercise 5.2.9. Let I be the n × n identity. Prove that, under Assumption 5.2.1, the matrix I − C is invertible, and the equation b = e + Cb has the unique solution b = (I − C)−1 e.
(5.16)
Prove also that b > 0. Exercise 5.2.10. Provide a weaker condition on C such that I − C is invertible. There is a widely used argument that cross-holdings artificially inflate the value of P firms, in the sense that the sum of book values of firms exceeds i ei , the sum of underlying equity values. The next exercise illustrates this: P P Exercise 5.2.11. Show that e 0 and mini, j ci j > 0 implies i bi > i ei . Due to this artificial inflation, we distinguish between the book value bi of a firm P and its market value v¯ i , which is defined as ri bi with ri := 1 − k cki . The value ri , which gives the share of firm i held by outsider investors, is strictly positive for all i
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
176
Nonlinear Interactions
by Assumption 5.2.1. With R := diag(r1, . . . ,rn ), we can write the vector of market values as v¯ = Rb. Substituting in (5.16) gives v¯ := Ae,
5.2.3.2
where
A := R(I − C)−1 .
(5.17)
Failure Costs So far the model is very straightforward, with the market value of firms being linear in external assets e. However, since bankruptcy proceedings are expensive, it is reasonable to assume that firm failures are costly. Moreover, when the market value of a firm falls significantly, the firm will experience difficulty raising short-term funds and will often need to cease revenue generating activities and sell illiquid assets well below their potential value. We now introduce failure costs. As before, v¯ i is market value without failure costs, as determined in (5.17), while vi will represent market value in the presence of failure costs. Failure costs for firm i are modeled as a threshold function f (vi ) = β1{vi < θ¯vi }
(i = 1, . . . ,n),
where θ ∈ (0,1) and β > 0 are parameters. Thus, costs are zero when vi is large and −β when they fall below the threshold θ¯vi . In particular, a discrete failure cost of −β is incurred when firm value falls far enough below the no-failure market value v¯ i . The larger is θ, the more prone the firm is to failure. The book value of firm i without failure costs was defined in (5.15). The book value of firm i in the presence of failure costs is defined as X bi = ei + ci j b j − f (vi ). j
Written in vector form, with f applied pointwise to the vector v, we get b = e + Cb − f (v). Solving for b gives b = (I −C)−1 (e − f (v)). The corresponding market value is v = Rb = A(e − f (v)).
(5.18)
Notice that, when no firms fail, we have vi = v¯ i , as expected.
5.2.3.3
Equilibria Equation (5.18) is a nonlinear equation in n unknowns. A vector v ∈ Rn solves (5.18) if and only if it is a fixed point of the operator T : Rn → Rn defined by T v = A(e − f (v)).
(5.19)
In what follows we set d := A(e − β1) and S := [d, v¯ ]. proposition 5.2.3 T is a self-map on S with least fixed point v∗ and greatest fixed point v∗∗ in S. Moreover, (i) the sequence (T k d)k∈N converges up to v∗ in a finite number of steps and (ii) the sequence (T k v¯ )k∈N converges down to v∗∗ in a finite number of steps.
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.3 Chapter Notes
177
Note that v∗ = v∗∗ is a possibility, in which case T has a unique fixed point in S. Exercise 5.2.12. Prove the first claim (first sentence) in Proposition 5.2.3. Why does (T k d)k∈N converge up to v∗ in a finite number of steps? First, as you saw in the solution to Exercise 5.2.12, the map T is an order-preserving self-map on [d, v¯ ], so T d ∈ [d, v¯ ]. In particular, d 6 T d. Iterating on this inequality and using the order-preserving property gives d 6 T d 6 T 2 d 6 · · · , so (T k d) is indeed increasing. Moreover, the range of T is a finite set, corresponding to all vectors of the form u = A(e − βw), where w is an n-vector containing only zeros and ones. Finiteness holds because there are only finitely many binary sequences of length n. Exercise 5.2.13. Given the above facts, prove that (T k d)k∈N converges up to v∗ in a finite number of steps. Similar logic can be applied to prove that (T k v¯ )k∈N converges down to v∗∗ in a finite number of steps. If we set v0 = v¯ and vk+1 = T vk , we can consider the sequence of valuations (vk ) P as a dynamic process, and the number of currently failing firms m k := i 1{vik < θ} can be understood as tracking waves of bankruptcies. Failures of firms in the first wave put stress on otherwise healthy firms that have exposure to the failed firms, which in turn causes further failures, and so on. Exercise 5.2.14. Prove that the sequence (m k ) is monotone increasing. As discussed in Proposition 5.2.3, the sequence (vk ), which can also be written as (T k v¯ ), is decreasing pointwise. In other words, the value of each firm is nonk+ j increasing. Hence, if vik < θ for some k, then vi < θ for all j > 0. Figure 5.1 illustrates a growing wave of failures that can arise in a financial network. Firms with lighter colors have better balance sheets. Black firms have failed. The code for generating this figure, along with details on parameters, can be found in the code book.
5.3
Chapter Notes Shin (2010) gives an excellent overview of systemic risk and the financial crisis of 2007–2008. Battiston et al. (2012) study connectedness in financial networks and introduce a measure of systemic impact called DebtRank. Bardoscia et al. (2015) provide a dynamic theory of instability related to DebtRank. Demange (2018) provides a threat index for contagion in financial networks related to Katz centrality. Bardoscia et al. (2019) analyze the risks associated with solvency contagion during crises. Jackson and Pernoud (2019) study investment in risky portfolios by banks in financial
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
178
Nonlinear Interactions
iteration 0
iteration 3
iteration 6
iteration 9
iteration 12
Figure 5.1 Waves of bankruptcies in a financial network
networks with debt and equity interdependencies. Jackson and Pernoud (2020) analyze optimal bailouts in financial networks. Amini and Minca (2020) offer an introduction to the modeling of clearing systems, analyzing equilibria for network payments and asset prices. Jackson and Pernoud (2021) provide a survey of the relationship between financial networks and systemic risk. The setting in §5.2.2.3 was investigated by Eisenberg and Noe (2001), one of the first papers on a network approach to default cascades. Additional details on stability properties can be found in Stachurski (2022b). As already mentioned, §5.2.3
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
5.3 Chapter Notes
179
is based on Elliott et al. (2014), which also includes an interesting discussion of how the level of integration across a network affects equilibria. Klages-Mundt and Minca (2021) discuss optimal intervention in economic networks via influence maximization methods, using Elliott et al. (2014) as an example. Acemoglu et al. (2021b) study how anticipation of future defaults can result in “credit freezes.” A general discussion of contraction maps and related fixed point theory can be found in Goebel and Kirk (1990) and Cheney (2013). For more on fixed point methods for order-preserving operators, see, for example, Guo et al. (2004), Zhang (2012), Marinacci and Montrucchio (2019) or Deplano et al. (2020).
https://doi.org/10.1017/9781009456340.007 Published online by Cambridge University Press
Appendix A Math Review
This appendix provides a brief review of basic analysis and linear algebra. The material contained here should be covered in intermediate mathematical economics courses or, if not, in math boot camp at the very start of a graduate program. (For those who want a slower treatment of the analysis section, we recommend Bartle and Sherbert (2011), which is carefully constructed and beautifully written. High quality texts on linear algebra at the right level for this course include Jänich (1994), Meyer (2000), Aggarwal (2020), and Cohen (2021).)
A.1
Sets and Functions As a first step, let’s clarify elementary terminology and notation.
A.1.1
Sets A set is an arbitrary collection of objects. Individual objects are called elements of the set. We assume the reader is familiar with basic set operations such as intersections and unions. If A is a finite set, then |A| is the number of elements in A. Powers applied to sets indicate Cartesian products, so that A2 := A × A := {(a,a 0 ) : a ∈ A, a 0 ∈ A}, etc. Throughout, ℘(A) is the power set of A, consisting of all subsets of A. For example, A = {1,2}
H⇒
℘(A) = {∅,{1},{2}, A}.
Let N be the natural numbers, Z be the integers, Q be the rational numbers, and R be the reals (i.e., the union of the rational and irrational numbers). For x, y in R, we let x ∨ y := max{x, y} and
x ∧ y := min{x, y}.
Absolute value is |x| := x ∨ (−x). For n ∈ N we set [n] := {1, . . . ,n}. We make use of the following elementary facts: For all a,b,c ∈ R, • |a + b| 6 |a| + |b|. • (a ∧ b) + c = (a + c) ∧ (b + c) and (a ∨ b) + c = (a + c) ∨ (b + c). https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
(A.1)
A.1 Sets and Functions
181
• (a ∨ b) ∧ c = (a ∧ c) ∨ (b ∧ c) and (a ∧ b) ∨ c = (a ∨ c) ∧ (b ∨ c). • |a ∧ c − b ∧ c| 6 |a − b|. • |a ∨ c − b ∨ c| 6 |a − b|. The first item is called the triangle inequality. Also, if a,b,c ∈ R+ , then (a + b) ∧ c 6 (a ∧ c) + (b ∧ c).
(A.2)
Exercise A.1.1. Prove: For all a,b,c ∈ R+ , we have |a ∧ c − b ∧ c| 6 |a − b| ∧ c.
A.1.2
Equivalence Classes Let S be any set. A relation ∼ on S is a nonempty subset of S × S. It is customary to write x ∼ y rather than (x, y) ∈ ∼ to indicate that (x, y) is in ∼. A relation ∼ on S is called an equivalence relation if, for all x, y,z ∈ S, we have (reflexivity) x ∼ x, (symmetry) x ∼ y implies y ∼ x and (transitivity) x ∼ y and y ∼ z implies x ∼ z. Any equivalence relation on S induces a partition of S into a collection of mutually disjoint subsets such that their union exhausts S. These subsets are called equivalence classes. They can be constructed by taking, for each x ∈ S, the set of all elements that are equivalent to x. Example A.1.1: Let S be the set of all people in the world. If x ∼ y indicates that x and y live in the same country, then ∼ is an equivalence relation. (Check the axioms.) The equivalence classes are the populations of each country. The partition induced on S is the set of these classes, which we can identify with the set of all countries in the world.
A.1.3
Functions A function f from set A to set B is a rule, written f : A → B or a 7→ f (a), that associates each element a of A with one and only one element f (a) of B. The set A is called the domain of f , and B is called the codomain. The range or image of f is range( f ) := {b ∈ B : b = f (a) for some a ∈ A}. A function f : A → B is called 0 0 • one-to-one if f (a) = f (a ) implies a = a ; • onto if range( f ) = B; and • a bijection or one-to-one correspondence if f is both onto and one-to-one.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
182
Math Review
one-to-one
onto
1
1
f(x) = 1/2 +x/2
f(x) = 4x(1−x)
0
0 0
1
0
1
Figure A.1 Different types of functions on (0,1) constant
bijection
1
1
f(x) = 1/2
f(x) = 1−x
0
0 0
1
0
1
Figure A.2 Some functions are bijections and some are not
Example A.1.2: If S is a nonempty set, then the identity map on S is the map I : S → S such that I (x) = x for all x ∈ S. The identity map is a bijection for any choice of S. The left panel of Figure A.1 shows a one-to-one function on (0,1). This function is not onto, however. For example, there exists no x ∈ (0,1) with f (x) = 1/4. The right panel of Figure A.1 shows an onto function, with range( f ) = (0,1). This function is not one-to-one, however. For example, f (1/4) = f (3/4) = 3/4. The left panel of Figure A.2 gives an example of a function that is neither one-toone nor onto. The right panel of Figure A.2 gives an example of a bijection.
A.1.4
Inverse Functions One motivation for our interest in the basic properties of functions is that we wish to solve inverse problems. For an arbitrary nonempty set S and a function f : S → S, an abstraction of an inverse problem is solving y = f (x) for x ∈ S.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.1 Sets and Functions
183
Prior to stating the next result, we recall that an inverse function for f : S → S is a function g : S → S such that f ◦ g = g ◦ f = I , where I is the identity map on S. The inverse function of f is often written as f −1 . lemma A.1.1 For f : S → S, the following statements are equivalent: (i) f is a bijection on S. (ii) For each y ∈ S, there exists a unique x ∈ S such that f (x) = y. (iii) f has an inverse on S. Proof ((i) H⇒ (ii)) Fix y ∈ S. Since f is onto, there exists an x ∈ S such that f (x) = y. Since f is one-to-one, there is at most one such x. ((ii) H⇒ (iii)) Let g : S → S map each y ∈ S into the unique x ∈ S such that f (x) = y. By the definition of g, for fixed x ∈ S, we have g( f (x)) = x. Moreover, for each y ∈ S, the point g(y) is the point that f maps to y, so f (g(y)) = y. ((iii) H⇒ (i)) Let g be the inverse of f . To see that f must be onto, pick any y ∈ S. Since f ◦ g is the identity, we have f (g(y)) = y. Hence there exists a point g(y) in S that is mapped into y ∈ S. To see that f is one-to-one, fix x, y ∈ S. If f (x) = f (y), then g( f (x)) = g( f (y)). But g ◦ f is the identity, so x = y. Here is a nice logical exercise that turns out to be useful when we solve linear inverse problems. Exercise A.1.2. Let S and T be nonempty sets. For f : S → T , a function g : T → S is called a left inverse of f if g ◦ f = I , where I is the identity on S. Prove that f is one-to-one if and only if f has a left inverse.
A.1.5
Real-Valued Functions If S is any set and f : S → R, we call f a real-valued function. The set of all realvalued functions on S is denoted R S . When S has n elements, R S is the same set as Rn expressed in different notation. The next lemma clarifies. lemma A.1.2 If |S| = n, then R S 3 h = (h(x1 ), . . . ,h(xn ))
←→
h1 .. n . ∈ R hn
(A.3)
is a one-to-one correspondence between Rn and the function space R S . The lemma just states that a function h can be identified by the set of values that it takes on S, which is an n-tuple of real numbers. We use this identification routinely in what follows. The indicator function of logical statement P is denoted 1{P} and takes value 1 (resp., 0) if P is true (resp., false). https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
184
Math Review
Example A.1.3: If x, y ∈ R, then 1{x 6 y} =
( 1 0
if x 6 y otherwise.
If A ⊂ S, where S is any set, then 1 A (x) := 1{x ∈ A} for all x ∈ S. A nonempty set S is called countable if it is finite or can be placed in one-to-one correspondence with the natural numbers N. In the second case we can enumerate S by writing it as {x1,x2, . . .}. Any nonempty set S that fails to be countable is called uncountable. For example, Z and Q are countable, whereas R and every nontrivial interval in R are uncountable. In general, if f and g are real-valued functions defined on some common set S and α is a scalar, then f + g, α f , f g, etc., are functions on S defined by ( f + g)(x) = f (x) + g(x),
(α f )(x) = α f (x),
etc.
(A.4)
for each x ∈ S. Similarly, f ∨ g and f ∧ g are functions on S defined by ( f ∨ g)(x) = f (x) ∨ g(x) and ( f ∧ g)(x) = f (x) ∧ g(x).
(A.5)
Figure A.3 illustrates. If f : A → B and g : B → C, then g ◦ f is called the composition of f and g. It is the function mapping a ∈ A to g( f (a)) ∈ C.
f ∨g
f ∧g
f
g
Figure A.3 Functions f ∨ g and f ∧ g when defined on a subset of R
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.1 Sets and Functions
A.1.6
185
Fixed Points Let S be any set. A self-map on S is a function G from S to itself. When working with self-maps in arbitrary sets, it is common to write the image of x under G as Gx rather than G(x). We often follow this convention. Given a self-map G on S, a point x ∈ S is called a fixed point of G if Gx = x. Example A.1.4: Every point of arbitrary S is fixed under the identity map I : x 7→ x. Example A.1.5: If S = N and Gx = x + 1, then G has no fixed point. Figure A.4 shows another example, for a self-map G on S = [0,2]. The fixed points are numbers x ∈ [0,2] where G meets the 45 degree line. In this case there are three. One of the most common techniques for solving systems of nonlinear equations in applied mathematics – and quantitative economics – is to convert them into fixed point problems and then apply fixed point theory. We will see many applications of this technique. Exercise A.1.3. Let S be any set, and let G be a self-map on S. Suppose there exist an x¯ ∈ S and an m ∈ N such that G k x = x¯ for all x ∈ S and k > m. Prove that, under this condition, x¯ is the unique fixed point of G in S. 2:00
1.75
G 45o
xh
1.50
1.25
1.00
0.75
0.50
xm x`
0.25
0.25
0.50
0.75
1.00
1.25
1.50
Figure A.4 Graph and fixed points of G : x 7→ 2.125/(1 + x −4 )
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
1.75
2.00
186
Math Review
A.1.7
Vectors An n-vector x is a tuple of n numbers x = (x1, . . . ,xn ), where xi ∈ R for each i ∈ [n]. In general, x is neither a row vector nor a column vector – which coincides with the perspective of most scientific computing environments, where the basic vector structure is a flat array. When using matrix algebra, vectors are treated as column vectors unless otherwise stated. The two most fundamental vector operations are vector addition and scalar multiplication. These operations act pointwise, so that, when α ∈ R and x, y ∈ Rn , x1 y1 x1 + y1 αx1 x2 y2 x2 + y2 αx2 x+y= + := and αx := .. .. .. .. . . . . . xn
yn
αxn
xn + yn
We let Rn be the set of all n-vectors and Mn×k be all n × k matrices. If A is a matrix then A> is its transpose. Pn n hx, yi := i=1 xi yi . • The inner product of x, y ∈ R is defined as √ n • The Euclidean norm of x ∈ R is kxk := hx,xi. The norm and inner product satisfy the triangle inequality and Cauchy–Schwarz inequality, which state that, respectively, kx + yk 6 kxk + kyk
A.1.8
and
| hx, yi | 6 kxkkyk
for all x, y ∈ Rn .
Complex Numbers We recall some elementary facts about C, the set of complex numbers. Each element of C can be understood as a point (a,b) ∈ R2 . In fact C is just R2 endowed with a special form of multiplication. The point (a,b) is more often written as a + ib. We elaborate below. The first and second projections of (a,b) are written as Re(a,b) = a and Im(a,b) = b and called the real and nonreal (or imaginary) parts, respectively. The symbol i represents the point (0,1) ∈ C. As is traditional, in the context of complex numbers, the complex number (a,0) ∈ C is often written more simply as a. With addition and scalar multiplication defined pointwise, this means that, as expected, (a,b) = (a,0) + (0,b) = (a,0) + (0,1)b = a + ib. Let z = (a,b). The modulus of z is written |z| and defined as the Euclidean norm (a 2 + b2 )1/2 of the tuple (a,b). The two-dimensional Euclidean space is then endowed with a new operation called multiplication, which is defined by (a,b)(c,d) = (ac − bd,ad + bc).
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
(A.6)
A.1 Sets and Functions
187
Note that, under this rule and our conventions, i 2 = (0,1)(0,1) = (−1,0) = −1. P As in the real case, the exponential ez is defined for z ∈ C by k>0 z k /(k! ). It can be shown that, under this extension, the exponential function continues to enjoy the additive property ez 1 +z 2 = ez 1 ez 2 . As a result, ea+ib = ea eib . Rather than providing its coordinates, another way to represent a vector z = (a,b) ∈ 2 R , and hence in C, is by providing a pair (r,ϕ) where r > 0 is understood as the length of the vector and ϕ ∈ [0,2π) is the angle. This translates to Euclidean coordinates via a + ib = (a,b) = (r cos ϕ,r sin ϕ) = r (cos ϕ + i sin ϕ). The representation (r,ϕ) is called the polar form of the complex number. By Euler’s formula cos(ϕ) + i sin(ϕ) = ei ϕ , we can also write r (cos ϕ + i sin ϕ) = r ei ϕ . √ √ Figure A.5 translates C 3 (1, 3) = 1 + i 3 into polar coordinates 2ei(π/3) . The advantage of these representations is clear when we multiply, since the rule r ei ϕ sei ψ = r s ei(ϕ+ψ)
(A.7)
π 2
(a, b) = (1,
√
3)
π 4
3π 4
r=2 √
3
ϕ = π/3
π
0
1
1
5π 4
7π 4 2
3π 2
Figure A.5 The complex number (a,b) = r ei ϕ
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
188
Math Review
is easier to remember and apply than (A.6). Calculating the modulus is also easy, since, by the trigonometric formula cos2 ϕ + sin2 ϕ = 1, 1/2 |r ei ϕ | = |r (cos(ϕ) + i sin(ϕ))| = r cos2 ϕ + sin2 ϕ = r. (A.8) Exercise A.1.4. Show that, for any u,v ∈ C we have |uv| = |u||v|.
A.2
Order Order structure is of great importance in economics – typically more so than in other fields such as physics or chemistry. Here we review the basics.
A.2.1
Partial Orders It was mentioned in the preface that order-theoretic methods form a core part of the text. In this section we introduce some key concepts. Let P be a nonempty set. A partial order on P is a relation on P × P satisfying, for any p,q,r in P, p p, p q and q p implies p = q, and p q and q r implies p r .
(reflexivity) (antisymmetry) (transitivity)
When paired with a partial order , the set P (or the pair (P, )) is called a partially ordered set. Example A.2.1: The usual order 6 on R is a partial order on R. Unlike other partial orders we consider, it has the additional property that either x 6 y or y 6 x for every x, y in R. For this reason, 6 is also called a total order on R. Exercise A.2.1. Let P be any set, and consider the relation induced by equality, so that p q if and only if p = q. Show that this relation is a partial order on P. Exercise A.2.2. Let M be any set. Show that ⊂ is a partial order on ℘(M), the set of all subsets of M. Example A.2.2: (Pointwise order over functions) Let S be any set. For f ,g in R S , we write f 6 g if f (x) 6 g(x) for all x ∈ S. This relation 6 on R S is a partial order called the pointwise order on R S .
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.2 Order
189
A subset B of a partially ordered set (P, ) is called • increasing if x ∈ B and x y implies y ∈ B; • decreasing if x ∈ B and y x implies y ∈ B. Exercise A.2.3. Describe the set of increasing sets in (R, 6). Example A.2.3: (Pointwise order over vectors) For vectors x = (x1, . . . ,xd ) and y = (y1, . . . , yd ), we write • x 6 y if xi 6 yi for all i ∈ [d] and • x y if xi < yi for all i ∈ [d]. The statements x > y and x y are defined analogously.1 The relation 6 is a partial order on Rn , also called the pointwise order. (In fact, the present example is a special case of Example A.2.2 under the identification in Lemma A.1.2 (page 183).) On the other hand, is not a partial order on Rn . (Which axiom fails?) Exercise A.2.4. Recall from Example A.3.2 that limits in R preserve weak inequalities. Prove that the same is true in Rd . In particular, show that, for vectors a,b ∈ Rd and sequence (xn ) in Rd , we have a 6 xn 6 b for all n ∈ N, and xn → x implies a 6 x 6 b.
A.2.2
Pointwise Operations on Vectors In this text, operations on real numbers such as | · | and ∨ are applied to vectors pointwise. For example, for vectors a = (ai ) and b = (bi ) in Rd , we set |a| = (|ai |),
a ∧ b = (ai ∧ bi ),
and a ∨ b = (ai ∨ bi ).
(The last two are special cases of (A.5).) A small amount of thought will convince you that, with this convention plus the pointwise order over vectors, the order-theoretic inequalities and identities listed in §A.1.1 also hold for vectors in Rd . (For example, |a + b| 6 |a| + |b| for any a,b,c ∈ Rd .) Exercise A.2.5. Prove: If B is m × k and B > 0, then |Bx| 6 B|x| for all k × 1 column vectors x.
A.2.3
Monotonicity Given two partially ordered sets (P, ) and (Q, E), a function G from P to Q is called order-preserving if 1 The notation x 6 y over vectors is standard, while x y is less so. In some fields, n k is used as an
abbreviation for “n is much smaller than k.” Our usage lines up with most of the literature on partially ordered vector spaces. See, e.g., Zhang (2012). https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
190
Math Review
p,q ∈ P and p q
H⇒
Gp E Gq.
(A.9)
Example A.2.4: Let 𝒞 be all continuous functions from S = [a,b] to R, and let 6 be the pointwise partial order on 𝒞. Define Z b I: 𝒞3 f → f (x)d x ∈ R. a
Since f 6 g implies on 𝒞.
Rb a
f (x)d x 6
Rb a
g(x)d x, the integral map I is order-preserving
Exercise A.2.6. Let X be a random variable mapping to finite S. Define ` : R S → R by `h = Eh(X ). Show that ` is order-preserving when R S has the pointwise order. If P = Q = R, and and E are both equal to 6, the standard order on R, then the order-preserving property reduces to the usual notion of an increasing function (i.e., nondecreasing function), and we will use the terms “increasing” and “orderpreserving” interchangeably in this setting.2 In addition, if S = g maps A ⊂ R into R, then we will call g • strictly increasing if x < y implies g(x) < g(y) and • strictly decreasing if x < y implies g(x) > g(y).
A.3
Convergence Let’s now recall the basics of convergence and continuity. Given any set S, an S-valued sequence (xn ) := (xn )n∈N is a function n 7→ xn from N to S. If S = R, we call (xn ) a real-valued sequence. A subsequence of (xn )n∈N is a sequence of the form (x σ(n) )n∈N , where σ is a strictly increasing function from N to itself. You can think of forming a subsequence from a sequence by deleting some of its elements – while still retaining infinitely many. In computer science and statistics, it is common to classify sequences according to their asymptotic behavior. Often this is done via big O notation, where, for a realvalued sequence (xn ), we write (xn ) = O(gn ) if there exists a nonnegative sequence (gn ) and a constant M < ∞ such that |xn | 6 Mgn for all n ∈ N. Exercise A.3.1. Let xn = −5n + n 2 for all n ∈ N. Show that (xn ) = O(n 2 ) holds but (xn ) = O(n) fails.
2 Other common terms for order-preserving in the literature include “monotone increasing,” “monotone,”
and “isotone.”
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.3 Convergence
A.3.1
191
Metric Properties of the Real Line The following definition is fundamental to what follows: A real-valued sequence (xn ) converges to x ∈ R, and we write xn → x, if for each ε > 0, there is an N ∈ N such that |xn − x| < ε whenever n > N . Example A.3.1: If xn = 1 − 1/n, then xn → 1. Indeed, for any ε > 0, the statement |xn − 1| < ε is equivalent to n > 1/ε. This clearly holds whenever n is sufficiently large. Exercise A.3.2. Prove: If a,b ∈ R, xn → a and xn → b, then a = b. Let’s state some elementary limit laws that are used without comment throughout. (You can review the proofs in sources such as Bartle and Sherbert (2011)). A sequence (xn ) is called bounded if there is an M ∈ R such that |xn | 6 M for all n ∈ N. It is called • monotone increasing if xn 6 xn+1 for all n ∈ N and • monotone decreasing if xn > xn+1 for all n. The sequence is called monotone if it is either monotone increasing or decreasing. The next theorem, concerning monotone sequences, is a deep result about the structure of R. theorem A.3.1 is bounded.
A real-valued monotone sequence converges in R if and only if it
The intuitive meaning of the “if” part of Theorem A.3.1 is that monotone bounded sequences always converge to some point in R because R contains no gaps. This statement is closely related to the “completeness” property of the real line, which is discussed in Bartle and Sherbert (2011) and many other texts on real analysis. Next let’s consider series. Given a sequence (xn ) in R, we set X n>1
xn := lim
N X
N →∞
xn whenever the limit exists in R.
n=1
P More generally, given arbitrary countable S and g ∈ R S , we write x∈S g(x) = M P if there exists an enumeration (xn )n∈N of S such that n>1 |g(xn )| is finite and, in P addition, n>1 g(xn ) = M.3 Exercise A.3.3. Show that, if S is countable, g ∈ R S , and there exist x 0,x 00 ∈ S P P such that g(x 0 ) > 0 and g(x 00 ) < 0, then x∈S g(x) < x∈S |g(x)|.4 3 This definition is not ambiguous because every possible enumeration leads to the same value when the
absolute sum is finite (see, e.g., the rearrangement theorem in Bartle and Sherbert (2011), §9.1). 4 Hint: Start with the case |S| = 2. Argue that the case with n elements follows from this case and the
ordinary (weak) triangle inequality |
P
x∈S g(x)| 6
P
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
x∈S |g(x)|.
192
Math Review
A.3.2
Metric Properties of Euclidean Space Now we review the metric properties of Rd , for some d ∈ N, when distance between vectors x, y ∈ Rd is understood in terms of Euclidean norm deviation kx − yk. The notion of convergence for real-valued sequences extends naturally to this setting: Sequence (xn ) in Rd is said to converge to x ∈ Rd if for each ε > 0, there is an N ∈ N such that kxn − xk < ε whenever n > N . In this case we write xn → x. Figure A.6 shows a sequence converging to the origin in R3 , with colder colors being later in the sequence. Exercise A.3.4. Prove that limits in Rd are unique. In other words, show that, if (xn ) is a sequence converging to x ∈ Rd and y ∈ Rd , then x = y. Given any point u ∈ Rd and ε > 0, the ε-ball around u is the set Bε (u) := {v ∈ Rd : ku − vk < ε}. With this terminology, we can say that (xn ) converges to x ∈ Rd if the sequence (xn ) is eventually in any ε-ball around x. proposition A.3.2 If (xn ) and (yn ) are sequences in Rd with xn → x and yn → y, then (i) (ii) (iii) (iv)
xn + yn → x + y, and xn yn → x y; xn 6 yn for all n ∈ N implies x 6 y; αxn → αx for any α ∈ R; xn ∨ yn → x ∨ y, and xn ∧ yn → x ∧ y.
A sequence (xn ) ⊂ Rd is called Cauchy if, for all ε > 0, there exists an N ∈ N with |xn − xm | < ε whenever n,m > N .
Figure A.6 Convergence of a sequence to the origin in R3
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.3 Convergence
193
Exercise A.3.5. Let d = 1 and suppose xn = 1/n. Prove that (xn ) is Cauchy. Exercise A.3.6. Prove that every convergent sequence in Rd is Cauchy. It is a fundamental result of analysis, stemming from axiomatic properties of the reals, that the converse is also true: theorem A.3.3 Cauchy.
A.3.3
A sequence in Rd converges to a point in Rd if and only if it is
Topology A point u ∈ A ⊂ Rd is called interior to A if there exists an ε > 0 such that Bε (u) ⊂ A. Exercise A.3.7. Let d = 1 so that kx − yk = |x − y|. Show that 0.5 is interior to A := [0,1) but 0 is not. Show that Q, the set of rational numbers in R, contains no interior points. A subset G of Rd is called open in Rd if every u ∈ G is interior to G. A subset F of Rd is called closed if, given any sequence (xn ) satisfying xn ∈ F for all n ∈ N and xn → x for some x ∈ Rd , the point x is in F. In other words, F contains the limit points of all convergent sequences that take values in F. Example A.3.2: Limits in R preserve orders, so a 6 xn 6 b for all n ∈ N, and xn → x implies a 6 x 6 b. Thus, any closed interval [a,b] in R is closed in the standard (one-dimensional Euclidean) metric. Exercise A.3.8. Prove that G ⊂ Rd is open if and only if G c is closed. A subset B of Rd is called bounded if there exists a finite M such that kbk 6 M for all b ∈ B. A subset K of Rd is called compact in Rd if every sequence in K has a subsequence converging to some point in K . The Bolzano–Weierstrass theorem tells us that K is compact if and only if K is closed and bounded.
A.3.4
Continuity in Vector Space If A ⊂ Rd , then f : A → Rk is called continuous at x ∈ A if, for each sequence (xn ) ⊂ A with xn → x, we have f (xn ) → f (x) in Rk . If f is continuous at all x ∈ A, then we call f continuous on A. Example A.3.3: If f (x) = x 2 on A = R, then f is continuous at all x ∈ R because, by Proposition A.3.2, xn → x implies xn2 = xn · xn → x · x = x 2 .
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
194
Math Review
More generally, every polynomial function is continuous on R. The elementary functions sin, cos, exp, and log are all continuous on their domains. Exercise A.3.9. Prove: If α,β ∈ R and f ,g are continuous functions from A ⊂ Rd to Rk , then so is α f + βg. Exercise A.3.10. Fix a ∈ Rd . Prove that f ,g : Rd → Rd defined by f (x) = x ∧a and g(x) = x ∨ a are both continuous functions on Rd . The next lemma is helpful in locating fixed points. lemma A.3.4 Let F be a self-map on S ⊂ Rd . If F m u → u ∗ as m → ∞ for some pair u,u ∗ ∈ S and, in addition, F is continuous at u ∗ , then u ∗ is a fixed point of F. Proof Assume the hypotheses of Lemma A.3.4, and let u m := F m u for all m ∈ N. By continuity and u m → u ∗ , we have Fu m → Fu ∗ . But the sequence (Fu m ) is just (u m ) with the first element omitted, so, given that u m → u ∗ , we must have Fu m → u ∗ . Since limits are unique, it follows that u ∗ = Fu ∗ .
A.4
Linear Algebra Next we review fundamental concepts and definitions from linear algebra.
A.4.1
Subspaces and Independence A subset E of Rn is called a linear subspace of Rn if x, y ∈ E and α,β ∈ R H⇒ αx + βy ∈ E. In other words, E is closed under the operations of addition and scalar multiplication; that is, (i) α ∈ R and x ∈ E implies αx ∈ E and (ii) x, y ∈ E implies x + y ∈ E. Exercise A.4.1. Fix c ∈ Rn and C ∈ Mn×k . Show that n • H := {x ∈ R : hc,xi = 0} and n k • range C := {y ∈ R : y = C x for some x ∈ R }
are linear subspaces of Rn . Show that S := {x ∈ Rn : hc,xi > 0} is not. A linear combination of vectors v1, . . . ,vk in Rn is a vector of the form α1 v1 + · · · + α k vk , where (α1, . . . ,α k ) ∈ Rk . The set of all linear combinations of elements of F ⊂ Rn is called the span of F and written as span F.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.4 Linear Algebra
195
Example A.4.1: The set range C in Exercise A.4.1 is the span of the columns of the matrix C, viewed as a set of vectors in Rn . The set range C is also called the column space of C. Exercise A.4.2. Let F be a nonempty subset of Rn . Prove that (i) span F is a linear subspace of Rn and (ii) span F is the intersection of all linear subspaces S ⊂ Rn with S ⊃ F. Figure A.7 shows the linear subspace spanned by the three vectors −3.5 3 3 u = 4 , v = −4 , and w = 3 . −0.4 0.2 1
(A.10)
The subspace H in which these vectors lie is, in fact, the set of all x ∈ R3 such that hx,ci = 0, with c = (−0.2, − 0.1,1). This plane is a two-dimensional object. While we make this terminology precise in §A.4.2, the key idea is that
Figure A.7 The span of vectors u,v,w in R3
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
196
Math Review
• at least two vectors are required to span H and • any additional vectors will not increase the span. A finite set of vectors F := {v1, . . . ,vk } ⊂ Rn is called linearly independent if, for real scalars α 1, . . . ,α k , α 1 v1 + · · · + α k vk = 0 H⇒ α1 = · · · = αk = 0. If F is not linearly independent, it is called linearly dependent. Exercise A.4.3. Show that F is linearly dependent if and only if there exists a vector in F that can be written as a linear combination of other vectors in F. Exercise A.4.4. Prove the following: (i) Every subset of a linearly independent set in Rn is linearly independent.5 (ii) Every finite superset of a linearly dependent set in Rn is linearly dependent.
Example A.4.2: It is easy to check that the set E := {δ1, . . . ,δn } ⊂ Rn defined by 1 0 0 0 1 0 δ1 := . , δ2 := . , · · · , δ n := . .. .. .. 0
0
1
is linearly independent. Its elements are called the canonical basis vectors of Rn . The span of the canonical basis vectors in Rn is equal to all of Rn . In particular, each x ∈ Rn can be expressed as x=
n X
αi δi ,
where αi := hx,δi i .
(A.11)
i=1
On the other hand, we cannot omit an element of the basis {δ1, . . . ,δn } and still span Rn . The next theorem generalizes this idea. theorem A.4.1 If E = {u 1, . . . ,u n } is a set of n vectors in Rn , then span E = Rn if and only if E is linearly independent. See, for example, Jänich (1994). Theorem A.4.1 captures the notion that linear independence of a set of vectors means linear diversity, which allows the span to be large. Exercise A.4.5. The null space or kernel of a matrix A ∈ Mn×k is the set null A := {x ∈ Rk : Ax = 0}. 5 By the law of the excluded middle, the empty set must be linearly independent too.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.4 Linear Algebra
197
Show that (i) null A is a linear subspace of Rk and (ii) null A = {0}, where 0 is the origin in Rk , if and only if the columns of A form a linearly independent subset of Rn .
A.4.2
Basis Vectors and Dimension Let V be a linear subspace of Rn . A set B ⊂ V is called a basis for V if B is linearly independent and span B = V . The key idea behind a basis is this: If S = {v1, . . . ,vk } spans some linear subspace V , then each element of V can be written as a linear combination of elements of S. If S is, in addition, linearly independent (and hence a basis), then this representation is unique: For each u ∈ V , there is exactly one (α1, . . . ,α k ) ∈ Rk such that u = α 1 v1 + · · · + α k vk . Indeed, if u = β 1 v1 + · · · + β k vk is another representation, then, subtracting this equality from the last, we have (α 1 − β 1 )v1 + · · · + (αk − β k )vk = 0. Because S is assumed to be linearly independent, this yields αi = βi for all i ∈ [k]. Not surprisingly, given their name, the canonical basis vectors E := {δ 1, . . . ,δn } serve as a basis for the whole space Rn . The representation (A.11), with coefficients αi = hx,δi i, is unique. theorem A.4.2 If V is a nonzero linear subspace of Rn , then (i) V has at least one basis and (ii) every basis of V has the same number of elements. Theorem A.4.2 is a relatively deep result. See, for example, Jänich (1994). The common number of bases in (ii) is called the dimension of V and written as dim V . The “nonzero” qualification in Theorem A.4.2 is included for the case V = {0}, which is a linear subspace that lacks any basis. It is sensible, and standard, to agree that the linear subspace {0} ⊂ Rn has dimension zero. Dimensionality is one measure of the “size” of a linear subspace. To illustrate, consider the system Ax = b, where A ∈ Mn×k , x ∈ Rk , and b ∈ Rn . Is there an x that solves this system? This will be more likely if the column space of A is large (see Example A.4.1). A large span will be obtained when the columns are linearly “diverse.” In other words, our hope is that there exists a large subset of the columns of A that is linearly independent, which in turn will be true when the span of A is high-dimensional. To quantify these ideas, we define the rank of A as rank A := dim(range A) = dimension of the column space of A.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
198
Math Review
theorem A.4.3 For any matrix A, the following quantities are equal: (i) rank A, (ii) the maximal number of linearly independent columns of A, and (iii) the maximal number of linearly independent rows of A. See, for example, chapter 2 of Aggarwal (2020) or chapter 5 of Jänich (1994). In view of Exercise A.4.6, for A ∈ Mn×k , we have rank A 6 k. If rank A = k, then A is said to have full column rank. In general, a linear subspace V contains within itself many other linear subspaces. (For example, a plane passing through the origin contains many lines that pass through the origin, each one of which is a linear subspace.) However, there is no proper subspace of V (i.e., no linear subspace contained in and distinct from V ) with the same dimension as V . The next theorem records this fact. theorem A.4.4 If U,V are linear subspaces of Rn , then U ⊂ V implies dim U 6 dim V , with equality if and only if U = V . Exercise A.4.6. Let U be a linear subspace of Rn . Using the results given above, prove the following statements: (i) The only n-dimensional linear subspace of Rn is Rn . (ii) If A ⊂ U is finite and |A| > dim U , then A is linearly dependent. Part (ii) is related to Figure A.7. The plane in that figure is two-dimensional, as we confirm in §A.4.3 below. Any three vectors lying in the plane are linearly dependent.
A.4.3
Linear Maps Are Matrices We will see in the following chapters that many nonlinear dynamic models and estimation problems can be expressed in terms of linear operations in high-dimensional spaces. We now state the definition of linear maps and their connection to matrices. A function u 7→ Au from Rk to Rn is called linear if A(αu + βv) = α Au + β Av
for all α,β ∈ R and all u,v in Rk .
In this context, A is sometimes called an operator rather than a function, but the meaning is the same. Exercise A.4.7. Fix s,t ∈ R. Show that A : R → R defined by Au = su + t is a linear function on R if and only if t = 0. Exercise A.4.8. Let A : Rn → Rn be a linear bijection. By Lemma A.1.1, the operator A has an inverse A−1 mapping Rn to itself. Prove that A−1 is linear.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
199
A.4 Linear Algebra
1
1
non-bijection
bijection
−1
−1
1
1
f (x) = 0x
f (x) = 0.5x
−1
−1
Figure A.8 Equivalence of the onto and one-to-one properties
One of the most striking and useful properties of linear operators is that the oneto-one property and the onto property are equivalent when the domain and codomain agree: theorem A.4.5 Let A : Rn → Rn be linear. The operator A is a one-to-one function if and only if it is onto. The proof can be found in Jänich (1994) or Stachurski (2016). Figure A.8 illustrates in the one-dimensional case. The linear map f (x) = αx is onto if and only if it is oneto-one, which occurs if and only if α 6= 0. A matrix A ∈ Mn×k is a linear function from Rk to Rn when identified with the mapping that sends a (column) vector u in Rk into the vector Au in Rn . In fact it is fundamental that, for every linear map A : Rk → Rn , there exists a unique M A ∈ Mn×k such that Au = M A u
for all u ∈ Rk
(A.12)
(see, e.g., Kreyszig (1978), §2.9). Thus, the set of linear maps and the set of matrices are in one-to-one correspondence in the finite-dimensional setting.
A.4.4
Linear Hyperplanes In Exercise A.4.1, you confirmed that, for a given nonzero c ∈ Rn , the subset of Rn defined by H := {x ∈ Rn : hc,xi = 0} is a linear subspace of Rn . Any set H of this form is called a linear hyperplane in Rn . The vector c is called the normal vector of the hyperplane. theorem A.4.6 (Rank–Nullity Theorem) For each A ∈ Mn×k , we have rank A + dim(null A) = k.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
200
Math Review
Example A.4.3: If A has linearly independent columns, then rank A = k, and A is said to have full column rank. Recall from Exercise A.4.5 that this is precisely the setting where null A = {0}. Hence dim(null A) = 0, and Theorem A.4.6 holds. In the discussion after Figure A.7, we claimed that the linear hyperplane showed there is a two-dimensional subset of R3 . The next example generalizes this idea. Example A.4.4: A linear hyperplane H = {x ∈ Rn : hx,ci = 0} with c 6= 0 has dimension n − 1. To see this, just set A in Theorem A.4.6 to c, treated as a 1 × n row vector. Then H = null A, and dim H = dim null A = n − rank A = n − 1. (Here rank A = 1 follows from Theorem A.4.3.)
A.4.5
Nonsingular Linear Systems A crucial task in applied modeling is solving linear systems such as Ax = b, where A is a matrix and x and b are conformable column vectors. The system can be underdetermined, overdetermined, or exactly determined (i.e., the same number of equations as unknowns). In this section we consider the last case, where the theory is straightforward. Let A and B be in Mn×n , and suppose that AB = B A = I . Then B is called the inverse of A, written as A−1 , while A is said to be invertible or nonsingular. The next theorem states that, for square matrices, the property of having either a left or a right inverse is equivalent to nonsingularity. theorem A.4.7 Given A in Mn×n , the following statements are equivalent: (i) There exists an L ∈ Mn×n such that L A = I . (ii) There exists an R ∈ Mn×n such that A R = I . If one and hence both of these statements hold, then A is nonsingular and L = R = A−1 . Proof Fix A in Mn×n , and suppose first that (i) holds. This implies that A has a left inverse. In view of Exercise A.1.2, it must be that x 7→ Ax is one-to-one on Rn . By Theorem A.4.5, this means that the same function is onto. Hence x 7→ Ax is a bijection and therefore invertible (Lemma A.1.1). By Exercise A.4.8, the inverse function is linear and hence can be represented by a matrix. We denote it A−1 . For the left inverse L we have L = A−1 , since L = L(A A−1 ) = (L A)A−1 = A−1 . Now suppose there exists an R ∈ Mn×n such that A R = I . Then, A is the left inverse of R, and, by the previous argument, R is invertible with A = R −1 .
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.4 Linear Algebra
201
Pre-multiplying both sides by R gives R A = I , so R is also a left inverse of A. As we now know, this means that A is nonsingular and R = A−1 . In summary, if either (i) or (ii) holds, then A is nonsingular, with left and right inverses both equal to A−1 . Consider the linear system Ax = b, where A ∈ Mn×n and b ∈ Rn . We seek a solution x ∈ Rn . The next theorem provides conditions under which such an x is always uniquely identified. theorem A.4.8 The following statements are equivalent: (i) (ii) (iii) (iv) (v) (vi) (vii)
For each b ∈ Rn , the equation Ax = b has a unique solution. The columns of A are linearly independent. The columns of A form a basis of Rn . null A = {0}. rank A = n. det A is nonzero. A is nonsingular.
The symbol det A represents the determinant of A. For the definition, see, for example, Jänich (1994) or Cohen (2021). We note only that, for n × n matrices A and B, • det(AB) = det(A) det(B); n • det(α A) = α det A for all α ∈ R; and −1 −1 • det(A ) = (det A) whenever A is nonsingular. Most of the equivalences in Theorem A.4.8 can be established from the results presented above. The key idea is that, under these equivalent conditions, the columns of A form a basis of Rn , and hence any b ∈ Rn can be expressed uniquely as a linear combination of elements of these columns. In other words, there exists a unique x ∈ Rn with Ax = b. The remaining points are just equivalent ways of saying that the columns of A form a basis of Rn . Exercise A.4.9. Let A and B be conformable in the sense that AB is well defined. Show that rank(AB) 6 rank A, with equality if and only if B is nonsingular. [Hint: Use Theorem A.4.4.]
A.4.6
Orthogonality We recall that vectors u,v in Rn are called orthogonal and we write u ⊥ v if hu,vi = 0. For a linear subspace L of Rn , we call u ∈ Rn orthogonal to L and write u ⊥ L whenever u ⊥ v for all v ∈ L. Exercise A.4.10. The orthogonal complement of linear subspace L is defined as L ⊥ := {v ∈ Rn : v ⊥ L}. Show that L ⊥ is a linear subspace of Rn .
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
202
Math Review
Exercise A.4.11. Prove: for any linear subspace L ⊂ Rn , we have L ∩ L ⊥ = {0}. A set of vectors O ⊂ Rn is called an orthogonal set if any two distinct elements of O are orthogonal. For any orthogonal set O, the Pythagorean law
X 2 X
kuk2 u =
u∈O
u∈O
always holds. Exercise A.4.12. Prove: Orthogonality implies linear independence in the sense that O ⊂ Rn is orthogonal and 0 ∈ /O
H⇒ O is linearly independent.
An orthogonal set O ⊂ Rn is called an orthonormal set if kuk = 1 for all u ∈ O. If L is a linear subspace of Rn , O is orthonormal in L, and span O = L, then O is called an orthonormal basis of L. For example, the canonical basis {e1, . . . ,en } forms an orthonormal basis of Rn . Exercise A.4.13. Explain why an orthonormal basis O of a subspace L is, in fact, a basis of L, in the sense of the definition in §A.4.2. A matrix M is called an orthonormal matrix if M ∈ Mn×n for some n ∈ N, and, in addition, the columns of M form an orthonormal set in Rn . These kinds of matrices will be important to us when we analyze singular value decomposition. Notice that, • by definition, every orthonormal matrix is square, and n n • the n columns of an orthonormal matrix M in R form a basis of R , since they are nonzero and orthogonal. The second point tells us that M is nonsingular. The next lemma summarizes important properties of orthonormal matrices. lemma A.4.9 Fix M ∈ Mn×n and let I be the n × n identity. The following statements are equivalent: (i) (ii) (iii) (iv)
M is an orthonormal matrix. M> M = I . M M> = I . M > = M −1 .
The equivalence of (ii) and (iii) is quite striking. It tells us that a square matrix with orthonormal columns automatically has orthonormal rows. Proof Clearly (i) and (ii) are equivalent, since they are two ways of writing the same thing. Equivalence of (ii)–(iv) follows from Theorem A.4.7 on page 200.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.5 Convexity and Concavity
A.5
203
Convexity and Concavity Convexity and concavity are structures of enormous significance in economics and finance, in terms of both computation and theory. In this section we note the key definitions and provide exercises that help build familiarity.
A.5.1
Convexity and Polyhedra Convexity plays a central role in optimization and fixed point theory. As usual, a subset C of Rn is called convex if u,v ∈ C and λ ∈ [0,1] H⇒ λu + (1 − λ)v ∈ C. Exercise A.5.1. Show that" (i) The unit simplex in Rn is a convex subset of Rn . (ii) For all a ∈ Rn and ε > 0, the sphere B = {x ∈ Rn : kx − ak < ε} is convex. (iii) The intersection of an arbitrary number of convex sets in Rn is again convex. In economic optimization problems, the convex sets within which we seek extrema are usually polyhedra. A polyhedron in Rn is a set of the form P = {x ∈ Rn : Ax 6 b}
for some A ∈ Mk×n and b ∈ Rk .
(A.13)
Equivalently, P is a polyhedron in Rn if there exist scalars b1, . . . ,bk and ndimensional vectors a1, . . . ,ak such that x ∈ P if and only if ai> x 6 bi for i = 1, . . . ,k. Example A.5.1: A budget set of the form B = {x ∈ Rn+ : p > x 6 m}, where m > 0 and p ∈ Rn+ , is a polyhedron. Here p is a vector of prices and x is a consumption bundle. Indeed, B can be expressed as the set of all x ∈ Rn such that p > x 6 m and, for the nonnegativity constraints, −δi> x 6 0 for i = 1, . . . ,n, where δi is the i-th canonical basis vector in Rn . This meets the definition of a polyhedron. Given b ∈ R and nonzero c ∈ Rn , n > n • H0 := {x ∈ R : x c = b} is called a hyperplane in R , while n > n • H1 := {x ∈ R : x c 6 b} is called a halfspace in R .
Note our convention. In §A.4.4 we defined linear hyperplanes, which correspond to H0 when b = 0. Thus linear hyperplanes are a special kind of hyperplane. You will be able to confirm that the hyperplane H0 is a linear subspace of Rn if and only if b = 0. Exercise A.5.2. Show that H0 and H1 are both convex in Rn .
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
204
Math Review
Figure A.9 A polyhedron P represented as intersecting halfspaces
It is immediate from the definition that P ⊂ Rn is a polyhedron if and only if P is the intersection of k halfspaces in Rn for some k ∈ N. Figure A.9 helps illustrate this idea. An extreme point of a polyhedron P is a point p ∈ P that cannot be realized as the convex combination of other points in P. In other words, we cannot find two points x, y ∈ P that are distinct from p and satisfy λx + (1 − λ)y = p for some λ ∈ [0,1]. The extreme points of P in Figure A.9 are represented as black dots. Exercise A.5.3. Show that every polyhedron in Rn is convex. A cone in Rn is a set C ⊂ Rn such that x ∈ C implies αx ∈ C for all α > 0. Exercise A.5.4. Show that (i) the intersection of any two cones is again a cone and (ii) a cone C ⊂ Rn is convex (i.e., C is a convex cone) if and only if it is closed under addition (i.e, x, y ∈ C implies x + y ∈ C). Exercise A.5.5. The positive cone of Rn is the set Rn+ := {x ∈ Rn : x > 0}. Show that, for the partially ordered set (Rn , 6), the positive cone is an increasing subset of Rn . Show in addition that Rn+ is a convex cone.
A.5.2
Convex and Concave Functions A function g from a convex subset C of Rn to Rk is called convex if g(λu + (1 − λ)v) 6 λg(u) + (1 − λ)g(v)
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
whenever u,v ∈ C and 0 6 λ 6 1
A.5 Convexity and Concavity
205
and concave if −g is convex. Concavity of g is obviously equivalent to g(λu + (1 − λ)v) > λg(u) + (1 − λ)g(v)
whenever u,v ∈ C and 0 6 λ 6 1.
When k = 1, the function g is called, respectively, strictly convex or strictly concave if, in addition, the inequalities become strict whenever u,v are distinct and 0 < λ < 1. Exercise A.5.6. Give an example of a function g from Rn to Rn that is both convex and concave. These properties of functions are closely related to the convexity of sets. For example, the same function g is convex if and only if its epigraph epi(g) := {(x,g(x)) ∈ Rn+1 : x ∈ C} is convex. Exercise A.5.7. If C is a convex subset of Rn and g : Rn → R is convex, then Jensen’s inequality states that, for any vectors {x1, . . . ,xk } ⊂ C and weights P {λ 1, . . . ,λ k } ⊂ R with 0 6 λi 6 1 and i λi = 1, we have ! k k X X g (xi ) λi . g xi λi 6 i=1
i=1
If g is concave then the reverse inequality holds. Prove Jensen’s inequality for the case where g is convex when k = 3. In the next exercise, if {yi } is a finite collection of vectors in Rk , then maxi yi is the vector in Rk obtained by taking the maximum pointwise. The minimum mini yi is defined in a similar way. Exercise A.5.8. Fix m ∈ N and let {gi }i∈[m] be a collection of Rk -valued functions defined on a convex subset C of Rn . Show that: (i) If gi is convex for every i in [m], then g defined at each x in C by g(x) := maxi∈[m] gi (x) is also convex on C. (ii) If gi is concave for every i in [m], then g defined at each x in C by g(x) := mini∈[m] gi (x) is also concave on C. Exercise A.5.9. Let f and g map C to R, where C ⊂ Rn is convex and so are f and g. Show that (i) f + g is convex and (ii) f + g is strictly convex if, in addition, either f or g is strictly convex. Important examples of concave and convex scalar-valued functions include certain kinds of quadratic forms. For the following you should recall that a symmetric n × n matrix A is called
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
206
Math Review
• • • •
positive semidefinite if x > Ax > 0 for any x in Rn ; positive definite if x > Ax > 0 for any nonzero x in Rn ; negative semidefinite if x > Ax 6 0 for any x in Rn ; and negative definite if x > Ax < 0 for any nonzero x in Rn .
It’s important to remember (but easy to forget) that symmetry is part of the definition of these properties. You probably remember that • A is positive definite (resp., semidefinite) if and only if all its eigenvalues are strictly positive (resp., nonnegative) and • A is positive definite (resp., semidefinite) H⇒ its determinant is strictly positive (resp., nonnegative). The second statement follows from the first, since the determinant of a matrix equals the product of its eigenvalues. The quadratic form q(x) = x > Ax is • • • •
convex if and only if A is positive semidefinite; strictly convex if and only if A is positive definite; concave if and only if A is negative semidefinite; and strictly concave if and only if A is negative definite.
See, for example, Simon (1994). Exercise A.5.10. Let X be n × k. Prove the following: (i) X > X is positive semidefinite. (ii) If, in addition, X has full column rank, then X > X is positive definite.
A.6
Optimization In this section we review some key topics in optimization theory.
A.6.1
Definitions and Existence A number m contained in a subset A of R is called the maximum of A and we write m = max A if a 6 m for every a ∈ A. It is called the minimum of A, written as m = min A, if m ∈ A and a > m for every a ∈ A. Given an arbitrary set D and a function f : D → R, define max f (x) := max{ f (x) : x ∈ D} and x∈D
A point
x∗
min f (x) := min{ f (x) : x ∈ D}. x∈D
∈ D is called
∗ ∗ • a maximizer of f on D if x ∈ D and f (x ) > f (x) for all x ∈ D and ∗ ∗ • a minimizer of f on D if x ∈ D and f (x ) 6 f (x) for all x ∈ D.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
A.6 Optimization
207
Equivalently, x ∗ ∈ D is a maximizer of f on D if f (x ∗ ) = maxx∈D f (x) and a minimizer if f (x ∗ ) = minx∈D f (x). We define argmax f (x) := {x ∗ ∈ D : f (x ∗ ) > f (x) for all x ∈ D}. x∈D
The set argminx∈D f (x) is defined analogously. Example A.6.1: If f (x) = x 2 and D = [−1,1], then argmaxx∈D f (x) = {−1,1}, while argminx∈D f (x) = {0}. In the second case, where the solution set is a singleton, that is, a set with exactly one element, we write argminx∈D f (x) = 0 as well.
Exercise A.6.1. Let f : D → A ⊂ R be any given function. Prove the following: (i) If g : A → R is a strictly increasing function, then x ∗ is a maximizer of f on D if and only if x ∗ is a maximizer of g ◦ f on A. (ii) If g : A → R is a strictly decreasing function, then x ∗ is a maximizer of f on D if and only if x ∗ is a minimizer of g ◦ f on A. One important special case of part (ii) is that x ∗ ∈ D is a maximizer of f on D if and only if x ∗ is a minimizer of − f on D. Hence, any maximization problem can be converted into a minimization problem and vice-versa.
A.6.2
Convexity and Extrema § A.6.1 discussed the existence of optimizers. In this section we consider uniqueness. The key observation is that, for convex and concave functions, local optimizers are global optimizers. If C ⊂ Rn and f is a real-valued function on C, then u ∗ ∈ C is a local minimizer of f on C if there exists an open set G in C such that u ∗ ∈ G and f (u ∗ ) 6 f (u) whenever u ∈ G. A local maximizer is defined analogously. The next exercise highlights one of the most important facts concerning computation of solutions to optimization problems in real-world applications. It is especially valuable in high-dimensional settings, where optimization problems can be very challenging. Exercise A.6.2. Show that, if C ⊂ Rn is convex, f is convex and u ∗ is a local minimizer of f on C, then u ∗ is a minimizer of f on C. Similarly, if f is concave on C, then any local maximizer is a global maximizer.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
208
Math Review
A.6.3
Multivariate Quadratic Objectives § 1.4.2.3 treated a one-dimensional quadratic optimization problem. Next we treat n-dimensional problems of the same type. lemma A.6.1 If H ∈ Mn×n is positive definite, then, for any b ∈ R and a ∈ Rn , u ∗ := H −1 a is the unique minimizer of q(u) := u > H u − 2u > a + b in Rn . Exercise A.6.3. Prove that any local minimizer of q in Lemma A.6.1 is also a global minimizer. [Hint: Use Exercise A.5.9.] Exercise A.6.4. Complete the proof of Lemma A.6.1 by showing that u ∗ is a local minimizer. It suffices to show that the derivative of q at u ∗ is zero. Use the following facts from matrix calculus: a ∈ Rn and H ∈ Mn×n
A.7
H⇒
d > d > u a = a and u H u = (H + H > )u. du du
Lagrangian Duality If you have studied undergraduate economics, you will have used Lagrangian methods to solve constrained optimization problems. The objective of this section is to supply insight on when and why the method works, as well as to highlight the connection between an original constrained problem and a so-called “dual problem.” This connection yields deep insights in economics, finance, statistical learning, artificial intelligence, and many other fields.
A.7.1
Theory Let E be a subset of Rn , and let f map E to R. We aim to solve min f (x) subject to g(x) = 0 and h(x) 6 0. x∈E
(A.14)
Here g maps E to Rm and h maps E to Rk . For example, the zero symbol in the statement g(x) = 0 is a vector of zeros, and the meaning is that gi (x) = 0 in R for i in 1, . . . ,m. The interpretation of the second constraint is analogous. Any x ∈ E that satisfies the constraints in (A.14) is called feasible. Let F(g,h) be the set of all feasible x ∈ E. A feasible point that attains the minimum in (A.14) is called optimal for – or a solution to – the optimization problem. Our first claim is that the constrained optimization problem (A.14) is equivalent to the unconstrained problem P = min max L(x,θ), x∈E θ∈2
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
(A.15)
A.7 Lagrangian Duality
209
where θ := (λ,µ) and
L(x,θ) = L(x,λ,µ) := f (x) +
m X
λi gi (x) +
i=1
k X
µi h i (x).
(A.16)
i=1
Here θ ∈ 2 combines the vectors of Lagrange multipliers λ ∈ Rm and µ ∈ Rk+ , where 2 := Rm × Rk+ . By equivalent to, we mean that (i) (ii) (iii)
fˆ(x) := maxθ∈2 L(x,θ) satisfies fˆ = f on F(g,h); fˆ = +∞ on the complement of F(g,h); and together fˆ and f satisfy P := min fˆ(x) = x∈E
min
x∈F(g,h)
fˆ(x) =
min
x∈F(g,h)
f (x).
(A.17)
The first equality in (A.17) is by definition. The second two follow from (ii) and (i), respectively. Hence we need only verify (i) and (ii). Exercise A.7.1. Show that (i) and (ii) both hold. You can assume that extrema exist. The function L in problem (A.16) is usually called the Lagrangian. The P in (A.15) stands for primal. So far we have shown that the original constrained problem and the primal problem are the same. The next step is to pair the primal problem with its dual problem, which is obtained by reversing the order of min and max in the primal: D = max min L(x,θ). θ∈2 x∈E
(A.19)
The dual problem has two attractive features. One is that, when minimizing with respect to x, we do not need to concern ourselves with the constraints on x in the original formulation (A.14). The second is that, since L(x,θ) is linear in θ, and since we are minimizing a family of these functions with respect to x, the minimizer is a concave function (see page 205). Concavity assists maximization, which is the next step in solving D. Exercise A.7.2. Show that D 6 P always holds. The result D 6 P in Exercise A.7.2 is called weak duality. If P = D, then strong duality is said to hold. Unlike weak duality, strong duality requires conditions on the primitives. Evidently strong duality holds if and only if it is valid to reverse the order of the min and max operators in the definition of the primal (or the dual). Results of this kind are called min-max theorems. Such theorems hold at “saddle points” of the function L. The next section explains.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
210
Math Review
A.7.2
Saddle Points and Duality We seek necessary and sufficient conditions for strong duality, which will lead to a characterization of minimizers for the original constrained problem. To do so, we again take θ := (λ,µ) and 2 := Rm × Rk+ , so that P = min max L(x,θ) x∈E θ∈2
and
D = max min L(x,θ).
(A.20)
θ∈2 x∈E
A pair (x ∗,θ∗ ) in E × 2 is called a saddle point of L if L(x ∗,θ) 6 L(x ∗,θ∗ ) 6 L(x,θ∗ )
for all
(x,θ) ∈ E × 2.
(A.21)
A depiction of a saddle point of a given bivariate function (x,θ) 7→ L(x,θ) ∈ R is given in Figure A.10. The left-hand side of the top panel is a 3D visualization, and the right-hand side is a contour plot of the same function. The saddle point is at the center. When the extrema in (A.20) exist, we have the following result: theorem A.7.1 If L has a saddle point (x ∗,θ∗ ) in E × 2, then strong duality holds. Moreover, P = D = L(x ∗,θ∗ ), and x ∗ solves the constrained optimization problem (A.14). Proof Let (x ∗,θ∗ ) be a saddle point (x ∗,θ∗ ) of L in E × 2. We have, for all (x,θ) ∈ E × 2, P 6 max L(x ∗,θ) 6 L(x ∗,θ∗ ) 6 min L(x,θ∗ ), θ
x
L(x∗ , θ) ∗
L(x, θ)
L(x, θ )
θ∗ θ∗
x∗
x∗
θ 7→ L(x∗, θ)
x 7→ L(x, θ∗ ) Figure A.10 A saddle point (x ∗,θ ∗ ) of the function L
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
211
A.7 Lagrangian Duality
where the first inequality is by definition and the second two are by the saddle point property. The last term is clearly dominated by D, so we conclude that P 6 L(x ∗,θ∗ ) 6 D. But, by weak duality, we also have D 6 P, so P = L(x ∗,θ∗ ) = D. Finally, to confirm that x ∗ solves the original constrained problem, suppose to the contrary that there exists an x0 ∈ E that satisfies the constraints and yields f (x0 ) < f (x ∗ ). Since the constraints are satisfied at both x0 and x ∗ , we can apply (A.18) on page 233 to obtain maxθ∈2 L(x0,θ) = f (x0 ) and maxθ∈2 L(x ∗,θ) = f (x ∗ ). Hence the second inequality of the saddle point condition implies f (x ∗ ) = max L(x ∗,θ) 6 max L(x0,θ) = f (x0 ). θ∈2
θ∈2
This contradicts the hypothesis that f (x0 ) < f (x ∗ ). Theorem A.7.1 tells us that to solve the constrained optimization problem and establish strong duality, we need only obtain a saddle point of the Lagrangian.
A.7.3
Karush, Kuhn, and Tucker For well-behaved problems, saddle points can be identified via well-known firstorder conditions, called the Karush–Kuhn–Tucker (KKT) conditions. To state them, we return to the original problem (A.14) and write θ explicitly as (λ,µ), so that (x ∗,λ ∗,µ∗ ) ∈ E × Rm × Rk+ satisfies the saddle point condition if L(x ∗,λ,µ) 6 L(x ∗,λ ∗,µ∗ ) 6 L(x,λ ∗,µ∗ )
for all
x ∈ E,λ ∈ Rm and µ ∈ Rk+ .
The KKT conditions are met by (x ∗,λ∗,µ∗ ) ∈ E × Rm × Rk+ if x ∗ ∈ F(g,h), ∇ f (x ∗ ) +
m X
k X
λi∗ ∇gi (x ∗ ) +
and
(A.22)
i=1
i=1
µi∗ h i (x ∗ ) = 0
µi∗ ∇h i (x ∗ ) = 0,
for all i ∈ [k].
(A.23)
Here we are requiring that f ,g,h are all differentiable at x ∗ , and, for a given function q : E → R, we use ∇ to represent the vector of partial derivatives. Equation (A.22) requires that the derivative of the Lagrangian with respect to x is zero at x ∗ . The second condition is called the complementary slackness condition. The KKT conditions are nothing more than saddle point conditions. Condition (A.22) is the first-order condition for an interior minimizer of the Lagrangian with respect to x, at the point (x ∗,θ∗ ), which tries to identify the local minimum visualized in the lower right panel of Figure A.10. The complementary slackness condition is also needed because if µi∗ h i (x ∗ ) = 0 fails at some i, then µi∗ h i (x ∗ ) < 0 must hold, in which case we could strictly increase the Lagrangian by shifting µi∗ to 0. This violates the saddle point property.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
212
Math Review
If enough regularity conditions hold, then the KKT conditions exactly identify extremal points. Here is one example, which is proved in Chapter 8 of Matousek and Gärtner (2007). theorem A.7.2 (Karush–Kuhn–Tucker) If E is open, f is continuously differentiable and convex, and both g and h are affine functions, then x ∗ minimizes f on F(g,h) if and only if there exists a pair (λ ∗,µ∗ ) ∈ Rm × Rk+ such that the KKT conditions hold.
https://doi.org/10.1017/9781009456340.008 Published online by Cambridge University Press
Appendix B Solutions to Selected Exercises
Solution to Exercise 1.2.1. For λ 1 = i, we have ! ! ! 0 −1 −1 −i Ae1 = = = λ 1 e1 . 1 0 i −1 Similarly for λ2 = −i, we have 0 Ae2 = 1
! ! ! −1 −1 i = = λ 2 e2 . 0 −i −1
Solution to Exercise 1.2.2. Fix an eigenpair (λ,e) of A and a nonzero scalar α. We have A(αe) = α Ae = λ(αe). Hence αe is an eigenvector and λ is an eigenvalue, as claimed. Solution to Exercise 1.2.3. Fix A ∈ Mn×n and τ > 0. If λ ∈ σ(A), then τn det(A − λ I ) = 0, or det(τ A − τλ I ) = 0. Hence τλ ∈ σ(τ A). To obtain the converse implication, multiply by 1/τ. Solution to Exercise 1.2.4. If p(λ) := det(A − λ I ) has n distinct roots, then |σ(A)| = n. For each λi ∈ σ(A), let ei be a corresponding eigenvector. It suffices to n show that {ei }i=1 is linearly independent. To this end, let k be the largest number such that {e1, . . . ,ek } is independent. Seeking a contradiction, suppose that k < n. Then Pk ek+1 = i=1 αi ei for suitable scalars {αi }. Hence, by Aek+1 = λ k+1 ek+1 , we have k X i=1
αi λi ei =
k X
αi λ k+1 ei
⇐⇒
i=1
k X
αi (λi − λ k+1 )ei = 0.
i=1
Since {e1, . . . ,ek } is independent, we have αi (λi − λk+1 ) = 0 for all i. At least one αi is nonzero, so λi = λ k+1 for some i 6 k. Contradiction. Solution to Exercise 1.2.5. Suppose to the contrary that there is one zero column vector in P. Then P is not nonsingular. Contradiction.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
214
Solutions to Selected Exercises
Solution to Exercise 1.2.6. Let A be as stated, with A = P D P −1 . Using elementary properties of the trace and determinant, we have X trace(A) = trace(P D P −1 ) = trace(D P P −1 ) = trace(D) = λi i
and det(A) = det(P) det(D) det(P −1 ) = det(P) det(D) det(P)−1 = det(D) =
Y
λi .
i
Solution to Exercise 1.2.8. If I is the identity and I e = λe for some nonzero e, then e = λe and hence λ = 1. Hence σ(A) = {1}. At the same time, I is diagonalizable, since I = I D I −1 when D = I . Solution to Exercise 1.2.19. Fix A ∈ Mn×n and b ∈ Rn , where r (A) < 1. We can write x = Ax + b as (I − A)x = b. Since r (A) < 1, I − A is invertible and hence the linear system (I − A)x = b has unique solution x ∗ = (I − A)−1 b. The expression P m x∗ = ∞ m=0 A b follows from the Neumann series lemma. Solution to Exercise 1.2.20. In what follows, Pw is as defined in (1.2), and, for any matrix Q, the symbol Q(i, j) denotes the i, j-th element. ((i), (⇒)) Suppose that Pw is irreducible and yet α = 0. Then, by the expression for Pwm in (1.3), we have Pwm (1,2) = 0 for all m. This contradicts irreducibility, so α > 0 must hold. A similar argument shows that β > 0. ((i), (⇐)) If α,β > 0, then the off-diagonal elements of Pw are strictly positive. Moreover, the diagonal elements of Pw2 are strictly positive. Hence Pw + Pw2 0 and Pw is irreducible. ((ii), (⇒)) Suppose that Pw is primitive. Then Pw is irreducible, so 0 < α,β 6 1 holds. It remains only to show that min{α,β} < 1. Suppose to the contrary that α = β = 1. Then Pwm has zero diagonal elements when m is odd and zero off-diagonal elements when m is even. This contradicts the primitive property, so min{α,β} < 1 must hold. ((ii), (⇐)) Suppose that 0 < α,β 6 1 and α < 1. Some algebra shows that Pw2 0. The same is true when 0 < α,β 6 1 and β < 1. Hence Pw is primitive. Solution to Exercise 1.2.22. Fix A ∈ Mn×k with A > 0, along with x, y ∈ Rk . From x 6 y we have y − x > 0, so A(y − x) > 0. But then Ay − Ax > 0, or Ax 6 Ay. Solution to Exercise 1.3.2. For the first claim, fix x ∈ S and z ∈ (0,1]. If κ(z) = x, then, since all elements of S are distinct, the definition of κ implies z ∈ I (x). Conversely, if z ∈ I (x), then, since all intervals are disjoint, we have κ(z) = x. For the second claim, pick any x ∈ S, and observe that, by the first claim, κ(W ) = x precisely when W ∈ I (x). The probability of this event is the length of the interval
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
215
I (x), which, by construction, is ϕ(x). Hence P{κ(W ) = x} = ϕ(x) for all x ∈ S as claimed. Solution to Exercise 1.3.3. Fix j ∈ [n]. Observe that Y := 1{κ(W ) = j} is a d Bernoulli random variable. The expectation of such a Y equals P{Y = 1}. As κ(W ) = ϕ, this is ϕ( j). Solution to Exercise 1.3.5. Draw U uniformly on (0,1] and set the coin to heads if U 6 δ. The probability of this outcome is P{U 6 δ} = δ. Solution to Exercise 1.3.6. For the solution we assume that S is finite, although the argument can easily be extended to densities. On the computer, we flip a biased coin B ∈ {0,1} with P{B = 0} = δ and then (i) draw Y from ϕ if B = 0, or (ii) draw Y from ψ if B = 1. With this set up, by the law of total probability, P{Y = s} = P{Y = s | B = 0}P{B = 0} + P{Y = s | B = 1}P{B = 1} = δϕ(s) + (1 − δ)ψ(s). d
In other words, Y = f . Solution to Exercise 1.3.7. Let P and Q be as stated. Evidently P Q > 0. Moreover, P Q1 = P1 = 1, so P Q is stochastic. That r (P) = 1 follows directly from Lemma 1.2.7. By the Perron–Frobenius theorem, there exists a nonzero, nonnegative row vector ϕ satisfying ϕ P = ϕ. Rescaling ϕ to ϕ/(ϕ1) gives the desired vector ψ. Solution to Exercise 1.3.8. Fix p > 0 and let X be L N (µ,σ2 ). We have E|X | p = EX p = E exp( pµ + pσ Z )
d
for Z = N (0,1).
d
Since pµ + pσ Z = N ( pµ, p 2 σ2 ), we can apply the formula for the mean of a lognormal distribution to obtain m p = exp( pµ + ( pσ)2 /2) < ∞. Solution to Exercise 1.3.9. Let X have a Pareto tail with tail index α, and let G be its ccdf. Fix r > α. Under the Pareto tail assumption, we can take positive constants b and x¯ such that G(t) > bt −α whenever t > x. ¯ Using (1.14) we have r
Z
EX = r
t 0
But
R∞ x¯
∞
r −1
Z G(t) dt > r
x¯
t 0
r −1
∞
Z G(t) dt + r
t r −1 bt −α dt.
x¯
t r −α−1 dt = ∞ whenever r − α − 1 > −1. Since r > α, we have EX r = ∞.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
216
Solutions to Selected Exercises
d
Solution to Exercise 1.3.10. Fix λ > 0 and suppose X = Exp(λ). A simple integration exercise shows that P{X > t} = e−λt . Now fix α > 0. Since limt→∞ t α e−λt = 0, the random variable X does not obey a power law. Solution to Exercise 1.3.11. Let p and the constants γ,c > 0 and x¯ ∈ R+ be as described in the exercise. Pick any t > x. ¯ By the usual rules of integration,
P{X > t} = c
∞
Z
u −γ du = −
t
c 1−γ t . 1−γ
With α := γ − 1, we then have t α P{X > t} = c/α, and X is Pareto-tailed with tail index α. Solution to Exercise 1.4.1. Let 𝒢 be a directed acyclic graph and fix u in 𝒢. Suppose to the contrary that every node reachable from u has positive out-degree. In this case, we can construct a directed walk from u of arbitrary length. But 𝒢 has only finitely many nodes, so any such walk must eventually cycle. Contradiction. Solution to Exercise 1.4.3. If (V , E) is undirected, then the adjacency matrix is symmetric. Solution to Exercise 1.4.4. Let A> = (ai0 j ), so that ai0 j = a ji for each i, j. By definition, we have ( j,k) ∈ E 0 ⇐⇒ a 0jk > 0 ⇐⇒ ak j > 0 ⇐⇒ (k, j) ∈ E, which proves (i). Regarding (ii), to say that k is accessible from j in 𝒢0 means that we can find vertices i 1, . . . ,i m that form a directed path from j to k under 𝒢0 , in the sense that i 1 = j, i m = k, and each successive pair (i `,i `+1 ) is in E 0 . But then, by (i), i m , . . . ,i 1 provides a directed path from k to j under 𝒢, since each successive pair (i `+1,i ` ) is in E. Solution to Exercise 1.4.5. Recalling that ∂/(∂ xk )x > Ax = (x > A)k , the first-order condition corresponding to (1.26), taking the actions of other players as given, is xk = α(x > A)k + εk
(k ∈ [n]).
Concatenating into a row vector and then taking the transpose yields x = α Ax + ε, where we used the fact that A is symmetric. Since r (α A) = αr (A), the condition r (A) < 1/α implies that r (α A) < 1, so, by the Neumann series lemma, the unique solution is x ∗ = (I − α A)−1 ε.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
217
Solutions to Selected Exercises
Solution to Exercise 1.4.6. When A is strongly connected, the Perron–Frobenius theorem tells us that r (A) > 0 and A has a unique (up to a scalar multiple) dominant right eigenvector satisfying r (A)e = Ae. Rearranging gives (1.32). Solution to Exercise 1.4.10. When β < 1/r (A) we have r (β A) < 1. Hence, we can express (1.36) as κ = 1 + β Aκ and employ Theorem 1.2.5 to obtain the stated result. Solution to Exercise 2.1.1. Fix j ∈ [n]. Since ai j = z i j /x j , we have η j = Hence, if v j > 0, then η j < 1.
Pn
i=1 z i j xj
.
Solution to Exercise 2.1.2. It follows easily from Assumption 2.1.1 that η(A) < 1. Moreover, since A > 0, the results in §1.2.3.4 imply that r (A) is dominated by the maximum of the column sums of A. But this is precisely η(A). Hence r (A) 6 η(A) < 1. Solution to Exercise 2.1.3. Let (A,d) be as stated. When A is irreducible, L := P∞ i ∗ ∗ i=1 A 0 and x = Ld. Since d is nontrivial, x 0 follows from L 0 and the definition of matrix multiplication. Solution to Exercise 2.1.4. If r (A) < 1, then I − A is nonsingular. At the same time, for the nontrivial solution x, we have (I − A)x = 0. Contradiction. If, on the other hand, r (A) = 1, then, since r (A) is an eigenvalue (by the Perron–Frobenius theorem), we have Ax = x for some x 0. The uniqueness claim follows from the Perron–Frobenius theorem. Solution to Exercise 2.1.7. Let λ be an eigenvalue of A, and let e be the corresponding eigenvector. Then, for all i ∈ [n], we have X j
ai j e j = λei
⇐⇒
X zi j e j = λei xj j
⇐⇒
X j
fi j
ej ei =λ , xj xi
where we have used the fact that x 0. It follows that λ is an eigenvalue of F. The same logic runs in reverse, so A and F share eigenvalues. Hence r (A) = r (F). Solution to Exercise 2.2.2. We need to show that 1> Am 1 = n(1 − α)m for any m. We prove this by induction, noting that 1> A = (1 − α)1> by the CRS assumption. It follows immediately that 1> A1 = n(1 − α). Now suppose also that 1> Am 1 = n(1 − α)m holds. Then 1> Am+1 1 = 1> A Am 1 = (1 − α)1> Am 1 = n(1 − α)m+1, where the last step is by the induction hypothesis.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
218
Solutions to Selected Exercises
Solution to Exercise 2.2.3. Inserting (2.18) into (2.19) and differentiating with respect to ` j and qi j leads to the first-order conditions given in (2.20). It can be shown that these local maximizers are global maximizers, although we omit the details. Solution to Exercise 2.2.5. By Exercise 2.2.1 we have r (A) < 1. Hence L = (I − A)−1 is well defined, and, moreover, we can solve (2.22) using the Neumann series lemma, yielding ρ = −(I − A> )−1 ε. Since the inverse of the transpose is the transpose of the inverse, we can write this as ρ = −L > ε. Unpacking gives the equation stated in the exercise. Solution to Exercise 2.2.7. Equation (2.24) can be expressed as h i = n −1 + n j ai j h j . Letting h = (h i ) be a column vector in R and letting 1 be a column vector of ones, these n equations become h = n −1 1 + Ah. Since r (A) < 1, the unique solution is h = n −1 (I − A)−1 1 = n −1 L1. Unpacking the vector equation gives the stated result.
P
Solution to Exercise 2.2.8. From the result in Exercise 2.2.2, we have 1> h =
1 X > m 1 X 1 >X m 1 A 1= 1 A 1= n (1 − α)m . n n n m>0
m>0
m>0
The last expression evaluates to 1/α, as was to be shown. Solution to Exercise 2.2.9. This expression follows easily from the definition of variance and the independence of firm-level shocks, which allows us to pass the variance through the sum. Solution to Exercise 2.2.11. Let h ∗ := 1/(αn). The claim is that h ∗ is the minPn imizer of khk on Rn+ under the constraint i=1 h i = 1/α. Squaring the objective function and substituting the constraint into the objective by taking h n = 1/α − h 1 − · · · − h n−1 , we are led to the equivalent problem of finding the minimizer of f (h 1, . . . ,h n−1 ) := h 21 + · · · + h 2n−1 +
1 − h 1 − · · · − h n−1 α
2 .
Since f is convex, any local minimizer is a global minimizer. Moreover, the first-order conditions give 1 hi = − h 1 − · · · − h n−1 = h n . α for all i. Hence, the solution vector is constant over i. Letting c be this constant and using the constraint gives nc = 1/α. The claim follows. Solution to Exercise 2.2.12. Let h ∗ be an n-vector with h ∗k = 1/α for some k and h ∗j = 0 for other indices. Clearly kh ∗ k = 1/α. Hence it suffices to show that, for any Pn h ∈ Rn+ with i=1 h i = 1/α, we have khk 6 1/α.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
219
Pn Fix h ∈ Rn+ with i=1 h i = 1/α. Since we are splitting 1/α into n parts, we P can express h as (w1 /α, . . . ,wn /α), where 0 6 wi 6 1 and i wi = 1. By Jensen’s inequality (Exercise A.5.7), we have !2 X wi 2 X wi 1 6 = 2. α α α i
i
Taking the square root gives khk 6 1/α, as was to be shown. Solution to Exercise 2.3.3. For α > 0 we always have kαuk0 = kuk0 , which violates positive homogeneity. Solution to Exercise 2.3.6. Let k·k be a norm on Rn , let (u m ) be a sequence in Rn , and let u be a point in Rn . To show that (i) implies (ii), we fix a ∈ Rn and observe that for all m ∈ N, | ha,u m i − ha,ui | = | ha,u m − ui | 6 ku m − uk1 max |ai |. i
Hence convergence in `1 norm implies (ii). In view of Exercise 2.3.5, convergence in k · k implies convergence in `1 , so (i) H⇒ (ii) is confirmed. To show that (ii) implies (iii) at the j-th component, we just specialize a to the j-th canonical basis vector. Finally, to show that (iii) implies (i), we first note that, by the equivalence of norms, it is enough to show that pointwise convergence implies `1 convergence; that is, X
(iii) H⇒ ku m − uk1 = | δ j ,u m − u | → 0, j∈[n]
where δ j is the j-th canonical basis vector. To prove that this sum converges to zero, it suffices to show that every element of the sum converges to zero (see §A.3.2), which is true by (iii). Solution to Exercise 2.3.7. Consider the claim that u m → x and vm → y in implies u m + vm → x + y. We know this is true in the scalar case n = 1. Moreover, Lemma 2.3.1 tells us that convergence in Rn holds if and only if it holds componentwise – which is just the scalar case. The rest of the proof is similar.
Rn
Solution to Exercise 2.3.8. The Frobenius norm reduces to the Euclidean norm for column and row vectors, so (2.32) requires that | hA, Bi F | 6 kAk F kBk F . This bound certainly holds: It is the Cauchy–Schwarz inequality. Solution to Exercise 2.3.9. Let a := sup f (u), u6=0
where
f (u) :=
kAuk , kuk
and let b := sup kAuk. kuk=1
Evidently a > b because the supremum is over a larger domain. To see the reverse, fix ε > 0 and let u be a nonzero vector such that f (u) > a − ε. Let α := 1/kuk and let u b := αu. Then https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
220
Solutions to Selected Exercises
b > kAu b k =
kAu b k kα Auk α kAuk = = = f (u) > a − ε. ku b k kαuk α kuk
Since ε was arbitrary, we have b > a. Solution to Exercise 2.3.10. Let A and B be elements of Mn×k and Mn× j , respectively. Fix v ∈ Rn . Since kAuk 6 kAk · kuk for any vector u, we have kABvk 6 kAk · kBvk 6 kAk · kBk · kvk, from which (2.32) easily follows. Solution to Exercise 2.3.15. Let (Am ) and (Bm ) have the stated properties. Regarding (i), we use the triangle inequality to obtain kAm − Ak = kAm − Bm + Bm − Ak 6 kAm − Bm k + kBm − Ak. Both terms on the right converge to zero, which completes the proof. Regarding (ii), we use the submultiplicative property to obtain kB Am C − B ACk 6 kBkkAm − AkkCk → 0. Solution to Exercise 2.3.17. Let k · ka and k · kb be two norms on Mn×n . By the results in §2.3.2.5, these norms are equivalent, so there exist constants M, N such that kAk ka 6 MkAk kb 6 N kAk ka for all k ∈ N. ∴
1/k
kAk ka
1/k
6 M 1/k kAk kb
1/k
6 N 1/k kAk ka
for all k ∈ N. Taking k → ∞, we see that the definition of the spectral radius is independent of the choice of norm. Solution to Exercise 2.3.18. Since r (A) < 1, we can find a constant K and an ε > 0 such that k > K implies kAk k < (1 − ε)k . Setting M := maxk6K kAk k and δ := 1 − ε produces the desired constants. Solution to Exercise 2.3.19. Suppose r (A) < 1. Iterating backwards on xt = Axt−1 + d yields xt = d + Ad + · · · + At−1 d + At x0 . By the Neumann series lemma, P we have x ∗ = t>0 At d, so X x ∗ − xt = A j d − At x 0 . j>t
Hence, with k · k as both the Euclidean vector norm and the matrix operator norm, we have
X X
∗ j t
kx − xt k = A d − A x0 6 kA j kkdk − kAt kkx0 k.
j>t
j>t Using r (A) < 1 again, it now follows from Exercise 2.3.18 that kx ∗ − xt k → 0 as t → ∞. 1/m
Solution to Exercise 2.3.20. We have kAm k1 = n(1 − α)m and so kAm k1 1/m n (1 − α). Taking m → ∞ gives r (A) = 1 − α.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
=
Solutions to Selected Exercises
221
Solution to Exercise 2.3.21. Let k · k be a norm on Rn . From the Perron–Frobenius theorem (Theorem 1.2.6), when A is primitive, kr (A)−m Am xk → c as m → ∞, where c > 0 whenever x 0. Hence limm→∞ kAm xk1/m = limm→∞ r (A)c1/m = r (A). Solution to Exercise 2.3.22. We prove only that the stated conditions on A imply that A> is weakly chained substochastic, since the proof of the reverse implication is very similar. We set ai0 j := a ji , so that A> = (ai0 j ). Let A have the stated properties. Since A has less than unit column sums, A> has less than unit rows, so A> is substochastic. P Now fix m ∈ [n] and take i ∈ [n] such that i → m under A and k aki < 1. By Exercise 1.4.4 on page 34, i → m under A is equivalent to m → i under A> . P P 0 Moreover, k aki < 1 is equivalent to k aik < 1. Hence A> is weakly chained substochastic. Solution to Exercise 2.3.23. Let A be the adjacency matrix of an input–output network such that value added is nonnegative in each sector. In what follows, we write ai0 j for the i, j-th element of A> , so that ai0 j = a ji . Let’s say that A has property U if, for each sector in the network, there exists an upstream supplier with positive value added. Property U is equivalent to the statement P that, for all m ∈ [n], there is an i ∈ [n] with i → m under A and k aki < 1. By Exercise 2.3.22, this is equivalent to the statement that A> is weakly chained substochastic. Since A> is substochastic, this is, in turn, equivalent to r (A> ) < 1. But r (A) = r (A> ), so property U is equivalent to r (A) < 1. Solution to Exercise 2.3.25. Let A = diag(a,1), where 0 < a < 1. Clearly r (A) = 1. Let b> = (1,0), and let x > = (1/(1 − a),0). Simple algebra shows that x = Ax + b. Solution to Exercise 3.1.1. If the path fails to reach d in n − 1 steps, then, since |V | = n, there exists a vertex x ∈ V that appears twice in (x1, . . . ,xn ). This means there exists a cycle from x, which contradicts our assumption that 𝒢 is a directed acyclic graph. Solution to Exercise 3.1.2. Fix q ∈ U and σ ∈ 6. Nonnegativity of Tσ q is obvious. Also, (Tσ q)(d) = c(d,d) + q(d) = 0, where the first equality is by σ(d) = d and the second is by q(d) = 0 and c(d,d) = 0. Hence Tσ q ∈ U , as required. Solution to Exercise 3.2.1. Since prices are positive (more output means more revenue), we expect that both inequality constraints (see (3.10)) will hold with equality. Reading from the figure, the equalities are 2q1 + 5q2 = 30 and 4q1 + 2q2 = 20. Solving simultaneously leads to q = (2.5,5.0). Solution to Exercise 3.2.3. The equality constraint Ax = b can be replaced by the two inequality constraints Ax 6 b and −Ax 6 −b. The constraint x > 0 can be
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
222
Solutions to Selected Exercises
replaced by −x 6 0. If we unpack these matrix inequalities, row by row, we obtain a collection of constraints, each of which has the form h > x 6 g for suitable h ∈ Rn and g ∈ R. The claim now follows from the definition of a polyhedron on page 203. Solution to Exercise 3.3.1. Fix y ∈ Y. The distributions ϕ and ψ are assumed to be everywhere positive, so if (3.18) holds for T , then ϕ(x)1{T (x) = y} > 0 for some location x. Hence, there exists an x ∈ X such that T (x) = y. Solution to Exercise 3.3.2. One scenario where no Monge map exists is when |Y| > |X|. For example, suppose X = {x1 } and Y = {y1, y2 }, with ϕ(x1 ) = 1 and ψ(yi ) ∈ (0,1) for i = 1,2. Either x1 is mapped to y1 or it is mapped to y2 . In either case, the Monge map condition (3.18) fails for both y1 and y2 . Solution to Exercise 3.3.3. Let T be a self-map on [n]. If T is a Monge map, then, P by the definition in (3.18), we must have i (1/n)1{T (i) = j} = 1/n for all j. If T is not a bijection, then there exist indices i,k, j such that i 6= k and T (i) = T (k) = j. This clearly violates the previous equality. P Conversely, if T is a bijection on [n], then T satisfies i (1/n)1{T (i) = j} = 1/n for all j. Hence T is a Monge map. Solution to Exercise 3.3.6. Applying (3.24) on page 113, we have > ψ = vec(ψ> ) = vec(1> n π Im ) = (Im ⊗ 1n ) vec(π).
Solution to Exercise 3.3.7. Let π be feasible for the primal problem, and let (w, p) be feasible for the dual. By dual feasibility, we have c(x, y) > p(y) − w(x) for all x, y, so XX XX XX hπ,ci > π(x, y)[ p(y) − w(x)] = π(x, y) p(y) − π(x, y)w(x). x
y
x
y
x
y
Rearranging and using primal feasibility now gives hπ,ci > p,ψ − w,ϕ . This proves the first claim. To see that D 6 P follows from the last inequality: Just fix π ∈ 5(ϕ,ψ) and maximize over all feasible dual pairs to obtain hπ,ci > D. Now minimize over π ∈ 5(ϕ,ψ). Solution to Exercise 3.3.8. From mina∈A f (a) = maxb∈B g(b), we have f (a) > ¯ with f (a) ¯ we have f (a) ¯ 6 g(b) for all (a,b) ∈ A × B. Taking (a, ¯ b) ¯ = g(b), ¯ = g(b) f (a) for any given a ∈ A. In particular, a¯ minimizes f on A. The argument for b¯ is similar. Solution to Exercise 3.3.9. Since any outflow from some node i is matched by equal inflow into some node j, summing both sides of (3.34) across all i ∈ V yields (3.32).
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
223
Solution to Exercise 3.3.11. Verifying the claim is just a matter of working with the definition of A. Fixing i ∈ [n], we have (Aq)(i) =
m X
aik qk =
k=1
This is equal to
P
m X
1{ek leaves i}qk −
k=1
j∈𝒪(i) q(i, j) −
m X
1{ek points to i}qk .
k=1
P
v∈ℐ(i) q(v,i),
as was to be shown.
Solution to Exercise 3.3.12. To the code that solves the original version of Example 3.3.1, we need to add bounds = ((0, (0, (0, (0,
5), None), None), None))
and then change the function call to result = linprog(c, A_eq=A, b_eq=b, method=’highs-ipm’, bounds=bounds) print(result.x)
The output is [5. 5. 5. 5.], which also agrees with our intuition. Solution to Exercise 4.1.2. Point (i) is immediate from the definition of F. Regarding (ii), from q(i, j) = q(i, j − 1) + P(i, j) we have P(i, j) = q(i, j) − q(i, j − 1), which is the length of the interval (q(i, j −1),q(i, j)]. The probability that Ut+1 falls in this interval is its length, which we just agreed is P(i, j). The proof is now complete. Solution to Exercise 4.1.3. P k is stochastic for all k ∈ N by induction and the fact that the set of stochastic matrices is closed under multiplication (see §1.3.1.3). Solution to Exercise 4.1.5. Let ℳ be as described. In this setting, the requirement that the transition matrix P is stochastic implies that p(x,x) = 1 and P(x, y) = 1{x = y}. Thus, P = I , the n × n identity matrix. Every distribution is stationary because ψ I = ψ for all ψ ∈ 𝒟(S). Solution to Exercise 4.1.6. Let G be a continuous function from [0,1] to itself, and set f (x) := Gx − x. Since G is a self-map on [0,1], we have f (0) = G0 > 0 and f (1) = G1 − 1 6 0, so f is a continuous function on [0,1] satisfying f (0) > 0 and f (1) 6 0. Existence of an x satisfying f (x) = 0 follows from the intermediate value theorem. The same x is a fixed point of G. Solution to Exercise 4.1.7. Let P be a Markov matrix on finite set S. Suppose in particular that S has d elements, so we can identify functions in R S with vectors in Rd and 𝒟(S) with the unit simplex in Rd . The set 𝒟(S) is a closed, bounded, and convex subset of Rd that P maps into itself. As a linear matrix operation, the map ψ 7→ ψ P is continuous. Existence of a fixed point now follows from Brouwer’s fixed point theorem (p. 141).
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
224
Solutions to Selected Exercises
Solution to Exercise 4.2.2. Let ℳ be a finite Markov model with states S = {1,2} and edge set E = {(1,2),(2,2)}. Thus, the chain immediately moves to state 2 and stays there forever. The corresponding transition matrix is ! 0 1 P= . 0 1 If h is P-harmonic, then h(x) = Ph(x) = h(2). Hence h is constant. This shows that P is ergodic. At the same time (S, E) is not strongly connected. Solution to Exercise 4.2.3. Let ℳ and A have the stated properties. Fix x ∈ S. Consider a P-chain (X t ) that starts at x. By property (b), there exists an a ∈ A and a k 6 n := |S| such that ε x := P{X k = a} is strictly positive. Once (X t ) enters A it never leaves, so X k = a implies X n ∈ A. Hence P{X n ∈ A} > ε x . With ε := minx∈S ε x > 0, we then have P{X n ∈ A} > ε for any initial condition x. P Another way to state this is y∈Ac P n (x, y) 6 1 − ε for all x ∈ S, which proves the first claim. Regarding the second claim, fix ψ ∈ 𝒟(S) and let ψt = ψ P t for all t. Observe that, for fixed m ∈ N, we have ψ(m+1)n = P n ψmn . As a result, for y ∈ Ac , we have X X ψ(m+1)n (y) = P n (x, y)ψmn (x) = P n (x, y)ψmn (x). x∈S
x∈Ac
X X
X
Summing over y gives X
ψ(m+1)n (y) =
y∈Ac
P n (x, y)ψmn (x) =
y∈Ac x∈Ac
X
x∈Ac
P n (x, y) ψmn (x).
y∈Ac
Let ηt := x∈Ac ψt (x) be the amount of probability mass on Ac at time t. Using the first claim and the definition of ηt now gives η(m+1)n 6 (1 − ε)ηmn . Hence ηmn → 0 as m → ∞. At the same time, ψmn → ψ ∗ as m → ∞, so X X ψ ∗ (x) = lim ψmn (x) = lim ηmn = 0. P
x∈Ac
m→∞
m→∞
x∈Ac
The second claim is now verified. Solution to Exercise 4.2.4. Regarding part (i), the triangle inequality, combined with the assumption that ϕ,ψ ∈ 𝒟(S), gives the bound X X X |ϕ(x) − ψ(x)| 6 |ϕ(x)| + |ψ(x)| 6 2. x
x
x
Regarding part (ii), if P is a stochastic matrix, then XX X X X ρ(ϕ P,ψ P) = P(x, y)ϕ(x) − P(x, y)ψ(x) 6 P(x, y) ϕ(x) − ψ(x) . y x y x x
Swapping the order of summation and using
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
P
y
P(x, y) = 1 proves the claim.
Solutions to Selected Exercises
225
Solution to Exercise 4.2.7. Fix ϕ,ψ ∈ 𝒟(S). From (4.27) we know that (4.29) is true when t = 1. Now suppose it is true at t. Then, using the fact that (4.27) holds for any pair of distributions, ρ(ϕ P t+1,ψ P t+1 ) 6 (1 − α(P))ρ(ϕ P t ,ψ P t ) 6 (1 − α(P))t+1 ρ(ϕ,ψ), where the last step uses the induction hypothesis. Hence (4.29) also holds at t + 1 and, by induction, at all t ∈ N. Solution to Exercise 4.2.9. If ℳ is strongly connected and aperiodic, then P is primitive, in which case there exists a k ∈ N with P k 0. Clearly α(P k ) > 0. Solution to Exercise 4.2.11. All elements of G are strictly positive, so a directed edge exists between every pair of pages u,v ∈ W . This clearly implies strong connectedness. Solution to Exercise 4.2.12. For any u,u 0,v ∈ W , we have G(u,v) ∧ G(u 0,v) > 1 − δ. Hence α(G) > 1 − δ. Therefore, by (4.31), we have ρ(ψG t ,g ∗ ) 6 2δt . Solution to Exercise 4.2.14. If 𝒮 is strongly connected and aperiodic, then the adjacency matrix T is primitive, so there exists a k ∈ N such that T k 0. Hence α(T k ) > 0, and Proposition 4.2.6 applies. Solution to Exercise 5.1.3. From the bound in Exercise 5.1.2, we obtain ku m − u k k 6
λm i λ ku 0 − u 1 k 1−λ
(m,k ∈ N with m < k).
Hence (u m ) is Cauchy, as claimed. Solution to Exercise 5.1.5. Let S be complete, let F be a self-map on S, and let F k be a uniform contraction. Let u ∗ be the unique fixed point of F k . Fix ε > 0. We can choose n such that kF nk Fu ∗ − u ∗ k < ε. But then kFu ∗ − u ∗ k = kF F nk u ∗ − u ∗ k = kF nk Fu ∗ − u ∗ k < ε. Since ε was arbitrary, we have kFu ∗ − u ∗ k = 0, implying that u ∗ is a fixed point of F. Regarding convergence, fix u ∈ S. Given n ∈ N, there exist integers j(n) and i(n) such that n = j(n)k + i(n), and j(n) → ∞ as n → ∞. Hence kF n u − u ∗ k = kF j(n)k+i(n) u − u ∗ k = kF j(n)k F i(n) u − u ∗ k → 0
(n → ∞),
by the assumptions on F k . Convergence implies uniqueness of the fixed point (why?).
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
226
Solutions to Selected Exercises
Solution to Exercise 5.1.6. If the risk-free real interest rate r is positive, then $100 received now can be converted with probability one into (1 + r )100 > 100 dollars in one year. Solution to Exercise 5.1.7. Take qk → q, where (qk ) is a sequence of n-vectors contained in U . By Exercise A.2.4 on page 189, since qk > 0 for all k, we must have q > 0. It remains only to show that q(n) = 0. As qk ∈ U for all k, we have qk (n) = 0 for all k. By Lemma 2.3.1, we also have qk (n) → q(n). Hence q(n) = 0. Solution to Exercise 5.1.8. We need to show that if p,q ∈ U and p 6 q, then T p 6 T q. This follows easily from the definition of T in (5.5). Solution to Exercise 5.1.9. Fix q ∈ U , α ∈ R+ , and x ∈ V . By definition, T (q + α1)(x) = min {c(x, y) + βq(y) + αβ} = T q(x) + αβ. y∈𝒪(x)
Hence T (q + α1) = T q + βα1 as claimed. Solution to Exercise 5.1.10. Fix x, y ∈ Rn+ and k ∈ N. By the inequalities in §A.1.1, applied pointwise to vectors, we have |Gx − Gy| = |(Ax + d) ∧ x¯ − (AGy + d) ∧ x| ¯ 6 |Ax + d − (Ay + d)|. This proves the claim because, by Exercise A.2.5, |Ax + d − (Ay + d)| = |A(x − y)| 6 A|x − y|. Solution to Exercise 5.1.11. Since G is a self-map on [a,b], we have Ga ∈ [a,b] and hence a 6 Ga. As G is order-preserving, applying G to this inequality yields Ga 6 G 2 a. Continuing in this way (or using induction) proves that (G k a) is increasing. The proof for (G k b) is similar. If Gx = x for some x ∈ [a,b], then, since a 6 x, we have Ga 6 Gx = x. Iterating on this inequality gives G k a 6 x for all k. Solution to Exercise 5.1.12. Clearly G is a self-map on S := [0, x]. ¯ Since A > 0, we have Gx 6 Gy for all x, y ∈ S. From this it follows easily that G is orderpreserving. Theorem 5.1.5 now guarantees existence of at least one fixed point. Solution to Exercise 5.1.13. By Exercise A.5.8, the minimum of two concave functions is concave. Since F x = x¯ and H x = Ax + b are both concave, the claim holds. Solution to Exercise 5.2.1. In essence, this holds because compositions of continuous functions are continuous. Nonetheless, here is a more explicit proof: Recalling the inequalities in §A.1.1, applied pointwise to vectors, we have, for any p,q ∈ Rn , |T p − T q| 6 |(e + p5) ∧ x) − (e + q5) ∧ x)| 6 |( p − q)5|.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
227
Since, for the Euclidean norm, k|u|k = kuk and u,v > 0 with u 6 v implies kuk 6 kvk, we then have kT p − T qk 6 k( p − q)5k 6 k p − qkk5ko . It follows easily that if k pn − pk → 0, then kT pn − T pk → 0 also holds. Solution to Exercise 5.2.2. Since 5 > 0, we always have p5 6 q5 whenever p 6 q. As a result, p 7→ a − d + p5 is order-preserving and hence so is T . Moreover, for any p ∈ S := [0,x], we have T p ∈ S. Hence, by Theorem 5.1.5, T has a fixed point in S. What else can we say about equilibria in this setting? By the same theorem, T has a least fixed point p ∗ and a greatest fixed point p ∗∗ in S. Moreover, since T is continuous, T k 0 ↑ p ∗ and T k x ↓ p ∗∗ . Solution to Exercise 5.2.3. Fix p,q ∈ S. Using the inequalities for min and max in §A.1.1, applied pointwise, we have |T p − T q| 6 |e + p5 − (e + q5)| = |( p − q)5| 6 | p − q|5. After transposing both sides of this equation, we see that, when r (5) < 1, the conditions of of Proposition 5.1.3 hold. The result follows. (If you prefer, instead of taking transposes, just use the proof of Proposition 5.1.3 directly, modified slightly to use the fact that we are operating on row vectors.) Solution to Exercise 5.2.4. Let 𝒢 = (V , E,w) be a financial network and a directed acyclic graph. By Proposition 5.2.1, it suffices to show that, for each bank i ∈ V , there exists a bank j ∈ V with i → j and such that j has zero inter-bank liabilities. To this end, fix i ∈ V . By the directed acyclic graph property, we know that there exists a j ∈ V with i → j and 𝒪( j) = 0. But if 𝒪( j) = 0, then j has no inter-bank liabilities. The claim follows. Solution to Exercise 5.2.5. Let 𝒢 be a financial network such that (E1) and (E2) hold. Since e 0, we have p∈S
H⇒
T p := ((e + p5) ∧ x) ∨ 0 = (e + p5) ∧ x.
By an argument identical to that employed for Exercise 5.1.13 on page 169, T is a concave operator on S = [0,x]. Evidently T is order-preserving. Finally, by (E1), we have xi > 0 for all i, so x 0 and hence T 0 = e ∧ x 0. It now follows directly from Du’s theorem that T has a unique fixed point in S. Solution to Exercise 5.2.6. Let 𝒢 be such that every node is cash-accessible. Set δ :=
1 · min {{xi : i ∈ V } ∪ {ei : i ∈ V s.t. ei > 0}} . n2
Let eˆ be defined by eˆi = 1 if ei > 0 and zero otherwise. We claim that, for all m 6 n, T m 0 > δ(eˆ + e5 ˆ + · · · + e5 ˆ m−1 ).
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
(5.14)
228
Solutions to Selected Exercises
This holds at m = 1 because T 0 = e ∧ x > δ e. ˆ Now suppose (5.14) holds at some m 6 n − 1. Then, since T is order-preserving, we obtain T m+1 0 > (δ(eˆ + e5 ˆ + · · · + e5 ˆ m−1 )5 + e) ∧ x > (δ(eˆ + e5 ˆ + · · · + e5 ˆ m )) ∧ x. Since eˆ + e5 ˆ + · · · + e5 ˆ m 6 n 2 1, where 1 is a vector of ones, and since (δn 2 1) 6 x by the definition of δ, we have T m+1 0 > δ(eˆ + e5 ˆ + · · · + e5 ˆ m ). This argument confirms that (5.14) holds for all m 6 n. We now claim that T n 0 0. In view of (5.14), it suffices to show that, for any P j ∈ V , there exists a k < n with (e5 ˆ k )( j) = i∈V eˆi 5ikj > 0. Since every node in S is cash-accessible, we know there exists an i ∈ V with ei > 0, and j is accessible from i. For this i we can choose k ∈ N with k < n and 5ikj = eˆi 5ikj > 0. We conclude that T n 0 0, as claimed. Solution to Exercise 5.2.7. Let ψ be a stationary distribution for 5. Suppose λ is a constant in [0,1], p = λψ, and x = ψ. Then e = 0 implies T p = (e + λψ5) ∧ x = (λψ)∧ψ = λψ = p. Since λ was arbitrary in [0,1], there is a continuum of equilibria. Solution to Exercise 5.2.8. The set N is an absorbing set, since, by definition, P is not accessible from N , and A cannot be accessible because otherwise P would also be accessible. The set P is also absorbing because if j ∈ P c is accessible from some i ∈ P, then j is cash-accessible. But then j ∈ P, which is a contradiction. Solution to Exercise 5.2.9. Since C > 0, Lemma 1.2.7, we have r (C) 6 max j colsum j (C). In view of Assumption 5.2.1, this maximum is strictly less than one. Hence r (C) < 1, and, by the Neumann series lemma, I − C is invertible and P (I − C)−1 = k>0 C k . The last equality implies b > 0 when b = (I − C)−1 e. P Solution to Exercise 5.2.10. Consider the condition i∈V ci j 6 1 for all j ∈ V , with strict inequality for at least one j. Since C > 0, this implies that C > is weakly chained substochastic, by Exercise 2.3.22. Hence r (C) = r (C > ) < 1, by Proposition 2.3.5. Hence I − C is invertible, by the Neumann series lemma. Solution to Exercise 5.2.11. We have X bi = 10 b = 10 e + 10 Ce + 10 C 2 e + · · · > 10 e + 10 Ce. i
Hence it suffices to show that 10 Ce > 0. This will be true if at least one column of Ce has a nonzero entry. Since e 0, we require only that ci j > 0 for some i, j, which is true by assumption. Solution to Exercise 5.2.12. Observe that vi 6 vi0 implies f (vi ) > f (vi0 ). As a result, the vector-valued map v 7→ − f (v) is order-preserving, and hence so is T .
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
229
Moreover, for v ∈ [d, v¯ ], we have d = A(e − β1) 6 T v := A(e − f (v)) 6 Ae = v¯, so T is a self-map on [d, v¯ ]. It follows directly from Theorem 5.1.5 that T has a least and greatest fixed point in S. Solution to Exercise 5.2.13. First, vk := T k d is increasing, as just discussed. Second, this sequence can take only finitely many values, since T has finite range. As (vk ) is increasing, it cannot cycle, so it must converge in finitely many steps. Let v0 be this limiting value, and let K be the number of steps required for (vk ) to attain v0 . Since vk = v0 for all k > K , we have T v0 = T T K v0 = T K +1 v0 = v0, so v0 is a fixed point of T in S. Moreover, if v00 is any other fixed point of T in S, then d 6 v00 , and hence, by the order-preserving property, vk = T k d 6 T k v00 = v00 for all k. Hence v0 6 v00 . Thus, v0 is the least fixed point of T . Solution to Exercise A.1.1. Fix a,b ∈ R+ and c ∈ R. By (A.2), we have a ∧ c = (a − b + b) ∧ c 6 (|a − b| + b) ∧ c 6 |a − b| ∧ c + b ∧ c. Thus, a ∧ c − b ∧ c 6 |a − b| ∧ c. Reversing the roles of a and b gives b ∧ c − a ∧ c 6 |a − b| ∧ c. This proves the claim in Exercise A.1.1. Solution to Exercise A.1.2. Suppose first that f is one-to-one. We construct a left inverse g as follows. For y ∈ range( f ), let g(y) be the unique x such that f (x) = y. (Uniqueness is by the one-to-one property.) For y ∈ / range( f ), let g(y) = x, ¯ where x¯ is any point in S. The function g is a left inverse of f because, for any x ∈ S, the point y = f (x) is in range( f ), and g(y) = x. Hence g( f (x)) = x. Suppose next that f has a left inverse g. Suppose further that x and x 0 are points in S with f (x) = f (x 0 ). Then g( f (x)) = g( f (x 0 )). Since g is a left inverse, this yields x = x 0 . Hence f is one-to-one. Solution to Exercise A.1.3. Let G and S be as stated in the exercise. Regarding uniqueness, suppose that G has two distinct fixed points x and y in S. Since G m x = x¯ and G m y = x, ¯ we have G m x = G m y. But x and y are distinct fixed points, so x = G m x must be distinct from y = G m y. Contradiction. Regarding the claim that x¯ is a fixed point, we recall that G k x = x¯ for k > m. Hence G m x¯ = x¯ and G m+1 x¯ = x. ¯ But then G x¯ = GG m x¯ = G m+1 x¯ = x, ¯ so x¯ is a fixed point of G.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
230
Solutions to Selected Exercises
Solution to Exercise A.1.4. In polar form, we have u = r ei ϕ and v = sei ψ , so uv = r s ei(ϕ+ψ) . Hence |uv| = r s (see (A.8)), which is equal to |u||v|. Solution to Exercise A.2.5. Fix B ∈ Mm×k with bi j > 0 for all i, j. Pick any P P i ∈ [m] and x ∈ Rk . By the triangle inequality, we have | j bi j x j | 6 j bi j |x j |. Stacking these inequalities yields |Bx| 6 B|x|, as was to be shown. Solution to Exercise A.3.1. Let xn = −5n+n 2 . Then |xn | 6 5n+n 2 6 6n 2 . Hence (xn ) = O(n 2 ). Regarding the second claim, suppose to the contrary that (xn ) = O(n). Then we can take an M such that |xn | 6 Mn for all n ∈ N. But then xn = −5n +n 2 6 Mn for all n. Dividing by n yields n 6 5 + M for all n. Contradiction. Solution to Exercise A.3.9. If xn → x in Rd and f and g are continuous, then f (xn ) → f (x) and g(xn ) → g(x) in Rk . But then, by Proposition A.3.2, α f (xn ) + βg(xn ) converges to α f (x) + βg(x) in Rk , as was to be shown. Solution to Exercise A.3.10. Here’s the answer for f : Take (xn ) converging to x in Rd . Applying the inequalities in §A.1.1 pointwise to vectors, we have 0 6 | f (xn ) − f (x)| = |xn ∧ a − x ∧ a| 6 |xn − x|. Taking the Euclidean norm over these vectors and using |u| 6 |v| implies kuk 6 kvk yields k f (xn ) − f (x)k 6 kxn − xk → 0. Similar arguments can be applied to g. Solution to Exercise A.4.4. Regarding the first claim, let E = {u 1, . . . ,u k } be linearly independent. Suppose that {u 1, . . . ,u m } is linearly dependent for some m < k. Pm Then we can find a nonzero vector (α1, . . . ,α m ) such that i=1 αi u i = 0. Setting Pk αi = 0 for i in {m + 1, . . . ,k} yields i=1 αi u i = 0, contradicting independence of E. Regarding the second claim, suppose that E ⊂ F and E is linearly dependent. If F is linearly independent, then we have a violation of the first claim. Hence F is linearly dependent. Solution to Exercise A.4.5. Regarding (i), if Ax = Ay = 0, then A(αx + βy) = α Ax + β Ay = 0, so null A is a linear subspace. Regarding (ii), suppose that null A = {0}. This means that the only x ∈ Rk satisfying Ax = 0 is the zero vector, which is equivalent to linear independence of the columns of A. Solution to Exercise A.4.6. For part (i) just set V = Rn in Theorem A.4.4. Regarding part (ii), let A and U be as stated, with |A| =: m > dim U . Suppose to the contrary that A is linearly independent. Then A is a basis for span A, and, therefore, dim span A = m > dim U . At the same time, since A ⊂ U and U is a linear subspace, we have span A ⊂ U . Hence, by Theorem A.4.4, we have m 6 dim U . Contradiction.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
231
Solution to Exercise A.4.8. Here’s a proof by contradiction: Let A be as stated. Suppose to the contrary that A−1 fails to be linear. Then we can find α,β ∈ R and x, y ∈ Rn such that A−1 (αx + βy) and α A−1 x + β A−1 y are distinct points. Since A is a bijection, their images under A are also distinct, so αx + βy 6= A(α A−1 x + β A−1 y). Linearity of A leads to a contradiction. Solution to Exercise A.4.10. Fix u,v ∈ L ⊥ and α,β ∈ R. If z ∈ L, then
αu + βv,z = α hu,zi + β hv,zi = α × 0 + β × 0 = 0. Hence αu + βv ∈ L ⊥ , as was to be shown. Solution to Exercise A.4.13. If O is an orthonormal basis of L, then, by definition, O spans L. In addition, the elements of O are independent because they are orthogonal and nonzero. Solution to Exercise A.5.1. For part (i), let S = {x ∈ Rn+ : 1> x 6 1} be the unit simplex, where 1 is a column vector of ones. Fix u,v ∈ S and λ ∈ [0,1]. We have λu + (1 − λ)v > 0 and 1> (λu + (1 − λ)v) = λ1> u + (1 − λ)1> v 6 λ + (1 − λ) = 1. Hence S is a convex set. For part (ii), fix u,v ∈ B, λ ∈ [0,1] and a ∈ Rn ,ε > 0. We have kλu + (1 − λ)v − ak =kλ(u − a) + (1 − λ)(v − a)k 6 λku − ak + (1 − λ)kv − ak 6 λε + (1 − λ)ε = ε. Hence B is convex. n S Regarding part (iii), let (Si ) be a convex set for i = 1,2, · · · ,n. Fix u,v ∈ ∩i=1 i and λ ∈ [0,1]. We have z = λu + (1 − λ)v ∈ Si
for all i.
n S , and hence ∩n S is convex. This implies z ∈ ∩i=1 i i=1 i
Solution to Exercise A.5.2. Fix u,v ∈ H0 , λ ∈ [0,1], b ∈ R and nonzero c ∈ Rn . Then (λu + (1 − λ)v)> c = λu > c + (1 − λ)v> c = λb + (1 − λ)b = b. Thus H0 is convex. The proof that H1 is convex is similar.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
232
Solutions to Selected Exercises
Solution to Exercise A.5.4. Regarding part (i), let C and D be two cones. Fix x ∈ C ∩ D and α > 0. Since x ∈ C and x ∈ D, and since both are cones, we have αx ∈ C ∩ D. Hence C ∩ D is a cone. Regarding part (ii), suppose first that C is a convex cone, and fix x, y ∈ C. Since C is convex, it must be that (1/2)(x + y) ∈ C. Since C is a cone, we can scale by 2 without leaving C. Hence x + y ∈ C. Suppose next that C is a cone and closed under addition. Fix α ∈ (0,1) and x, y ∈ C. Since C is a cone, we have αx ∈ C and (1 − α)y ∈ C. Since C is closed under addition, it follows that αx + (1 − α)y ∈ C. Hence C is convex. Solution to Exercise A.5.6. Every linear function is both convex and concave. Solution to Exercise A.5.8. It suffices to prove these results in the scalar case n = k = 1, since the vector results are just element-by-element extensions of the scalar case. We focus on the setting where each gi is convex, as the concave case is similar. m and {b }m , we always have In general, for scalars {ai }i=1 i i=1 max{ai + bi } 6 max{ai } + max{bi }. i
i
i
Hence, in the scalar case, when all gi s are convex, we have, for any λ ∈ [0,1] and x, y ∈ C, max{gi (λx + (1 − λ)y)} 6 max{λgi (x) + (1 − λ)gi (y)} 6 λ max gi (x) + (1 − λ) max gi (y). i
i
i
i
This proves the scalar case (and, by extension, the vector case). Solution to Exercise A.6.1. Regarding part (i), let f and g be as stated. Since g is strictly increasing, we have f (x ∗ ) > f (x), ∀ x ∈ D
⇐⇒
g( f (x ∗ )) > g( f (x)), ∀ x ∈ D.
This proves the equivalence claimed in part (i). (Note why the strictly increasing property of g cannot be weakened here.) The proof of (ii) is similar, with the second inequality reversed. Solution to Exercise A.6.2. Let f and C be as described, and let u ∗ be a local minimizer. Suppose, contrary to the claim in the exercise, that there exists a point u in C such that f (u) < f (u ∗ ). Then, by convexity, for each λ in [0,1], we have f (λu + (1 − λ)u ∗ ) 6 λ f (u) + (1 − λ) f (u ∗ ) < f (u ∗ ). Taking λ → 0, we can find a point v := λu + (1 − λ)u ∗ arbitrarily close to u ∗ such that f (v) < f (u ∗ ). This contradicts the definition of a local minimizer.
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
Solutions to Selected Exercises
233
Solution to Exercise A.7.1. Regarding the first claim, suppose that g(x) = 0 and h(x) 6 0, so that x ∈ F(g,h). In this case, X X fˆ(x) = max L(x,θ) = f (x) + max λi gi (x) + max µi h i (x) = f (x). θ∈2
λ∈Rm
µ∈Rk+
i
i
(A.18) Hence fˆ = f on F(g,h), and claim (i) is verified. Regarding claim (ii), suppose that gi (x) deviates from zero for some i. Then P maxλ∈Rm i λi gi (x) equals +∞, so fˆ(x) = +∞. In addition, if h i (x) > 0 for P ˆ some i, then maxµ∈Rk i µi h i (x) = +∞, so, once again f (x) = +∞. We have + confirmed that fˆ = +∞ whenever x ∈ / F(g,h). Solution to Exercise A.7.2. Pick any x 0 ∈ E and θ ∈ 2. We have L(x 0,θ) > minx L(x,θ), so max L(x 0,θ) > max min L(x,θ). θ
∴
θ
x
min max L(x,θ) > max min L(x,θ). x
θ
https://doi.org/10.1017/9781009456340.009 Published online by Cambridge University Press
θ
x
References
Acemoglu, D. and Azar, P. D. (2020). Endogenous production networks. Econometrica, 88(1):33–82. Acemoglu, D., Carvalho, V. M., Ozdaglar, A., and Tahbaz-Salehi, A. (2012). The network origins of aggregate fluctuations. Econometrica, 80(5):1977–2016. Acemoglu, D., Ozdaglar, A., and Pattathil, S. (2023). Learning, diversity and adaptation in changing environments: The role of weak links. Technical report, National Bureau of Economic Research. Acemoglu, D., Ozdaglar, A., and Siderius, J. (2021a). Misinformation: Strategic sharing, homophily, and endogenous echo chambers. Technical report, National Bureau of Economic Research. Acemoglu, D., Ozdaglar, A., Siderius, J., and Tahbaz-Salehi, A. (2021b). Systemic credit freezes in financial lending networks. Mathematics and Financial Economics, 15(1): 185–232. Acemoglu, D., Ozdaglar, A., and Tahbaz-Salehi, A. (2016). Networks, shocks, and systemic risk. In The Oxford Handbook of the Economics of Networks. Oxford University Press. Aggarwal, C. C. (2020). Linear Algebra and Optimization for Machine Learning. Springer. Aliprantis, C. D. and Border, Kim, C. (1999). Infinite Dimensional Analysis: A Hitchhiker’s Guide. Springer-Verlag, 2 edition. Allouch, N. (2015). On the private provision of public goods on networks. Journal of Economic Theory, 157:527–552. Amarasinghe, A., Hodler, R., Raschky, P., and Zenou, Y. (2020). Key players in economic development. Technical report, IZA Discussion Paper. Amini, H. and Minca, A. (2020). Clearing financial networks: Impact on equilibrium asset prices and seniority of claims. Tutorials in Operations Research, pages 154–175. DOI https://doi.org/10.1287/educ.2020.0221. Antràs, P. (2020). Global Production: Firms, Contracts, and Trade Structure. Princeton University Press. Antràs, P., Chor, D., Fally, T., and Hillberry, R. (2012). Measuring the upstreamness of production and trade flows. American Economic Review, 102(3):412–416. Ascenzi, E. and Palanza, F. (2021). How to control electric autonomous taxi fleets in an energy efficient way. Technical report, Chalmers University of Technology. Atalay, E., Hortacsu, A., Roberts, J., and Syverson, C. (2011). Network structure of production. Proceedings of the National Academy of Sciences, 108(13):5199–5202. Axtell, R. L. (2001). Zipf distribution of US firm sizes. Science, 293(5536):1818–1820.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
References
235
Azimzadeh, P. (2019). A fast and stable test to check if a weakly diagonally dominant matrix is a nonsingular m-matrix. Mathematics of Computation, 88(316):783–800. Bala, V. and Goyal, S. (2000). A noncooperative model of network formation. Econometrica, 68(5):1181–1229. Ballester, C., Calvó-Armengol, A., and Zenou, Y. (2006). Who’s who in networks. Wanted: The key player. Econometrica, 74(5):1403–1417. Baqaee, D. R. (2018). Cascading failures in production networks. Econometrica, 86(5): 1819–1838. Barabási, A.-L. and Albert, R. (1999). Emergence of scaling in random networks. science, 286(5439):509–512. Bardoscia, M., Barucca, P., Codd, A. B., and Hill, J. (2019). Forward-looking solvency contagion. Journal of Economic Dynamics and Control, 108:103755. Bardoscia, M., Battiston, S., Caccioli, F., and Caldarelli, G. (2015). Debtrank: A microscopic foundation for shock propagation. PloS one, 10(6):e0130406. Barrot, J.-N. and Sauvagnat, J. (2016). Input specificity and the propagation of idiosyncratic shocks in production networks. The Quarterly Journal of Economics, 131(3):1543–1592. Bartle, R. G. and Sherbert, D. R. (2011). Introduction to Real Analysis. Wiley, 4th edition. Battiston, S., Puliga, M., Kaushik, R., Tasca, P., and Caldarelli, G. (2012). Debtrank: Too central to fail? Financial networks, the Fed and systemic risk. Scientific Reports, 2(1):1–6. Beiglböck, M., Pammer, G., and Schachermayer, W. (2022). From Bachelier to Dupire via optimal transport. Finance and Stochastics, 26(1):59–84. Belhaj, M., Bervoets, S., and Deroïan, F. (2016). Efficient networks in games with local complementarities. Theoretical Economics, 11(1):357–380. Belhaj, M. and Deroïan, F. (2019). Group targeting under networked synergies. Games and Economic Behavior, 118:29–46. Benhabib, J., Bisin, A., and Luo, M. (2019). Wealth distribution and social mobility in the US: A quantitative approach. American Economic Review, 109(5):1623–1647. Benzi, M. and Klymko, C. (2015). On the limiting behavior of parameter-dependent network centrality measures. SIAM Journal on Matrix Analysis and Applications, 36(2):686–706. Bernard, A. B., Dhyne, E., Magerman, G., Manova, K., and Moxnes, A. (2019). The origins of firm heterogeneity: A production network approach. Technical report, National Bureau of Economic Research. Bertsimas, D. and Tsitsiklis, J. N. (1997). Introduction to Linear Optimization. Athena Scientific. Blanchet, A., Carlier, G., and Nenna, L. (2018). Computation of Cournot–Nash equilibria by entropic regularization. Vietnam Journal of Mathematics, 46(1):15–31. Board, S. and Meyer-ter-Vehn, M. (2021). Learning dynamics in social networks. Econometrica, 89(6):2601–2635. Bollobás, B. (1999). Linear Analysis: An Introductory Course. Cambridge University Press. Borgatti, S. P., Everett, M. G., and Johnson, J. C. (2018). Analyzing Social Networks. Sage. Boroviˇcka, J. and Stachurski, J. (2020). Necessary and sufficient conditions for existence and uniqueness of recursive utilities. The Journal of Finance, 75(3):1457–1493. Bramoullé, Y., Galeotti, A., and Rogers, B. W. (2016). The Oxford Handbook of the Economics of Networks. Oxford University Press.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
236
References
Cai, J. and Szeidl, A. (2018). Interfirm relationships and business performance. The Quarterly Journal of Economics, 133(3):1229–1282. Calvó-Armengol, A., Patacchini, E., and Zenou, Y. (2009). Peer effects and social networks in education. The Review of Economic Studies, 76(4):1239–1267. Candogan, O., Bimpikis, K., and Ozdaglar, A. (2012). Optimal pricing in networks with externalities. Operations Research, 60(4):883–905. Carvalho, V. M. (2014). From micro to macro via production networks. Journal of Economic Perspectives, 28(4):23–48. Carvalho, V. M. and Grassi, B. (2019). Large firm dynamics and the business cycle. American Economic Review, 109(4):1375–1425. Carvalho, V. M., Nirei, M., Saito, Y. U., and Tahbaz-Salehi, A. (2021). Supply chain disruptions: Evidence from the great east Japan earthquake. The Quarterly Journal of Economics, 136(2):1255–1321. Carvalho, V. M. and Tahbaz-Salehi, A. (2019). Production networks: A primer. Annual Review of Economics, 11:635–663. Charpentier, A., Galichon, A., and Vernet, L. (2019). Optimal transport on large networks, a practitioner’s guide. arXiv preprint arXiv:1907.02320. Cheney, W. (2013). Analysis for Applied Mathematics, volume 208. Springer Science & Business Media. Chetty, R., Jackson, M. O., Kuchler, T., Stroebel, J., Hendren, N., Fluegge, R. B., Gong, S., Gonzalez, F., Grondin, A., and Jacob, M. (2022). Social capital I: Measurement and associations with economic mobility. Nature, 608(7921):108–121. Chiu, J., Eisenschmidt, J., and Monnet, C. (2020). Relationships in the interbank market. Review of Economic Dynamics, 35:170–191. Çınlar, E. (2011). Probability and Stochastics, volume 261. Springer Science & Business Media. Cochrane, J. H. (1994). Shocks. In Carnegie-Rochester Conference series on public policy, volume 41, pages 295–364. Elsevier. DOI https://doi.org/10.1016/0167-2231(94)00024-7. Cohen, M. X. (2021). Linear Algebra: Theory, Intuition, Code. sincXpress. Cook, W. J. (2011). In Pursuit of the Traveling Salesman. Princeton University Press. Coscia, M. (2021). The atlas for the aspiring network scientist. arXiv preprint arXiv:2101.00863. Dantzig, G. B. (1951). Application of the simplex method to a transportation problem. In T. C. Koopmans (Ed.), Activity Analysis of Production and Allocation, pages 359–373. John Wiley and Sons. Dasaratha, K., Golub, B., and Hak, N. (2022). Learning from neighbors about a changing state. Technical report, Northwestern University. Davey, B. A. and Priestley, H. A. (2002). Introduction to Lattices and Order. Cambridge University Press. De Masi, G., Fujiwara, Y., Gallegati, M., Greenwald, B., and Stiglitz, J. E. (2011). An analysis of the Japanese credit network. Evolutionary and Institutional Economics Review, 7(2): 209 –232. DeGroot, M. H. (1974). Reaching a consensus. Journal of the American Statistical Association, 69(345):118–121. Demange, G. (2017). Optimal targeting strategies in a network under complementarities. Games and Economic Behavior, 105:84–103.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
References
237
Demange, G. (2018). Contagion in financial networks: A threat index. Management Science, 64(2):955–970. Deplano, D., Franceschelli, M., and Giua, A. (2020). A nonlinear Perron–Frobenius approach for stability and consensus of discrete-time multi-agent systems. Automatica, 118:109025. Dew-Becker, I. (2022). Tail risk in production networks. Technical report, Northwestern University. Di Giovanni, J., Levchenko, A. A., and Mejean, I. (2014). Firms, destinations, and aggregate fluctuations. Econometrica, 82(4):1303–1340. Du, Y. (1990). Fixed points of increasing operators in ordered Banach spaces and applications. Applicable Analysis, 38(01–02):1–20. Du, Y., Lehrer, E., and Pauzner, A. (2015). Competitive economy as a ranking device over networks. Games and Economic Behavior, 91:1–13. Dupor, B. (1999). Aggregation and irrelevance in multi-sector models. Journal of Monetary Economics, 43(2):391–409. Durrett, R. (2007). Random Graph Dynamics. Cambridge University Press. Easley, D. and Kleinberg, J., (2010). Networks, Crowds, and Markets, volume 8. Cambridge University Press. Eisenberg, L. and Noe, T. H. (2001). Systemic risk in financial systems. Management Science, 47(2):236–249. Elliott, M. and Golub, B. (2019). A network approach to public goods. Journal of Political Economy, 127(2):730–776. Elliott, M. and Golub, B. (2022). Networks and economic fragility. Annual Review of Economics, 14:665–696. Elliott, M., Golub, B., and Jackson, M. O. (2014). Financial networks and contagion. American Economic Review, 104(10):3115–3153. Elliott, M., Golub, B., and Leduc, M. V. (2022). Supply network formation and fragility. American Economic Review, 112(8):2701–47. Erdös, P. and Rényi, A. (1960). On the evolution of random graphs. Publications of the Mathematical Institute of the Hungarian Academy of Sciences, 5(1):17–60. Fajgelbaum, P. D. and Schaal, E. (2020). Optimal transport networks in spatial equilibrium. Econometrica, 88(4):1411–1452. Flamary, R., Courty, N., Gramfort, A., Alaya, M. Z., Boisbunon, A., Chambon, S., Chapel, L., Corenflos, A., Fatras, K., Fournier, N., Gautheron, L., Gayraud, N. T., Janati, H., Rakotomamonjy, A., Redko, I., Rolet, A., Schutz, A., Seguy, V., Sutherland, D. J., Tavenard, R., Tong, A., and Vayer, T. (2021). Pot: Python optimal transport. Journal of Machine Learning Research, 22(78):1–8. Foss, S., Korshunov, D., and Zachary, S. (2011). An Introduction to Heavy-Tailed and Subexponential Distributions, volume 6. Springer. Gabaix, X. (2011). The granular origins of aggregate fluctuations. Econometrica, 79(3): 733–772. Galeotti, A., Golub, B., and Goyal, S. (2020). Targeting interventions in networks. Econometrica, 88(6):2445–2471. Galeotti, A. and Goyal, S. (2010). The law of the few. American Economic Review, 100(4):1468–1492. Galichon, A. (2018). Optimal Transport Methods in Economics. Princeton University Press.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
238
References
Glynn, P. W. and Desai, P. Y. (2018). A probabilistic proof of the Perron–Frobenious theorem. Technical report, arXiv preprint 1808.04964. Goebel, K. and Kirk, W. A. (1990). Topics in Metric Fixed Point Theory. Cambridge University Press. Golub, B. and Jackson, M. O. (2010). Naive learning in social networks and the wisdom of crowds. American Economic Journal: Microeconomics, 2(1):112–149. Goyal, S. (2023). Networks: An Economics Approach. MIT Press. Graham, B. S. (2017). An econometric model of network formation with degree heterogeneity. Econometrica, 85(4):1033–1063. Greinecker, M. and Kah, C. (2021). Pairwise stable matching in large economies. Econometrica, 89(6):2929–2974. Guo, D., Cho, Y. J., and Zhu, J. (2004). Partial Ordering Methods in Nonlinear Platforms. Nova Publishers. Häggström, O. (2002). Finite Markov Chains and Algorithmic Applications. Cambridge University Press. Herskovic, B. (2018). Networks in production: Asset pricing implications. The Journal of Finance, 73(4):1785–1818. Hojman, D. A. and Szeidl, A. (2008). Core and periphery in networks. Journal of Economic Theory, 139(1):295–309. Holme, P. (2019). Rare and everywhere: Perspectives on scale-free networks. Nature Communications, 10(1):1–3. Huang, W.-Q., Zhuang, X.-T., Yao, S., and Uryasev, S. (2016). A financial network perspective of financial institutions’ systemic risk contributions. Physica A: Statistical Mechanics and Its Applications, 456:183–196. Jackson, M. O. (2010). Social and Economic Networks. Princeton University Press. Jackson, M. O. (2014). Networks in the understanding of economic behaviors. Journal of Economic Perspectives, 28(4):3–22. Jackson, M. O. and Pernoud, A. (2019). Investment incentives and regulation in financial networks. Technical report, SSRN 3311839. Jackson, M. O. and Pernoud, A. (2020). Credit freezes, equilibrium multiplicity, and optimal bailouts in financial networks. Technical report, arxiv 2012.12861. Jackson, M. O. and Pernoud, A. (2021). Systemic risk in financial networks: A survey. Annual Review of Economics, 13:171–202. Jackson, M. O. and Wolinsky, A. (1996). A strategic model of social and economic networks. Journal of Economic Theory, 71(1):44–74. Jänich, K. (1994). Linear Algebra. In Undergraduate Texts in Mathematics. Springer-Verlag. Kakutani, S. (1941). A generalization of Brouwer’s fixed point theorem. Duke Mathematical Journal, 8(3):457–459. Katz, L. (1953). A new status index derived from sociometric analysis. Psychometrika, 18(1):39–43. Kepner, J. and Gilbert, J. (2011). Graph Algorithms in the Language of Linear Algebra. SIAM. Kikuchi, T., Nishimura, K., Stachurski, J., and Zhang, J. (2021). Coase meets bellman: Dynamic programming for production networks. Journal of Economic Theory, 196:105287. Kim, K., Kim, S. Y., and Ha, D.-H. (2007). Characteristics of networks in financial markets. Computer Physics Communications, 177(1–2):184–185.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
References
239
Klages-Mundt, A. and Minca, A. (2021). Optimal intervention in economic networks using influence maximization methods. European Journal of Operational Research, 300(3): 1136–1148. Kolouri, S., Park, S. R., Thorpe, M., Slepcev, D., and Rohde, G. K. (2017). Optimal mass transport: Signal processing and machine-learning applications. IEEE Signal Processing Magazine, 34(4):43–59. Kondo, I. O., Lewis, L. T., and Stella, A. (2020). Heavy tailed, but not zipf: Firm and establishment size in the US. Technical report, Federal Reserve Bank of Minneapolis. Krasnoselskii, M. (1964). Positive Solutions of Operator Equations. Noordhoff. Kreyszig, E. (1978). Introductory Functional Analysis with Applications, volume 1. Wiley. Kumamoto, S.-I. and Kamihigashi, T. (2018). Power laws in stochastic processes for social phenomena: An introductory review. Frontiers in Physics, 6:20. La’O, J. and Tahbaz-Salehi, A. (2022). Optimal monetary policy in production networks. Econometrica, 90(3):1295–1336. Leontief, W. W. (1941). The Structure of American Economy, 1919–1929. Harvard University Press. Liu, E. (2019). Industrial policies in production networks. The Quarterly Journal of Economics, 134(4):1883–1948. Liu, E. and Tsyvinski, A. (2020). Dynamical structure and spectral properties of input–output networks. Technical report, National Bureau of Economic Research. Ljungqvist, L. and Sargent, T. J. (2018). Recursive Macroeconomic Theory. MIT press, 4th edition. Lucas, R. and Stokey, N. (1989). Recursive Methods in Dynamic Economics. Harvard University Press. Marinacci, M. and Montrucchio, L. (2019). Unique Tarski fixed points. Mathematics of Operations Research, 44(4):1174–1191. Martin, T. and Otto, C. A. (2020). The downstream impact of upstream tariffs: Evidence from investment decisions in supply chains. Technical report, SSRN 2872662. Matousek, J. and Gärtner, B. (2007). Understanding and Using Linear Programming. Springer Science & Business Media. Menczer, F., Fortunato, S., and Davis, C. A. (2020). A First Course in Network Science. Cambridge University Press. Meyer, C. D. (2000). Matrix Analysis and Applied Linear Algebra, volume 71. SIAM. Meyer-Nieberg, P. (2012). Banach Lattices. Springer Science & Business Media. Meyn, S. P. and Tweedie, R. L. (2009). Markov Chains and Stochastic Stability. Cambridge University Press. Miller, R. E. and Blair, P. D. (2009). Input-Output Analysis: Foundations and Extensions. Cambridge University Press. Miranda-Pinto, J. (2021). Production network structure, service share, and aggregate volatility. Review of Economic Dynamics, 39:146–173. Molavi, P., Tahbaz-Salehi, A., and Jadbabaie, A. (2018). A theory of non-Bayesian social learning. Econometrica, 86(2):445–490. Nair, J., Wierman, A., and Zwart, B. (2021). The Fundamentals of Heavy Tails: Properties, Emergence, and Estimation. Preprint, California Institute of Technology.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
240
References
Nash, J. F. (1950). Equilibrium points in n-person games. Proceedings of the National Academy of Sciences, 36(1):48–49. Newman, M. E. (2005). Power laws, Pareto distributions and Zipf’s law. Contemporary Physics, 46(5):323–351. Newman, M. E. (2018). Networks. Oxford University Press. Nikaido, H. (1968). Convex Structures and Economic Theory. Academic Press. Norris, J. R. (1998). Markov Chains. Cambridge University Press. Ocampo, S. (2022). A task-based theory of occupations with multidimensional heterogeneity. Technical report, Western University. Olabisi, M. (2020). Input–output linkages and sectoral volatility. Economica, 87(347):713–746. Ou, Q., Jin, Y.-D., Zhou, T., Wang, B.-H., and Yin, B.-Q. (2007). Power-law strength-degree correlation from resource-allocation dynamics on weighted networks. Physical Review E, 75(2):021102. Pearce, R. (2017). Triangle counting for scale-free graphs at scale in distributed memory. In 2017 IEEE High Performance Extreme Computing Conference (HPEC), Sept. 2017, Waltham, MA USA. Pages 1–4. IEEE. Peyré, G. and Cuturi, M. (2019). Computational optimal transport: With applications to data R in Machine Learning, 11(5-6):355–607. science. Foundations and Trends Polovnikov, K., Pospelov, N., and Skougarevskiy, D. (2022). Ownership concentration and wealth inequality in Russia. In Proceedings of the 31st International Joint Conference on Artificial Intelligence, July 2022, Vienna. Pages 5136–5142. Privault, N. (2013). Understanding Markov Chains. Examples and Applications. SpringerVerlag Singapore, 357–358. Punel, A. and Ermagun, A. (2018). Using twitter network to detect market segments in the airline industry. Journal of Air Transport Management, 73:67–76. Quah, D. (1993). Empirical cross-section dynamics in economic growth. European Economic Review, 37(2-3.):426–434. Rybski, D., Buldyrev, S. V., Havlin, S., Liljeros, F., and Makse, H. A. (2009). Scaling laws of human interaction activity. Proceedings of the National Academy of Sciences, 106(31):12640–12645. Schauder, J. (1930). Der Fixpunktsatz in Funktionalräumen. Studia Math, 2:71–80. Schrijver, A. (2005). On the history of combinatorial optimization (till 1960). Handbooks in Operations Research and Management Science, 12:1–68. Seneta, E. (2006a). Markov and the creation of Markov chains. In Markov Anniversary Meeting, pages 1–20. Citeseer. Seneta, E. (2006b). Non-Negative Matrices and Markov Chains. Springer Science & Business Media. Sharkey, K. J. (2017). A control analysis perspective on Katz centrality. Scientific reports, 7(1):1–8. Shiller, R. J. (2020). Narrative Economics: How Stories Go Viral and Drive Major Economic Events. Princeton University Press. Shin, H. S. (2010). Risk and Liquidity. Oxford University Press. Simon, C. P. (1994). Mathematics for Economists. Norton & Company, Inc.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
References
241
Simonetto, A., Monteil, J., and Gambella, C. (2019). Real-time city-scale ridesharing via linear assignment problems. Transportation Research Part C: Emerging Technologies, 101: 208–232. Stachurski, J. (2016). A Primer in Econometric Theory. MIT Press. Stachurski, J. (2022a). Economic Dynamics: Theory and Computation. MIT Press, 2nd edition. Stachurski, J. (2022b). Systemic risk in financial systems: Properties of equilibria. arXiv preprint. arXiv:2202.11183. Vershik, A. M. (2013). Long history of the Monge–Kantorovich transportation problem. The Mathematical Intelligencer, 35(4):1–9. Villani, C. (2008). Optimal Transport: Old and New, volume 338. Springer Science & Business Media. Watts, A. (2001). A dynamic model of network formation. Games and Economic Behavior, 34(2):331–341. Yun, T.-S., Jeong, D., and Park, S. (2019). “Too central to fail” systemic risk measure using Pagerank algorithm. Journal of Economic Behavior & Organization, 162:251–272. Zenou, Y. (2016). Key Players. Oxford Handbook on the Economics of Networks, pages 244–274. Zhang, Z. (2012). Variational, Topological, and Partial Order Methods with Their Applications, volume 29. Springer.
https://doi.org/10.1017/9781009456340.010 Published online by Cambridge University Press
Index
P-Markov, 133 ε-ball, 192 absorbing, 27 accessible, 27 adjacency matrix, 33 aperiodic, 29 basis, 197 Bellman equation, 91 Bellman operator, 94 big O notation, 190 bijection, 181 book value, 175 bounded, 193 sequence, 191 canonical basis vectors, 196 Cartesian product, 180 Cauchy sequence, 192 cdf, 19 Chapman–Kolmogorov equation, 135 characteristic polynomial, 6 closed set, 193 codomain, 181 column space, 195 communication (graphs), 27 compact, 193 competitive equilibrium, 121 complementary slackness, 106, 211 complex numbers, 186 composition, 184 concave function, 205 cone, 204 consensus, 157 contracting, 161 convergence, 191, 192 convergence of matrices, 82 convergence of vectors, 79 convex cone, 204 convex function, 204 convex set, 203
https://doi.org/10.1017/9781009456340.011 Published online by Cambridge University Press
countable, 184 counter CDF (CCDF), 19 coupling, 111 cumulative distribution function, 19 cycle, 28 decreasing, 189 degree distribution, 45 DeGroot learning, 155 determinant, 201 diagonalizable, 7 digraph, 24 direct predecessor, 25 direct successor, 25 directed acyclic graph, 28 directed graph, 24 directed path, 27 directed walk, 27 distributions, 15 domain, 181 domar weight, 70 dominant eigenvector, 13 dual, 209 dual problem, 105 edges, 24 eigendecomposition, 7 eigenpair, 5 eigenspace, 6 eigenvalue, 5 eigenvector, 5 eigenvector centrality, 41, 43 epigraph, 205 equivalence, 79, 82 equivalence relation, 181 ergodic, 143 Euler’s formula, 187 eventually contracting, 162 extreme point, 107, 204 fixed point, 160, 185 flow network, 92
Index
Frobenius inner product, 81 Frobenius norm, 81 function, 181 real-valued, 183 Gelfand’s formula, 83 globally stable, 147 halfspace, 203 harmonic, 143 head of an edge, 25 heavy-tailed, 19 Herfindahl index, 72, 75 hub centrality, 39 hyperplane, 203 imaginary, 186 in-degree, 25 in-degree centrality, 39 incidence matrix, 124 increasing, 189 increasing function, 190 indicator, 183 initial condition, 133 inner product, 186 Frobenius, 112 interior, 193 inverse, 200 invertible, 200 irreducible, 12 Jensen’s inequality, 205 Kantorovich duality, 118 Karush–Kuhn–Tucker, 211 Katz centrality, 44, 45 kernel, 196 Kronecker product, 113 Lagrange multiplier, 209 Lagrangian, 209 law of large numbers, 145 law of total probability, 16 length (directed walk), 27 Leontief inverse, 58, 69 light-tailed, 19 linear, 198 linear combination, 194 linear hyperplane, 199 linearly independent, 196 local maximizer, 207 local minimizer, 207 lognormal distribution, 20 marginal distribution, 136 Markov chain, 133 Markov model, 129
https://doi.org/10.1017/9781009456340.011 Published online by Cambridge University Press
Markov–Dobrushin coefficient, 151 Martingale, 143 matrix norm, 80 maximizer, 206 maximum, 206 minimizer, 206 minimum, 206 minimum cost-to-go, 91 Minkowski’s inequaltiy, 79 modulus, 186 moment, 20 moment generating function, 19 Monge map, 109 monotone sequence, 191 Nash equilibrium, 35 negative definite, 206 negative semidefinite, 206 Neumann series lemma, 11 nodes, 24 nonreal, 186 nonsingular, 200 norm, 78 normal distribution, 19 normal vector, 199 NSL, 11 null space, 196 one-to-one function, 181 onto function, 181 open set, 193 operator norm, 81 optimal plan, 112 optimal policy, 94 order-preserving, 189 orthogonal, 201 orthogonal complement, 201 orthogonal set, 202 orthogonally diagonalizable, 8 orthonormal matrix, 202 set, 202 orthonormal basis, 202 out-degree, 25 out-degree centrality, 39 output multiplier, 64 Pareto distribution, 21 Pareto tail, 21 partial order, 188 partially ordered set, 188 periodic digraph, 28 Perron projection, 14
243
244
Index
Perron root, 13 pointwise convergence, 80 pointwise order, 188, 189 pointwise partial order, 13 polar form, 187 policy function, 93 positive cone, 204 positive definite, 206 positive semidefinite, 206 power law, 21 power set, 180 preferential attachment, 49 primal, 209 primitive matrix, 12 Pythagorean law, 202 range, 181 rank, 197 real numbers, 180 real part, 186 reflexivity, 181 relation, 181 saddle point, 210 scale-free network, 46 scale-free networks, 45 self-map, 160, 185 sequence, 190 series, 191 shortest path, 89 similar matrix, 10 simple eigenvalue, 6 sink, 25 slack variables, 104 source, 25 span, 194 spectral gap, 149
https://doi.org/10.1017/9781009456340.011 Published online by Cambridge University Press
spectral radius, 11 spectrum, 5 standard form, 104, 112 state space, 129 stationary, 138 stationary distribution, 18, 138 stochastic matrix, 18 strictly decreasing, 190 strictly increasing, 190 strong duality, 106, 209 strongly connected, 27 submultiplicative norm, 80 subsequence, 190 subspace, 194 substochastic matrix, 85 supremum norm, 79 symmetry, 181 t-distribution, 19 tail index, 21 tail of an edge, 25 transition matrix, 130 transitivity, 181 transport plan, 111 triangle inequality, 181 trust matrix, 155 uncountable, 184 unit simplex, 16 value added, 57 vertices, 24 weak duality, 105, 209 weight function, 32 weighted digraph, 32 zeta distribution, 23