Appendix A Basic Mathematical Tools 2015
Appendix A Basic Mathematical Tools 2015
I. Summation Operation and Descriptive
Statistics
Basic Mathematical Tools II. Properties of Linear Functions
III. Proportions and Percentages
Read Wooldridge, Appendix A IV. Special Functions
V. Differential Calculus
I. Summation Operation and
Descriptive Statistics Summation Operation
• Summation operator () involves the sum of many numbers.
• Property s.1: For any constant c,
n
• Given a sequence of n numbers
{xi; i=1, …, n}
c nc
i 1
• The sum of these numbers
• The sum of n constants (c) equals the product of n and c
n
x = x
i1
i 1 + x2 + …. + xn
cxi c xi n n n
i 1 i 1
(ax by ) a x b y
i 1
i i
i 1
i
i 1
i
The sum of c times xi equals c time the sum of xi.
Summation Operation Summation Operation
• Notes that the sum of ratios is not the ratio of the sums. • Note that the sum of the squares is not the square of the sum.
n n
x ( xi ) 2
n
n
xi x i i
2
y i 1
n
i 1 i 1
i 1 i
y
i 1
i
• Example: n = 2
• Example: n = 2 x12 + x22 (x1 + x2 ) 2
Descriptive Statistics: Sample median Descriptive Statistics: Sample median
• Other measure of central tendency is sample • Steps in finding sample median
median.
Step 1: order the values of the xi from smallest to largest.
• Example: Given numbers, {‐4, 8, 2, 0, 21, ‐10, 18} Step 2: if n is odd, the sample median is the middle number of
– Sample mean = 35/7 = 5 the ordered observations.
– Sample median = 2
• Ordered sequence {‐10, ‐4, 0, 2, 10, 18, 21} Step 3: if n is even, the median is defined to be the average of
the two middle values.
• If 21 is changed to 42
• Numbers {‐4, 8, 2, 0, 42, ‐10, 18} • Deviations
– Sample mean = 56/7 = 8
– Sample median = 2 • Deviations can be found by taking each observation and subtracting off
• Ordered sequence {‐10, ‐4, 0, 2, 10, 18, 42} the sample average
• Sample median: di xi x
Good point: it is less sensitive than sample average to changes
in the extreme values in a list of numbers. Examples are
median housing values or median income.
Summation Operation and Descriptive
Statistics Deviations and Demean Sample
Example: n =5
• Properties d1: Given {xi; i=1, …, n},
x1 = 6, x2 = 1, x3 = ‐2, x4 = 0, x5 = 5
The sum of the deviations equal zero.
n n
x ?
di xi x 0
i 1 i 1
Demean sample is {4, ‐1, ‐4, ‐2, 3}
n
x x 0
i 1
i
• Properties d2: Given {xi; i=1, …, n}, • Properties d3: Given {(xi,yi): i=1, …,n},
the sum of squared deviations is the sum of squared xi minus It can be shown that
n n
n times the squared of sample mean.
( xi x )( yi y ) xi ( yi y )
i 1 i 1
n n
(x x ) x
i 1
i
2
i 1
i
2
n( x ) 2 n n
( xi x ) yi xi yi n( x y )
i 1 i 1
• Show!
Summary: Summation and Deviation Problem A.1
Summation Deviation A.1 The following table
contains monthly housing
s.1 d.1 expenditures for 10 families.
s.2 d.2 2
2 (i) Find the average monthly
housing expenditure. [ans.]
s.3 d.3
(ii) Find the median monthly
housing expenditure. [ans.]
housing expenditure to $900 dollars, but the 9 670
10 530
expenditures of all other families remain the same.
Sum 5,660
Compute the average and median housing
Mean 566
expenditures. [ans.]
Solution A.1 (ii) Solution A.1 (iii)
(ii) 505
(iii)
Steps in finding sample mean
• $566 and $505 (in dollars), respectively
• Step 1: order the values of the xi from smallest to largest. • 5.66 and 5.05 (in hundreds of dollars),
{300, 350, 440, 450, 480, 530, 640, 670, 700, 1100,}
respectively.
• Step 3: if n is even, the median is defined to be the average of
the two middle values.
The two middle numbers are 480 and 530; when these are averaged,
we obtain 505, or $505.
Example A.2 Linear Housing Expenditure
Linear Functions
Functions
• Relationship between monthly housing (dollar) expenditure
• y = 0 + 1x and monthly income (dollar)
y = 1x – housing = 0 + 1income
denotes “change”. – housing = 164 + 0.27income
• Interpret: 0 = 164 or intercept
– When income=0, housing expenditures equal $164.
– A family with no income spends $164 on housing.
Example A.2 Linear Housing Expenditure
Functions Linear functions
• housing = 164 + 0.27income
• MPC and APC • A linear function can have more than two variables.
– 1 is the marginal propensity to consume (MPC). • y = 0 + 1x1 + 2x2
1 = 0.27
– The average propensity to consume can be written as
hou sin g 164
– 0 is called the intercept (the value of y when x1=0 and
0.27 x2=0)
income income
– 1 and 2 are slopes.
• Note that (1) APC is not constant
(2) APC>MPC
(3) APC gets closer to MPC as income increases.
y
• The change in y, for given changes in x1 and x2 is 1 .... if x2 0
y = 1 x1 + 2 x2 x1
• 1 is how y changes with x1, holding x2 fixed. We called the
• If x2 does not change (x2 =0), then partial effect of x1 on y.
y = 1 x1 if x2 =0.
• The notion of ceteris paribus.
• If x1 does not change (x1 =0), then Note that partial effect involves holding some factors fixed.
y = 2 x2 if x1 =0.
• quantity = 120 – 9.8price + 0.03income
price: dollars per disc
income: measured in dollars
• Interpretation
– 9.8 is the partial effect of price on quantity. Holding income fixed,
when the price of compact discs increases by one dollar, the quantity
demanded falls by 9.8.
Interpret 2
Solution A.2 (i) Solution A.2 (ii)
(i) (ii)
missed = 3 + 0.2distance distance = 5
missed = 3 + 0.2distance
• This is just a standard linear equation with
intercept equal to 3 and slope equal to .2.
• The intercept is the number of missed classes • 3 + .2(5) = 4 classes.
for a student who lives on campus.
III. Proportions and Percentages
Solution A.3
A.3 quantity = 120 – 9.8price + 0.3income • Proportions and percentages play an important role
in applied economics.
• If price = 15 and income = 200,
quantity = 120 – 9.8(15) + .03(200) • Examples in the form of percentages
= –21, – inflation rates,
– unemployment rates, and
• This is nonsense.
– entrance acceptance rates.
• This shows that linear demand functions generally
cannot describe demand over a wide range of prices
and income.
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 43
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 44
II. Properties of Linear Functions Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat III. Proportions and Percentages Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat
Proportions and Percentages Proportions and Percentages
• A proportion is the decimal form of percent.
Example: Admission Rate
A percentage is simply obtained by multiplying a proportion
by 100.
• Proportion:
• When using percentages, we often need to convert them to – the proportion of applicants who are admitted to MABE is 0.50.
decimal form. • Percentage:
For example: find interest income – 50 percent of the applications are admitted to MABE program.
– if the annual return on time deposit is 7.6% and we save 30,000 baht
at the beginning of the year,
– 7.6% = 0.76 (percentage = proportion) • If there are 200 applicants, how many students are admitted?
– our interest income is 30,000*0.076 = 2280
Proportions and Percentages Proportions
• Find changes in various quantities.
• A report by popular media can be incorrect.
• Let x be annual income
x0 is the initial value
Which one is correct?
x1 is the subsequent value.
• In Thailand, the percentage of high school dropout is .20. The proportionate change in x in moving from x0 to x1 is
• Her percentage in econometric exam is .75. x1 x0 x
x0 x0
This is sometimes called the relative change.
• Note that to get the proportionate change we simply divide the change in
x, or x, by its initial value.
• Unemployment rate has increased by one percentage point.
• Example: During General Chavalit administration (1997), the
• But unemployment rate has increased by 25 percent! value added tax was increased from 7% to 10%.
• Summary • Who is correct?
– The percentage point change is the change in the percentages. – Supporters
– The percentage change is the change relative to the initial value (x2002) This is simply a three percentage point increase! or an increase of
x1 x0 x three satang on the baht.
100* 100* – Opponents
x0 x0
This is a 43% increase in value added tax!
x
%x 100*
x0
Problem A.4 Solution A.4 (i)
• A.4 Suppose the unemployment rate in the (i)
United States goes from 6.4% in one year to • The percentage point change is 5.6 – 6.4 = –.8,
5.6% in the next.
(i) What is the percentage point decrease in the • or an eight‐tenths of a percentage point
unemployment rate? [ans.] decrease in the unemployment rate.
(ii) By what percent has the unemployment rate
fallen? [ans.]
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 55 56
III. Proportions and Percentages Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat
Solution A.4 (ii) Problem A.5
(ii) • A.5 Suppose that the return from holding a particular
firm’s stock goes from 15% in one year to 18% in the
• The percentage change in the unemployment following year.
rate is
– The majority shareholder claims that “the stock
100[(5.6 – 6.4)/6.4] = –12.5%. return only increased by 3%,”
– while the chief executive officer claims that “the
return on the firm’s stock has increased by 20%.”
– Reconcile their disagreement. [ans.]
IV. Some Special Functions and A. quadratic
B. Logarithm
Solution A.5 Their Properties C. Exponential
A.5
• Linear function
• The CEO is referring to the change relative to the – y = 0 + 1x1
initial return of 15%. – Interpret:
• One unit change in x results in a same change in y, regardless of the
starting value of x.
• The majority shareholder is referring to the • Marginal effect of x on y is constant
percentage point increase in the stock return,
– To be precise, the shareholder should specifically refer to a • Example: utility function – the notion of diminishing marginal
3 percentage point increase. returns is not consistent with a linear relationship.
• Many economic phenomena requires the use of nonlinear
• One way to capture diminishing returns is to include a
functions quadratic term to a linear function.
y = 0 + 1x + 2x2
• Nonlinear function is characterized by the fact that the
change in y for a given change in x depends on the starting • Given 1>0 and 2 <0
value of x. The relationship between y and x has the parabolic shape. Let
• Quadratic functions 0=6 1=8 and 2 = ‐2
• Natural Logarithm
• Exponential Function
y = 6 + 8x ‐ 2x2
A. quadratic A. quadratic
B. Logarithm B. Logarithm
Graph: Quadratic functions C. Exponential
Quadratic functions C. Exponential
• When 1>0 and 2 <0, the maximum of the function occurs at
1
x*
(2 2 )
• This is called the turning point.
If y = 6 + 8x ‐ 2x2 (so 1=8 and 2 = ‐2), the largest value of y
occur at
x* = 8/4 = 2
y* = 6+8(2)‐2(22) = 14
• 2 <0. This implies a diminishing marginal effect of x on y • A diminishing marginal effect of x on y is the same as saying that
– the slope of the function decreases as x increases.
– Suppose we start at a low value of x and then increase x by
some amount, say c • Calculus: the derivative of the quadratic function:
• This has a larger effect on y than if we start at a higher value of x y = 0 + 1x + 2x2
and increase x by the same amount. (See graph)
• For “small” changes in x, the approximate slope of the quadratic function
– Once x>x*, an increase in x actually decreases y. is
y
slope 1 2 2 x
x
A. quadratic A. quadratic
Example A.4: A quadratic wage B. Logarithm B. Logarithm
function
C. Exponential
Quadratic functions C. Exponential
Interpretation:
1) Since 2<0, this implies the diminishing marginal effect of exper on wage. 1) there is an increasing marginal return.
2) exper* = .48/[2(.008)] = 30. This is turning point. 2) the minimum of the function is at the point
– exper has a positive effect on wage up to the turning point.
3) The marginal effect of exper on wage depends on years of experience. 1
1st year (x0=0, x1=1, x=1) wage = .48 – 2*0.008(0) = .48 x*
5th year (x4=4, x5=5 x=1) wage = .48 – 2*0.008(4) = .416
4) At 30 years, an additional year of experience would lower the wage.
(2 2 )
32th year (x31=31, x32=32 x=1) wage = .48 – 2*0.008(31) = ‐.016
• Properties
1) The log function is defined only for positive values of x (x>0).
• The natural logarithm, an important nonlinear function, plays an See graph of a log function
important role in econometric analysis.
for 0<x<1 log(x) < 0
• We denotes the natural logarithm as the log function for x=1 log(x) = 0
for x>1 log(x) >0
y = log(x)
2) When y= log(x), the effect of x on y never becomes negative.
• Other common symbols include loge(x) and ln(x). y 1
y = log(x)
– Most calculators use ln(x). x x
– Different symbols are useful when we use logarithm with different bases.
• The relationship between x and y displays diminishing returns.
• The slope of the function gets closer and closer to zero as x gets large
A. quadratic A. quadratic
B. Logarithm Natural Logarithm B. Logarithm
Graph: log function C. Exponential C. Exponential
• What is the difference in slopes between the quadratic and
the log function?
Ans. The marginal effect of x on y of the log function never
becomes negative.
• Some useful algebraic facts:
l.1) log(x1x2) = log(x1) + log(x2)
l.2) log(x1/x2) = log(x1) – log(x2)
l.3) log(xc) = clog(x) for any constant c.
• The difference in logs can be used to approximate proportionate changes. • Example, for a small change: x0=40 and x1=41
x1 x0 x
– Exact percentage change
log( x1 ) log( x0 ) for small changes in x. = 100*(41‐40)/40 = 2.5%
x0 x0
– Approximate percentage change
• Note that log(x) = log(x1)‐log(x0) = 100*[log(41)‐log(40)] = 2.47%
• Approximate percent change is • Example, for a large change: x0=40 and x1=60
– Exact percentage change
= 100*(60‐40)/40 = 50%
100 log(x) ≈ %x for small changes in x.
– Approximate percentage change
= 100*[log(60)‐log(40)] = 40.55%
A. quadratic A. quadratic
B. Logarithm B. Logarithm
Natural Logarithm C. Exponential
Natural Logarithm C. Exponential
• Elasticity of y with respect to x can be written as • Constant Elasticity Model
y x %y log(y) = 0 + 1log(x)
x y %x
• The slope or elasticity is approximately equal to
– It is the percentage change in y when x increases by 1%
log( y )
1
• If y is a linear function, y = 0 + 1x, then the elasticity is log( x)
y x x x
1 1
x y y 0 1 x • It is the elasticity of y with respect to x
– It depends on the value of x.
Demand Function
C. Exponential
Natural Logarithm C. Exponential
• Log‐level model
log(y) = 0 + 1x
• Let q quantity demanded (unit)
log(y) = 1x
p price (dollar) 100log(y) = 1001x
%y = (1001)x
log(q) = 4.7 – 1.25log(p)
• The slope or the semi‐elasticity of y with respect to x is
%y
– The price elasticity of demand = ‐1.25 100 1
– Interpret x
• A 1% percent increase in price leads to a 1.25% fall in the quantity
• The semi‐elasticity is the percentage change in y when x increases by one
demanded.
unit. It is equal to 1001.
A. quadratic A. quadratic
Example A.6: Logarithmic B. Logarithm B. Logarithm
Wage Equation
C. Exponential
Natural Logarithm C. Exponential
• Level‐log function
• Hourly wage and years of education are related by y = 0 + 1log(x)
y = 1 log(x)
log(wage) = 2.78 + .094 educ 100y = 1100 log(x)
• Using approximation,
%(wage) = 100(.094)educ
100y = 1%x
%(wage) = 9.4educ
y = (1/100)(%x)
• Interpret: • Interpret
– One more year education increases hourly wage by about 9.4% – 1/100 is the unit change in y when x increases by 1%
• Let hours hours worked per week
wage hourly wage
hours = 33 + 45.1log(wage)
hours = (45.1/100)(%wage)
hours = 0.451(%wage)
• Interpret
1% increase in wage increases the weekly hours worked by
about 0.45, or slightly less than one‐half hour.
A. quadratic A. quadratic
B. Logarithm B. Logarithm
Exponential Function C. Exponential
Exponential Function C. Exponential
• We write the exponential function as
• The exponential function is related to the log function.
y = exp(x)
– Other notation can be written as
• For example, given log(y) that is a linear function of x, y = ex
– How to find y itself as a function of x?
• Facts
– exp(0) =1;
– exp(1) = 2.7183
– exp(x) is defined for any value of x.
– exp(x) is always greater than 0
• The exponential function is the inverse of the log function in the following
sense:
log[exp(x)] = x, for all x
exp[log(x)] = x, for x>0
In other words, the log
“undoes” the exponential, and
vice versa.
The exponential function is
sometimes called the anti‐log
function.
A. quadratic
B. Logarithm
Exponential Function C. Exponential Summary: Logarithm and Exponential
• Given a function,
• Some algebraic facts:
e.1) exp(x1+ x2) = exp(x1)∙exp(x2) or ex1+ x2 = ex1∙ex2 l.3 log(xc) = clog(x) e.3 exp[clog(x)] = xc
e.2) exp(x1‐ x2) = exp(x1)/exp(x2) or ex1‐ x2 = ex1/ex2
e.3) exp[clog(x)] = xc or eclog(x) = xc
(ii) Now use the difference in natural logs to find
the approximate percentage difference. [ans.]
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 89
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 90
IV. Some Special Functions and Their Properties Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat IV. Some Special Functions and Their Properties Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat
Solution A.6 (ii) Problem A.7
(ii) • A.7 Suppose the following model describes the
• The approximate proportionate change is relationship between annual salary (salary) and
the number of previous years of labor market
log(42,000) – log(35,000) =.182, experience (exper):
so the approximate percentage change is %18.2. log(salary) = 10.6 + .027exper.
• [Note: log() denotes the natural log.]
(i) What is salary when exper = 0? when exper =
5? (Hint: You will need to exponentiate.) [ans.]
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 91
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 92
IV. Some Special Functions and Their Properties Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat IV. Some Special Functions and Their Properties Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat
Problem A.7 continue … Solution A.7 (i)
(ii) Use equation (A.28) to approximate the (i) log(salary) = 10.6 + .027exper
percentage increase in salary when exper
increases by five years. [ans.] • When exper = 0,
log(salary) = 10.6; therefore, salary =
exp(10.6) = $40,134.84.
(iii) Use the results of part (i) to compute the
exact percentage difference in salary when
exper = 5 and exper = 0. Comment on how this • When exper = 5,
compares with the approximation in part (ii). salary = exp[10.6 +.027(5)]
[ans.] = $45,935.80.
Solution A.7 (ii) Solution A.7 (iii)
(iii) log(salary) = 10.6 + .027exper
(ii) exper=0 log(salary) = 10.6 + .027exper
100log(y)= 1001x (A.28) salary = exp(10.6) = $40,134.84.
exper=5 log(salary) = 10.6 + .027exper
salary = exp[10.6 +.027(5)] = $45,935.80.
• The approximate proportionate increase is
.027(5) = .135, • Exact percentage increase
100[(45,935.80‐40,134.84)/40,134.84)
= 14.5%,
so the approximate percentage change is
13.5%. so the exact percentage increase is about one percentage
point higher.
dy 1
dx x
• For a small change, evaluated at the initial point x0,
df/dx is the derivative of the function f, evaluated at the
1 x ,
initial point x0. y x log( x)
x0 x0
which is the approximation of the proportionate change in x.
– The derivative of the sum of two functions is the sum of the derivatives
DC.3 Let f(x) = exp(x) = exp(x) or = exp(x)
– The derivative of the exponential function of x is the exponential function of x
DC.7 Let y = z(f(x)) =
Chain Rule
Differential Calculus
Find the derivatives of the following functions:
DC.7 Let y = f(z(x)) = =
– y = 0 + 1x+ 2x2
Example:
y = exp(0 + 1x) – y = 0 + 1/x
z = 0 + 1x
– y = 0 + 1
x
= =
= exp – y = 0 + 1log(x)
= exp x
– y = exp(0 + 1x)
Differential Calculus Differential Calculus
• We can approximate the change in y as • y = f(x1,…, xn)
x2,…, xn fixed
• Example
Example:
y = 0 + 1x1 + 2x2 log( ) = 0 + 1educ + 2exper + 3tenure + 4age
log( ) = .514 + .078educ +.002exper +.0088tenure +.0033age
1) What is the partial derivative of y with respect to x1 ?
I. Summation II. Linear III. Prop&Perc IV. SpecFunc V. Calculus 107 108
V. Differential Calculus Basic Mathematical Tools . Intensive Course in Mathematics and Statistics . Chairat Aemkulwat
Example A.8 wage function
Differential Calculus with interaction
• Find the partial effect of exper on wage:
wage/exper = .19 ‐ .008exper +.007educ
• At the initial values (exper0=5, educ0=12), the approximate change in wage
1) What is the partial derivative of y with respect to x1 ? is
wage/exper = 23.4 cents per hour
Differential Calculus Problem A.9
• Minimizing and maximizing functions. Let f(x1, x2, …, xk) is the A.9 Suppose the yield of a certain crop (in bushels per acre)
differentiable function of k variables. is related to fertilizer amount (in pounds per acre) as
• A necessary condition for x1*, x2*, …, xk* to optimize f over all possible
values of xj is yield = 120 +.19 fertilizer
(i) Graph this relationship by plugging in several values for
fertilizer. [ans.]
• Notes
1) All of the partial derivatives of f must be zero when they are evaluated at (ii) Describe how the shape of this relationship compares
the xh*. with a linear function between yield and fertilizer. [ans.]
2) These are called the first order conditions.
3) We hope to solve above equations for the xh*.