{\rtf1\ansi\ansicpg1252\cocoartf1504\cocoasubrtf830
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
{\*\expandedcolortbl;;}
\paperw11900\paperh16840\margl1440\margr1440\vieww10800\viewh8400\viewkind0
\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural\partightenfactor0
\f0\fs24 \cf0 % This script decomposes TIMs by INDUSTRY and by PRODUCTS
\
% in an asymmetric SUT system (m industries and n products)
\
% It accompanies the note "On the Decomposition of Total Impact Multipliers in a Supply-and-Use Framework"
\
% in the Journal of Economic Structures
\
% Thomas Wiedmann, 2017
\
\
clear
\
clc
\
\
\
%% Load data
\
\
% 6 industries first, then 10 products
\
% Note: see also supplementary data file of the article
\
\
m = 6 ;
\
n = 10 ;
\
\
% Transaction matrix:
\
T = [
\
0 0 0 0 0 0 320 205 30 0 0 0 0 0 0 0
\
0 0 0 0 0 0 0 0 310 400 200 0 0 0 0 0
\
0 0 0 0 0 0 0 0 0 10 330 490 100 0 0 0
\
0 0 0 0 0 0 0 0 0 0 0 0 400 700 0 0
\
0 0 0 0 0 0 0 0 0 0 0 0 0 0 1800 0
\
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1700
\
20 30 40 35 55 20 0 0 0 0 0 0 0 0 0 0
\
0 25 10 35 25 30 0 0 0 0 0 0 0 0 0 0
\
100 10 10 10 50 50 0 0 0 0 0 0 0 0 0 0
\
10 200 20 0 20 20 0 0 0 0 0 0 0 0 0 0
\
50 20 200 0 40 40 0 0 0 0 0 0 0 0 0 0
\
0 20 0 310 50 0 0 0 0 0 0 0 0 0 0 0
\
10 5 30 10 200 100 0 0 0 0 0 0 0 0 0 0
\
0 25 20 20 200 200 0 0 0 0 0 0 0 0 0 0
\
10 25 10 5 300 500 0 0 0 0 0 0 0 0 0 0
\
80 5 5 0 50 400 0 0 0 0 0 0 0 0 0 0
\
] ;
\
\
% Value added:
\
VA = [275 545 585 675 810 340 0 0 0 0 0 0 0 0 0 0] ;
\
\
% Extensions, e.g. emissions
\
F = [100 300 300 100 1000 1700 0 0 0 0 0 0 0 0 0 0] ;
\
\
\
%% Calculate DIMs and TIMs
\
% DIM = Direct Impact Multiplier
\
% TIM = Total Impact Multiplier
\
\
TotalIn = sum(T) + VA ; % total inputs
\
DIMs = F ./ TotalIn ; % DIMs, can also be noted as f
\
A = T * diag(1./TotalIn) ; % A-matrix; technical coefficient matrix
\
L = inv(eye(size(A))-A) ; % Leontief Inverse
\
TIMs = DIMs * L ;
\
\
\
%% Decomposition of TIMs by INDUSTRY
\
\
% This answers the question: What are the emissions originating from
\
% INDUSTRIES involved in the TIM of a product (i.e. the direct emissions
\
% from industries involved in any supply chain in the production of the
\
% product; e.g. emissions for all electricity use in ANY supply
\
% path).
\
\
TIMs_decomp_IND = diag(DIMs) * L ;
\
\
\
%% Decomposition of TIMs by PRODUCTS
\
\
% This answers the question: What are the life-cycle emissions of PRODUCTS
\
% directly used in the production of a product (i.e. the indirect
\
% emissions embodied in products that act as inputs to the industry that
\
% produces the product, e.g. life-cycle emissions in the steel used for
\
% wind turbines).
\
\
TIMs_decomp_PROD_interim = diag(DIMs) + diag(TIMs) * A ;
\
\
\
%% Convert Product TIMs
\
\
% Since the result of the TIM decomposition is in SUT format, the
\
% "by industry" product TIMs need to be converted into "by product" product
\
% TIMs as follows.
\
\
% Let a(1:m,p) be the first m rows of column p in the A matrix derived from
\
% the SUT (which has the dimensions (m+n) x (m+n)). Transposing this column
\
% (into one row with m values) and row-wise multiplying it with the
\
% industry TIM columns from the previous step, results in new columns of
\
% industry TIMs that are scaled according to the contribution of all
\
% industries to the production of product p.
\
\
% Memo: m = number of industries (6 in this example)
\
% Memo: n = number of products (10 in this example)
\
\
TIMs_decomp_PROD_by_PROD = zeros((m+n),n) ; % the final decomposition shows contributions from industries and products to n product TIMs
\
\
for p = 1:n ; % number of products
\
\
B = transpose(A(1:m,m+p)) ; % First, choose correct column in A matrix and transpose. Only the industry-by-product part of A is needed.
\
\
ScaledIndTIMs = TIMs_decomp_PROD_interim(:,1:m) .* repmat(B,m+n,1) ; % Second, scale (multiply) industry columns in TIM decomp table
\
\
TIMs_decomp_PROD_by_PROD(:,p) = ScaledIndTIMs * ones(m,1) ; % Third, sum all industry columns horizontally to produce TIM decomposition of product p
\
\
% Alternative: TIMs_decomp_PROD_by_PROD(:,p) = sum(ScaledIndTIMs,2) ;
\
\
end
\
\
disp ([' ']);
\
disp (['Ascertain that the total TIM is the same as that of the product:']);
\
sum(TIMs_decomp_PROD_by_PROD)
\
sum(TIMs_decomp_PROD_interim(:,m+1:m+n))
\
\
disp ([' ']);
\
disp (['See full results in Workspace']);
\
\
\
\
\
\
}