2015 Midterm
2015 Midterm
Boyd
October 22 2015
Midterm Exam
Name:
SUNetID: @stanford.edu
1
1. Orthogonality. Suppose the n-vectors a, b, and c satisfy a ⊥ c and b ⊥ c. Which of
the following statements must hold? (That is, are true for any a, b, and c that satisfy
a ⊥ c, b ⊥ c.) Circle the ones that must hold.
• a ⊥ b.
• (a + b) ⊥ c.
• (a + c) ⊥ (b + c).
2. Matrix equations. Consider two m×n matrices A and B. Suppose that for j = 1, . . . , n,
the jth column of A is a linear combination of the first j columns of B. How do we
express this as a matrix equation? Circle the correct response.
• A 6= 0.
• All entries of A are nonzero.
• The columns of A are independent.
• The rows of A are independent.
• A is square.
2
4. Multiplication by a diagonal matrix. Suppose that A is an m×n matrix, D is a diagonal
matrix, and B = DA. Choose one of the following.
• y gives a set of currency holdings that we can obtain by exchanging our holdings.
• yi is the amount of currency i we can obtain by converting all our currencies into
currency i.
• yi is the amount of currency i we need to re-create our holdings by exchanges.
3
6. Interpreting sparsity. Suppose the n-vector x is sparse, i.e., has only a few nonzero
entries. Give a short sentence or two explaining what this means in each of the following
contexts.
(a) x represents the daily cash flow of some business over n days.
4
7. Suppose A is an n × n matrix that satisfies A2 = 0. Does this imply that A = 0?
(This is the case when n = 1.) If this is (always) true, explain why. If it is not, give a
specific counterexample, i.e., a matrix A that is nonzero but satisfies A2 = 0.
8. Cash flow to bank account balance. The T -vector c represents the cash flow for an
interest bearing bank account over T time periods. Positive values of c indicate a
deposit, and negative values indicate a withdrawal. The T -vector b denotes the bank
account balance in the T periods. We have b1 = c1 (the initial deposit or withdrawal)
and
bt = (1 + r)bt−1 + ct , t = 2, . . . , T,
where r > 0 is the (per-period) interest rate. (The first term is the previous balance
plus the interest, and the second term is the deposit or withdrawal.)
Find the T × T matrix A for which b = Ac. Roughly speaking, this matrix maps a
cash flow sequence into a bank account balance sequence. Your description must make
clear what all entries of A are.
5
9. Multiple channel marketing campaign. Potential customers are divided into m market
segments, which are groups of customers with similar demographics, e.g., college edu-
cated women aged 25–29. A company markets its products by purchasing advertising
in a set of n channels, i.e., specific TV or radio shows, magazines, web sites, blogs,
direct mail, and so on. The ability of each channel to deliver impressions or views by
potential customers is characterized by the reach matrix, the m × n matrix R, where
Rij is the number of views of customers in segment i for each dollar spent on channel
j. (We assume that the total number of views in each market segment is the sum
of the views from each channel, and that the views from each channel scale linearly
with spending.) The n-vector c will denote the company’s purchases of advertising, in
dollars, in the n channels. The m-vector v gives the total number of impressions in
the m market segments due to the advertising in all channels. Finally, we introduce
the m-vector a, where ai gives the profit in dollars per impression in market segment
i. The entries of R, c, v, and a are all nonnegative.
(Questions on facing page.)
6
(a) Express the total amount of money the company spends on advertising using
vector/matrix notation.
(b) Express v using vector/matrix notation, in terms of the other vectors and matri-
ces.
(c) Express the total profit from all market segments using vector/matrix notation.
(d) How would you find the single channel most effective at reaching market segment
3, in terms of impressions per dollar spent?
(e) What does it mean if R35 is very small (compared to other entries of R)?
7
10. A surprising discovery. An intern at a quantitative hedge fund examines the daily
returns of around 400 stocks over one year (which has 250 trading days). She tells
her supervisor that she has discovered that the returns of one of the stocks, Google
(GOOG), can be expressed as a linear combination of the others, which include many
stocks that are unrelated to Google (say, in a different type of business).
Her supervisor then says: “It is overwhelmingly unlikely that a linear combination of
the returns of unrelated companies can reproduce the daily return of GOOG. So you’ve
made a mistake in your calculations.”
Is the supervisor right? Did the intern make a mistake? Give a very brief explanation.