<<

ECON2285: Mathematical

Yulei Luo

SEF of HKU

September 1, 2017

Luo, Y. (SEF of HKU) ME September1,2017 1/35 Course Outline

Economics: The study of the choices people (, …rm managers, and governments) make to attain their goals, given their scarce resources. : Simpli…ed version of reality used to analyze real-world economic situations. This course will mainly focus on how to use mathematical methods to solve economic models. After solving the models, you may use to test the hypothesis derived from models. If you are interested in testing economic models, you may take Econ0701: .

Luo, Y. (SEF of HKU) ME September1,2017 2/35 Course Outline

Static Analysis Main objective: characterize partial and general equilibrium: = and solve for equilibrium and quantities. Mathematical tools: matrix algebra Economic applications: equilibrium models and national- models Comparative-Static Analysis Main objective: compare di¤erent equilibrium states that are associated with di¤erent sets of values of parameters or exogenous variables (i.e., they are given and not determined by the model structure). Mathematical tools: calculus (di¤erentiation, partial di¤erentiation, etc.) Economic applications: market equilibrium models and national-income models

Luo, Y. (SEF of HKU) ME September1,2017 3/35 (Continued.) Static Optimization Analysis Main objective: characterize the optimizing behavior of consumers and …rms behind equilibrium at one period (static, atemporally). Mathematical tools: unconstrained and constrained static optimization Economic applications: maximization, pro…t maximization, and cost minimization. Dynamic Analysis Main objective: characterize the evolution of economic variables over time (dynamic, intertemporally). Mathematical tools: …rst-order and higher-order di¤erence (discrete-time) or di¤erential (continuous-time) equations. Economic applications: models, cobweb model, etc. Dynamic Optimization Main objective: characterize the optimal behavior of agents over time. Mathematical tools: optimal control theory (the Lagrange multiplier method) or dynamic programming (The Bellman equation method) Economic applications: optimal economic growth models, life-cycle optimal consumption-saving models, optimal investment models.

Luo, Y. (SEF of HKU) ME September1,2017 4/35 The meaning of equilibrium

In essence, an equilibrium for a speci…c model is a situation that is characterized by a lack of tendency to change. It is for this reason that the analysis of equilibrium is referred to as statics. We will discuss two examples of equilibrium. One is the equilibrium attained by a market under given demand and supply conditions. The other is the equilibrium of national income under given conditions of total consumption and investment patterns.

Luo, Y. (SEF of HKU) ME September1,2017 5/35 Partial equilibrium model (linear)

In a static equilibrium model, the standard problem is to …nd the set of values of the endogenous variables (i.e., they are not given and are determined by the model structure) which will satisfy the equilibrium conditions of the model. Partial equilibrium market model: a model of determination in a single market. Three variables:

Qd = the quantity demanded of the commodity Qs = the quantity supplied of the commodity P = the price of commodity. And the equilibrium condition is

Qd = Qs . (1) The model setup is then

Qd = Qs (2) Q = a bP (3) d Qs = c + dP (4) where a, b, c, and d are all positive. Luo, Y. (SEF of HKU) ME September1,2017 6/35 One way to …nd the equilibrium is by successive elimination of variables and equations through substitution. From Qd = Qs , we have

a bP = c + dP. (5) Since b + d = 0, the equilibrium price is then 6 a + c P = , (6)  b + d and the equilibrium quantity can be obtained by substituting P into either Qd or Qs : ad bc Q = , (7)  b + d where we assume that ad bc > 0 to make the model economically meaningful.

Luo, Y. (SEF of HKU) ME September1,2017 7/35 Partial equilibrium model (Nonlinear)

The partial equilibrium market model can be nonlinear. The model setup is then

Qd = Qs (8) Q = 4 P2 (9) d Qs = 1 + 4P (10) As before, the three-equation system can be reduced to a single equation by substitution: P2 + 4P 5 = 0, (11) which can be solved by applying the quadratic formula:

P = 1 or 5. (12) Note that only the …rst root is economically meaningful.

Luo, Y. (SEF of HKU) ME September1,2017 8/35 General market equilibrium

In the above, we only consider a single market. In the real world, there would normally exist many . Thus, a more realistic model for the demand and supply functions of a commodity should take into account the e¤ects not only of the price of the commodity itself but also of the prices of other commodities. As a result, the price and quantity variables of multiple commodities must enter endogenously into the model. Consequently, the equilibrium condition of an n commodity market model will involve n equations, one for each commodity, in the form E = Q Q = 0, (13) i i,d i,s where i = 1, , n,    Q = Q (P1, , Pn) and Q = Q (P1, , Pn) (14) i,d i,d    i,s i,s    are the demand and supply functions of commodity i. Thus solving n equation system for P : E (P1, , Pn) = 0 (15) i    if a solution does exist.

Luo, Y. (SEF of HKU) ME September1,2017 9/35 Two commodity market model

The model setup is as follows

Q1,d = Q1,s (16) Q1,d = a0 + a1P1 + a2P2 (17) Q1,s = b0 + b1P1 + b2P2 (18) Q2,d = Q2,s (19) Q2,d = α0 + α1P1 + α2P2 (20)

Q2,s = β0 + β1P1 + β2P2, (21) which implies that

(a0 b0) + (a1 b1) P1 + (a2 b2) P2 = 0 (22) (α0 β ) + (α1 β ) P1 + (α2 β ) P2 = 0 (23) 0 1 2

Luo, Y. (SEF of HKU) ME September1,2017 10/35 (Continued.) Denote that

c = a b ; d = α β , (24) i i i i i i where i = 0, 1, 2. The above linear equations can be written as

c1P1 + c2P2 = c0 (25) d1P1 + d2P2 = d0, (26) which can be solved by further elimination of variables:

c2d0 c0d2 c0d1 c1d0 P1 = ; P2 = . (27) c1d2 c2d1 c1d2 c2d1 Note that for the n commodity linear market model, we have n linear equations and n unknowns. However, an equal number of equations and unknowns doesn’tnecessarily guarantee the existence of a unique solution. Only when the number of unknowns equals to the number of functional independent equations, the solution exists and is unique. We thus need systematic methods to test the existence of a unique solution.

Luo, Y. (SEF of HKU) ME September1,2017 11/35 Equilibrium national-income model

Consider a simple Keynesian national-income model,

Y = C + I0 + G0 (Equilibrium condition) (28) C = a + bY (The consumption function), (29)

where Y and C stand for the endogenous variables national income and consumption expenditure, respectively, and I0 and G0 are the exogenously determined investment and government spending. Following the same procedure, the equilibrium income and consumption can solved as follows a + I + G Y = 0 0 (30)  1 b a + b(I + G ) C = 0 0 . (31)  1 b

Luo, Y. (SEF of HKU) ME September1,2017 12/35 Why matrix algebra?

As more and more commodities are incorporated into the model, it becomes more and more di¢ cult to solve the model by substitution. A method suitable for handling a large system of simultaneous equations is matrix algebra. Matrix algebra provides a compact way of writing an equation system; it leads to a way to test the existence of a solution by evaluation of a determinant – a concept closely related to that of a matrix; it also gives a method to …nd that solution if it exists.

Luo, Y. (SEF of HKU) ME September1,2017 13/35 Quick review of matrix algebra

Matrix: a matrix is simply a rectangular array of numbers. So any table of data is a matrix.

1 The size of a matrix is indicated by the number of its rows and the number of its columns. A matrix A with k rows and n columns is called a k n matrix.  The number in row i and column j is called the (i, j) entry and is written as aij . 2 Two matrices are equal if they both have the same size and if the corresponding entries in the two matrices are equal. 3 If a matrix contains only one column (row), it is called a column (row) vector. a a a Example: 11 12 is a 2 2 matrix. 1 is a 2 1 matrix or a a21 a22  a2  column vector.   

Luo, Y. (SEF of HKU) ME September1,2017 14/35 (Continued.) Addition: One can add two matrices with the same size. E.g., a a 1 0 a + 1 a 11 12 + = 11 12 . a21 a22 0 1 a12 a22 + 1       Subtraction: subtract matrices of the same size simply by subtracting their corresponding entries. E.g., a11 a12 1 0 a11 1 a12 = . a21 a22 0 1 a12 a22 1       Scalar multiplication: matrices can be multiplied by ordinary numbers a a αa αa (scalar). E.g., α 11 12 = 11 12 . a12 a22 αa12 αa22    

Luo, Y. (SEF of HKU) ME September1,2017 15/35 (Continued.) Matrix multiplication: Not all pairs of matrices can be multiplied together, and the order in which matrices are multiplied can matter. We can de…ne the matrix product AB if and only if

Number of columns of A = Number of rows of B. (32)

For the matrix product to exist, A must be k m and B must be m n. To obtain the (i, j) entry of AB, multiply the ith row of A and the jth column of B. If A is k m and B is m n, then the product AB is k n. That is, the product matrix AB inherits the number of its rows from A and the number of its columns from B. E.g.,

a1 2 2 a1 a2 = a1 + a2. (33) a2   a a  α α a + α a 11 12 1 = 1 11 2 12 (34) a12 a22 α2 α1a12 + α2a22      

Luo, Y. (SEF of HKU) ME September1,2017 16/35 (Continued.) Linear dependence of vectors. A set of vectors v1, , vn is said to be linearly dependent if and only if any one of them can be expressed   as a linear combination of the remaining vectors; otherwise, they are linearly independent.

For any vectors v1, , vn to be linear independent, for any set of scalars ki , n    ∑i=1 ki vi = 0 if and only if ki = 0 for all i. Example: the three vectors

2 1 4 v = , v = , v = (35) 1 7 2 8 3 5       are linearly dependent since v3 is a linear combination of v1 and v2:

3v1 2v2 = v3 (36)

Luo, Y. (SEF of HKU) ME September1,2017 17/35 (Continued.) Laws of matrix algebra (think of matrices as generalized numbers) Associative laws:

(A + B) + C = A + (B + C ) (37) (AB)C = A(BC ) (38)

Communication law for addition

A + B = B + A (39)

Distributive laws A(B + C ) = AB + AC (40) Note that Communication law for multiplication does NOT hold:

AB = BA ingeneral. (41) 6

Luo, Y. (SEF of HKU) ME September1,2017 18/35 (Continued.) Transpose: the transpose of a k m matrix A is the m k matrix obtained by interchanging the rows and columns of A. It is also written as AT . E.g., T a1 a1 a2 = (42) a2   Square matrix: a matrix with the same numbers of rows and columns. E.g., a a 11 12 . a21 a22   Determinant of a square matrix: For 1 1 matrix a, det(a) = a.For 2 2 a a   matrix A = 11 12 , a21 a22  

det(A) = A = a11a22 a12a21 (43) j j which is just the product of two diagonal entries minus the product of two o¤-diagonal entries.

Luo, Y. (SEF of HKU) ME September1,2017 19/35 (Continued.) Inverse: Let A be a square matrix. The matrix B is an inverse 1 0 for A if AB = BA = I where I = is called identity matrix (a square 0 1 matrix with ones in its principal diagonal and zeros everywhere else).If the 1 matrix B exists, we say that A is invertible and denote B = A . Squareness is a necessary but not su¢ cient condition for the existence of an inverse. If a square matrix A has an inverse, A is said to be nonsingular. If A has no inverse, it is said to be a singular matrix.

Luo, Y. (SEF of HKU) ME September1,2017 20/35 Some properties of the transpose and the inverse

The operation of matrix transpose and matrix inverse satisfy

(AB)0 = B0A0 (44) (A0)0 = A (45) A0A = 0 A = A0 = 0 (46) () (A + B)0 = A0 + B0 (47) 1 1 (A )0 = (A0) (48) 1 1 (A ) = A (49) 1 1 1 (AB) = B A (50)

provided that the objects above are well de…ned.

Luo, Y. (SEF of HKU) ME September1,2017 21/35 (Continued.) System of equations in matrix form: Consider the following two-equation (two unknown variables) system

a11x1 + a12x2 = b1 (51) a21x1 + a22x2 = b2 (52)

a a x Let A = 11 12 be the coe¢ cient matrix of the system, x = 1 , a21 a22 x2     b and b = 1 . The above equations can be written in a compact form: b2   a a x b 11 12 1 = 1 or Ax = b. (53) a21 a22 x2 b2       The solution to the above equations can be written as

1 x =A b, (54)

1 if A exists.

Luo, Y. (SEF of HKU) ME September1,2017 22/35 Test for the existence of the inverse and …nd the inverse

The necessary and su¢ cient conditions for nonsingularity are that the matrix satis…es the squareness and linear independence conditions (that is, its rows or equivalently, its columns are linearly independent.). An n n nonsingular matrix A has n linearly independent rows (or columns); consequently, it must have rank n. Consequently, an n n matrix having rank n must be nonsingular.  The concept of determinant can be used to not only determine whether a square matrix is nonsingular, but also calculate the inverse of the matrix.

Luo, Y. (SEF of HKU) ME September1,2017 23/35 (Continued.) The value of a determinant of order n can be found by the Laplace expansion of any row or any column as follows

n i+j A = ∑ aij ( 1) Mij , (55) j j j=1 j j where Mij is the minor of the element aij and can be obtained by deleting j j i+j the ith row and jth column of the determinant A and Cij = ( 1) Mij is called cofactor. j j j j j j Example: for a 3 3 matrix A, its determinant has the value:  a11 a12 a13 a22 a23 A = a21 a22 a23 = a11 (56) j j a32 a33 a a a 31 32 33

a21 a23 a21 a22 a12 + a13 . (57) a31 a33 a31 a32

Luo, Y. (SEF of HKU) ME September1,2017 24/35 Determinantal criterion for non-singularity

Given a linear equation system Ax = b, where A is a square coe¢ cient matrix, we have

A = 0 A is row or column independent j j 6 () A is nonsingular () 1 A exists () 1 A unique solution x =A b exists. ()

Luo, Y. (SEF of HKU) ME September1,2017 25/35 Finding the inverse matrix

Each element a of n n matrix A has a cofactor C . A cofactor matrix ij  j ij j C = Cij is also n n. The transpose C 0 is referred to as the adjoint of A and denotedj j by adj A.   1 The procedure to calculate A : 1 Find A j j 2 Find the cofactors of all elements of A and form C = Cij j j 3 Form C = adj A 0   4 Determine adj A A 1 = (58) A j j

Luo, Y. (SEF of HKU) ME September1,2017 26/35 Cramer’srule

Another way to calculate the inverse of a matrix An n is to use the Cramer  rule. Let Bj be the n n matrix formed by taking A and substituting its j th column, a , with the constants vector b. For example, for j = 2, j

B2 = a1 b a3 an (59)    a11 b1 a13 a1n      a21 b2 a23 a2n = 2    3 . (60)     6 an1 bn an3 ann 7 6    7 4 5 Let A = 0 and Bj be the determinants of A and Bj , respectively. See any linearj algebraj 6 textbookj j or pages 103-104 in CW for proof. 1 Cramer rule then says that the j th element of the solution x =A b is given by B x = j j j j = 1, , n. (61) j A 8    j j

Luo, Y. (SEF of HKU) ME September1,2017 27/35 Reconsider the two-commodity Model

c1P1 + c2P2 = c0 (62) d1P1 + d2P2 = d0, (63) which can be rewritten as

c1 c2 P1 c0 = , (64) d1 d2 P2 d0      A x b which implies that | {z }| {z } | {z }

1 P1 c1 c2 c0 1 d2 c2 c0 = = P2 d1 d2 d0 A d1 c1 d0       j j     c2d0 c0d2 = c1d2 c2d1 . (65) c0d1 c1d0 " c1d2 c2d1 #

Luo, Y. (SEF of HKU) ME September1,2017 28/35 Reconsider equilibrium national-income Model

The model

Y = C + I0 + G0 (Equilibrium condition) (66) C = a + bY (The consumption function), (67) can be rewritten in a compact matrix form 1 1 Y I + G = 0 0 , (68) b 1 C a      A x b which implies that | {z }| {z } | {z } a+I +G Y 1 1 1 I + G 0 0 = 0 0 = 1 b . (69) C 1 b b 1 a a+b(I0 +G0 ) " 1 b #       Applying Cramer rule gives:

I0 + G0 1 1 1 a + I0 + G0 Y = / = . (70) a 1 b 1 1 b     Luo, Y. (SEF of HKU) ME September1,2017 29/35

IS-LM model: closed

Consider another linear model of macroeconomy: the IS-LM model made up of two sectors: the real goods sector and the monetary sector. The goods market involves the following equations: Y = C + I + G (71) C = a + b(1 t)Y (72) I = d ei (73) G = G0, (74)

where Y , C, I , and i (the interest rate) are endogenous variables, G0 is the exogenous variable, and a, b, d, e, and t are structural parameters. In the newly introduced money market, we have

Md = Ms (Equilibrium condition in the money market) (75) M = kY li (Aggregate money demand) (76) d Ms = M0, (77)

where M0 is the exogenous money supply and k and l are parameters. Note that these three equations can be reduced to

M0 = kY li (78) Luo, Y. (SEF of HKU) ME September1,2017 30/35 (Continued.) Together, the two sectors give the following system of equations

Y C I = G0 (79) b(1 t)Y C = a (80) I + ei = d (81)

kY li = M0, (82) which can be written in a compact matrix form:

1 1 1 0 Y G0 b(1 t) 1 0 0 C a = 2 0 0 1 e 32 I 3 2 d 3 6 k 0 0 l 76 i 7 6 M0 7 6 76 7 6 7 4 54 5 4 5 A x b | {z }| {z } | {z }

Luo, Y. (SEF of HKU) ME September1,2017 31/35 (Continued.) Applying Cramer rule gives:

G0 1 1 0 1 1 1 0 a 1 0 0 b(1 t) 1 0 0 Y  = 2 3 / 2 3 d 0 1 e 0 0 1 e

6 M0 0 0 l 7 6 k 0 0 l 7 6 7 6 7 l4(a + d + G ) + eM 5 4 5 = 0 0 . (83) ek + l [1 b(1 t)] Similarly, we may derive the expressions for other endogenous variables (C, I , i) in terms of both exogenous variables and structural parameters. It is clear that Cramer’srule is elegant, but if you have to invert a numerical matrix (e.g., a = 1, t = 0.1, b = 0.4, etc.), you’dbetter to use Matlab, Gauss, Mathematica, etc.

Luo, Y. (SEF of HKU) ME September1,2017 32/35 Note on homogeneous-equation system

The equation system Ax = b considered before can have any constants in the vector b. If b = 0, that is, every elements in the b vector is zero, the equation system becomes Ax = 0, (84) where 0 is a zero vector. This special case is referred to as a homogeneous-equation system. “homogeneous” here means that if all the variables x1, , xn are multiplied by the same number, the equation system will remain valid.   This is possible only if b = 0. Note that if the coe¢ cient matrix A is nonsingular (that is, it is invertible), a homogeneous-equation system can yield only a trivial solution, that is, x = 0. (check it yourself)

Luo, Y. (SEF of HKU) ME September1,2017 33/35 (Continued.) The only way to get a nontrivial solution from the above HE system is to have

A = 0, that is, to have a singular coe¢ cient matrix A. (85) j j No unique nontrivial solution exists for this HE system. For example, consider a 2 2 case:  a11x1 + a12x2 = 0 (86) a21x1 + a22x2 = 0, a a assume that A = 11 12 is singular, so that A = 0. This implies that a21 a22 j j   the row vector a11 a12 is a multiple of the row vector a21 a22 ; consequently, one of the two equations is redundant. By deleting the second equation from the system, we end up with one equation in two variables and the solution is x1 = ( a12/a11) x2, (87) which is well-de…ned if a11 = 0 and represents an in…nite number of solutions. 6

Luo, Y. (SEF of HKU) ME September1,2017 34/35 Solution Outcomes for a Linear-equation System

Ax = b Vector b b = 0 6 A =0 There exists a unique, nontrivial solution x= 0 jAj 6= 0 In…nite numbers of solutions if equations are6 dependent j j No solution if equations are inconsistent b = 0 A =0 There exists a unique, trivial solution x= 0 jAj 6= 0 In…nite numbers of solutions if equations are dependent j j Not possible if equations are inconsistent

Luo, Y. (SEF of HKU) ME September1,2017 35/35