CS计算机代考程序代写 finance algorithm 1. Consider the following one period trinomial model: Ω = {ω1,ω2,ω3}, P(ωi) = 1/3 for i = 1,2,3, a bank account B with interest rate r = 0, and one stock S with S0 = 6 and

1. Consider the following one period trinomial model: Ω = {ω1,ω2,ω3}, P(ωi) = 1/3 for i = 1,2,3, a bank account B with interest rate r = 0, and one stock S with S0 = 6 and
We denote with C(K) the European call option (on the stock) with strike price K ≥ 0; this has payoff C1(K) := (S1 − K)+ at time 1. Answer the following questions and justify carefully with either proofs or counterexamples.
(a) Is the market (B,S) arbitrage free? (2 marks)
(b) Is the call option C(K1) with strike K1 = 4 replicable? (2 marks)
(c) Find arbitrage free prices C0(K1) (at time 0, in the given market (B, S)) of a call with strike K1 = 4. (5 marks)
(d) Consider the enlarged market (B,S,C(K1)) made of: bank account, stock, call option with strike K1 = 4 sold at time 0 at an arbitrage free price C0(K1). Is this market complete? Does the answer depend on the value of C0(K1)? (5 marks)
󰀻󰁁 󰁁󰁁
󰁁 2,ifω=ω1, S1(ω) = 󰁁󰁁󰀿󰁁󰁁󰁁 6, if ω = ω2, 󰁁󰁁󰁁󰀽 1 2 , i f ω = ω 3 .
(e) Consider the market (B,S,C(K1)) made of: bank account, stock, call option with strike K1 = 4 sold at time 0 at price C0(K1) := 13 . Now enlarge the market (B, S, C(K1)) using
5
call options with strike K2 = 5, sold at time 0 at price C0(K2). We do not assume that
C0(K2) is necessarily an arbitrage free price; instead we assume that C0(K2) satisfies the inequalities
C0(K2) ≤ C0(K1) ≤ C0(K2) + K2 − K1 (A) (S0 − K2)+ ≤ C0(K2) ≤ S0. (B)
It can be shown that in any market model where at least one of these inequalities fails there is an arbitrage. Does the converse hold, i.e. do our assumptions imply that the enlarged market (B, S, C(K1), C(K2)) is arbitrage free? If yes, prove it; if not, explicitly find values of C0(K2) which satisfy (A), (B) and for which the market admits an arbitrage.
(6 marks) (Total: 20 marks)
MATH96014/MATH97009/MATH97101 Mathematical Finance: An Introduction to Option Pricing (2020) Page 2

2. In the framework of the N-period binomial model with constant parameters S0 = 8,u = 2,d = 1/2,r = 0, let S = (Sn)Nn=0 be the stock price process, Mn its historical minimum up to time n (i.e. Mn := mini=0,…,n Si). Consider the down-and-in rebate option with the lower barrier L = 6 which expires at time N and pays 1 if Sn is less than L for any n = 0,…,N; in other words, this derivative has a payoff 1 − YN at maturity N, where Yn := 1{Mn≥6} (i.e. Yn = 1 if Mn ≥ 6, and Yn = 0 otherwise). We denote with Vn the arbitrage-free price at time n = 0, . . . , N of this option.
Below, whenever we say that a process is Markov, we mean with respect to the risk-neutral measure Q and with the usual filtration Fn = σ(X1,…,Xn),n = 0,…,N generated by the coin tosses Xn(ω) = ωn on the probability space Ω = {H, T }N . Answer the following questions and justify carefully with either proofs or counterexamples.
(a) Is M a Markov process?
(b) Is Y a Markov process?
(c) Is (S, M ) a Markov process?
(d) Is (S, Y ) a Markov process?
(e) Use the risk-neutral pricing formula to express Vn in terms of Vn+1.
(f) Work by backward induction to show that, for every n = 0, . . . , N ,
representation Vn = vn(Xn), where vn : Rk → R, n = 0,…,N, are some (deterministic) functions and X = (Xn)n is some Markov process with values in Rk, for some k ≥ 1. Determine one such X, and write explicitly vN and an explicit formula to express vn in terms ofvn+1 forn=0,…,N−1. (4marks)
(Total: 20 marks)
MATH96014/MATH97009/MATH97101 Mathematical Finance: An Introduction to Option Pricing (2020) Page 3
(2 marks) (3 marks) (4 marks) (5 marks) (2 marks)
Vn admits the

3. Consider a market (Bn,Sn)n=0,1,…,T described by a multi-period binomial model with constant parameters 0 < d < 1+r < u, and as usual let Fk = σ(X1,...,Xk),0 ≤ k ≤ T be the filtration generated by the coin tosses (Xi)i. Consider a forward-start call option, which entitles its holder to receive at time T0 ∈ N, T0 < T a call option (on the stock S) with maturity T and strike KST0 (where K > 0). Answer the following questions, and (other than in item (a)) justify carefully with proofs.
(a) Write down a formula, involving the expectation with respect to the risk-neutral measure Q,
for (b) (i)
(ii) (iii)
V0 := the price at time 0 of the forward-start call option. Prove that the random variables
Rk+1 :=Sk+1, k=0,1,…,T−1, Sk
are IID under the EMM Q. Provethat,foreachk=0,1,…,T−1,Rk+1 isindependentofFk.
(5 marks)
Prove that, for each i = 0, 1, . . . , T − 1, the random vector Vk+1 := (Rk )k=i+1,…,T −1 is independent of Fi. Hint: Prove that EQi (f(Ri+1, . . . , RT )) is constant, for any f.
(iv)
(c) Compute the expectation of ST0 under Q. (2 marks)
Prove that ST is independent of ST0 under Q. ST0
(7 marks) (d) Show that V0 = c(T − T0, Kx), where c(t, x) is the price at time 0 of a call option with
expiry t and S0 = x. (6 marks) (Total: 20 marks)
MATH96014/MATH97009/MATH97101 Mathematical Finance: An Introduction to Option Pricing (2020) Page 4

4. On the sample space Ω = {ωi}i=1,…,5 endowed with some probability P s.t. P(ωi) > 0 for all i, consider a one-period arbitrage-free market model where the bank account has zero interest rate, and there are two stocks S1, S2 with prices S01 = 3, S02 = 3
1󰀕 󰀖T2󰀕 󰀖T S1 = 1 3 5 7 4 , S1 := 1 4 6 5 4 .
For the non-replicable derivative with payoff X1, we consider the problem of finding p:=min{x:(x,h)∈R×R2 satisfiesVx,h(ω)≥X(ω)fori=1,2,3,4}, (1)
1i1i
the smallest initial capit󰁓al p of a portfolio (x,h) super-replicating X1 P a.s., where as usual we
denote with V x,h = x+ 2 h (Sj −Sj) the wealth relative to the initial capital x and the trading 1 j=1j10
strategy h = (h1, h2); and its dual linear program, i.e.
d:=max{EQ(X1):Q∈M}, whereM:={Qproba. onΩ:EQ(S1j −S0j)=0,j=1,2} (2)
is the set of martingale measures. We denote with h∗ any trading strategy s.t. V p,h∗ ≥ X P a.s., 11
and with Q∗ any element of M such that d = EQ∗ (X1), i.e. any optimisers of (1) and (2). Answer the following questions and justify carefully with either proofs or counterexamples.
(a) Prove that the market (B, S1, S2) is arbitrage-free.
(b) Is p an arbitrage-free price for X1? Prove your assertion.
(c) Prove that V p,h∗ = X Q∗ a.s.. 11
(3 marks) (2 marks) (3 marks)
(d) Consider the problem of finding the smallest initial capital p ̄ of a portfolio (x,h) super- replicating X1, choosing only among portfolios which are not short-selling the first stock (i.e. S1). Formulate this problem in a way analogous to (1), and formulate its dual problem in a way analogous to (2). Are the respective optimal values p ̄ and d ̄ always equal? (4 marks)
(e) Suppose you own one share of the first stock, and you are allowed to trade the second stock and use the bank account to borrow and deposit money, but you cannot trade in the first stock. Consider the smallest initial capital p ̃ which you will need to super-replicate X1. Formulate the problem of finding p ̃ in a way analogous to (1), and formulate its dual linear program in a way analogous to (2). (3 marks)
(f) Solve the primal and dual problems you formulated in item (e), i.e. find their optimisers and the optimal values, in the case where the derivative is given by
󰀕 󰀖T X1 := 1 0 3 4 −3 .
MATH96014/MATH97009/MATH97101 Mathematical Finance: An Introduction to Option Pricing (2020) Page 5
(5 marks)
(Total: 20 marks)

5. Consider the trinomial model with time index {0, 1}, and a market made of a bank account with interest rate r = 2 and of one stock whose price is given by S0 = 3 and
i f ω = x 1 if ω = x2 i f ω = x 3 ,
S1(ω) = 󰁁󰀿󰁁󰁁9 󰁁󰀽 1 5
where Ω = {x1, x2, x3} is the probability space, endowed with a probability P s.t. P({x1})= 2 , P({x2})= 5 , P({x3})= 3 .
󰀻 󰁁󰁁 3
10 10 10
An investor with initial capital 1 and utility function U(X) = ln(x),x > 0 wants to invest in this
market up to maturity.
5
(a) Compute the set of equivalent martingale measures. (6 marks)
(b) Compute the set of the terminal wealths which the investor can attain. (4 marks)
(c) Find the optimal investment strategy for the investor, i.e. compute the number of stocks ∆ˆ 0 he needs to buy or sell at time 0 in order to maximize the expected utility of his terminal wealth. (10 marks)
(Total: 20 marks)
MATH96014/MATH97009/MATH97101 Mathematical Finance: An Introduction to Option Pricing (2020) Page 6

(a) (b)
This trinomial model is free of arbitrage since the condition d < 1 + r < u is satisfied: indeedd=2/6=1/3,1+r=1,u=12/6=2. In the market (B, S) the call with strike K1 is not replicable. This follows from the next item, since we find that there exists more than one AFP (arbitrage free price) for the call. Alternatively, it follows from the fact that, since r = 0, the replication equation is x + h(S1 − S0) = C(K1), which in vector notation becomes (1) (c) which has no solution. Indeed its first equation gives x = 4h, its second equation gives x = 2, combining these gives h = 1/2, and these values do not solve the third equation since 2 + 6/2 = 5 does not equal 8. In this simple setting, the less computationally intensive way to find its AFP is probably to compute the smallest super-replication price s and largest sub- replication price i. An alternative but more commonly used way is to use the EMM (equivalent martingale measures), which we now do. Recall that Q is an EMM if S0 = EQ[S1/(1+r)], Q is a probability and Q ∼ P, i.e. iff qi := Q({ωi}) satisfy 󰀻 󰀿6=2q +6q +12q 󰁁󰁁󰀽 1 2 3 1=q1 +q2 +q3 qi >0fori=1,2,3
The system has 2 equalities and 3 unknowns, so it has one free parameter. So we choose q2 = t, and compute q1,q3 as q1 = 3(1 − t)/5,q3 = 2(1 − t)/5, and imposing qi > 0 we obtain that the set of (q’s corresponding to the set of)
EMM is 󰀻󰀿󰀳󰁃 3(1 − t)/5 󰀴󰁄 󰀼󰁀 M := 󰀽 t : t ∈ (0, 1)󰀾 .
2(1 − t)/5
As M is not empty, this confirms that the model is arbitrage-free. The set P
of AFP for the call with strike 4 is
P :={EQ[(S1 −4)+/(1+r)]:Q∈M}, 1
(2)
i . e .
󰀳󰁃 1 󰀴󰁄 󰀳󰁃 2 − 6 󰀴󰁄 󰀳󰁃 ( 2 − 4 ) + 󰀴󰁄 x 1 +h 6−6 = (6−4)+ , 1 12−6 (12−4)+
󰀳󰁃 1 󰀴󰁄 󰀳󰁃 − 4 󰀴󰁄 󰀳󰁃 0 󰀴󰁄 x1+h0=2, 168
SOLUTION OF FINAL EXAM M5MF22 2019/2020
1. Exercise 1, similarly seen in Lectures and Problems

2
(3)
(d)
(4)
SOLUTION OF FINAL EXAM M5MF22 2019/2020
which using (2) can be written as
P = 󰀝 3 (1 − t) · 0 + t · 2 + 2 (1 − t) · 8 : t ∈ (0, 1)󰀞 . 55
By evaluating the above expression at t = 0 and at t = 1 to get the values 16 and 2, and since the function of t which appears is strictly monotone (it is
5
affine), we get that P = (2, 16 ). 5
For any choice of AFP p := C0(4), the market (B,S,C(K1)) is complete. In- deed, the replication equation
x + h(S1 − S0) + k(C1(K1) − C0(K1)) = D1
for a derivative with payoff D1 corresponds to the system of equations
󰀳󰁃 1 󰀴󰁄 󰀳󰁃 − 4 󰀴󰁄 󰀳󰁃 0 − p 󰀴󰁄 󰀳󰁃 d 1 󰀴󰁄 x 1 +h 0 +k 2−p = d2 , 1 6 8−p d3
where di := D1(ωi). which always has a solution. Indeed, the system has 3 unknowns x,h,k, and is made of independent equations, because the vectors v1,v2,v3 which represent the payoff of bank account, stock and call option, are linearly independent: indeed v1,v2 are linearly independent (one is not a multiple of the other), and, for any choice of AFP p := C0(4), v3 is not a linear combination of v1,v2 (otherwise C1(4) would have been replicable).
For an alternative solution, observe that, for any choice of AFP C0(4), the market (B, S, C(4)) has only one EMM (thus it is complete), which is the unique EMM Q for the (B,S) market s.t.
C0(4) = EQ[C1(4)/(1 + r)].
The converse does NOT hold, i.e. our assumptions do not imply that the
enlarged market (B, S, C(K1), C(K2)) is arbitrage free. The reason is that,
C0(4) := 13 is an AFP for C(4), the market (B,S,C(K1)) is arbitrage-free 5
and complete, so any derivative has a unique AFP in (B,S,C(K1)), and the market (B,S,C(K1)) has only one EMM, which is the unique EMM Q for the (B, S) market s.t. (5) holds. We can then use such Q to find the unique AFP p for C1(5) in the (B,S,C(K1)) market, and show that there is a value of C0(5) which satisfies the inequalities
C0(K2) ≤ C0(K1) ≤ C0(K2) + K2 − K1 (S0 − K2)+ ≤ C0(K2) ≤ S0,
and yet is different from p. This happens because the above inequalities do not fix uniquely the exact value of C0(K2), but only require it to be in some interval I, so all but at most one value of C0(K2) ∈ I will result in an arbitrage. Of course, we actually have to check that the market (B,S,C(K1)) is complete, and that I is not degenerate (i.e. a singleton), which would invalidate our argument above; let us do that.
The EMMs for the market (B,S,C1(K1)) are the Q’s given by (2) and such
(5) (e)
(6) (7)
that C0(K1) = EQ(C1(K1)/(1 + r)). Since since t = 1 is the only solution of Q2
C0(K1) = E (C1(K1)/(1 + r)), i.e. of
13 = 3(1−t) ·0+t·2+ 2(1−t) ·8, 555

SOLUTION OF FINAL EXAM M5MF22 2019/2020 3 the market (B, S, C1(K1)) admits only one EMM, so it is complete.
Since the payoff C1(5) is given by
󰀳󰁃 ( 2 − 5 ) + 󰀴󰁄 󰀳󰁃 0 󰀴󰁄 (6−5)+ = 1 ,
(12 − 5)+ 7
the only AFP for C1(5) in the (B,S,C(K1)) market is given by
p = 3 (1 − 1 ) · 0 + 1 · 1 + 2 (1 − 1 ) · 7 = 19 . 5 2 2 5 2 10
Since (6) , (7) state that C0(5) must satisfy
13 − 1 ≤ C0(K2) ≤ 13, (6 − 5)+ ≤ C0(K2) ≤ 6,
55
or equivalently that 8 ≤ C0(K2) ≤ 13, we can choose for C0(5) any value in
55
[8, 13] \ {19} (say C0(5) = 2), with C0(K1) = 13 as chosen above, and the 55 10 5
corresponding market has an arbitrage, yet it satisfies (6) , (7).
2. Exercise 2, similarly seen in Lectures and Problems
(a) M is not Markov. Indeed after drawing its tree we immediately see the problem: M2(HH) = 8 = M2(HT) yet M3(HTT) = 4 is different from M3(HHH) = M3(HHT) = M3(HTH) = 8, so
EQ2 f(M3)(HH) = p ̃f(8) + (1 − p ̃)f(8), does not equal EQ2 f(M3)(HT) = p ̃f(8) + (1 − p ̃)f(4)
w h e n e v e r f ( 8 ) ∕ = f ( 4 ) , w h e r e p ̃ = Q ( H ) = 1 / 3 .
(b) Y is not Markov. Indeed after drawing its tree we immediately see the problem:
Y2(HH) = 1 = Y2(HT) yet Y3(HTT) = 0 is different from Y3(HHH) = Y3(HHT) = Y3(HTH) = 1, so
E Q2 f ( Y 3 ) ( T H ) = p ̃ f ( 1 ) + ( 1 − p ̃ ) f ( 1 ) , d o e s n o t e q u a l EQ2 f(Y3)(TT) = p ̃f(1) + (1 − p ̃)f(0)
w h e n e v e r f ( 1 ) ∕ = f ( 0 ) , w h e r e p ̃ = Q ( H ) = 1 / 3 .
(c) (S,M) is Markov, as it is easily guessed after drawing its tree. To prove it,
define Sn+1 󰀝 u, if Xn+1 = H Cn+1:= S = d, ifXn+1=T ,
n
so that Mn+1 = Mn ∧ (SnCn+1). Then by the independence lemma
where
g(s, m) := EQ[f(sCn+1, m ∧ (sCn+1))].
EQn[f(Sn+1,Mn+1)]=EQn[f(SnCn+1,Mn ∧(SnCn+1))]=g(Sn,Mn),
(d) (S, Y ) is Markov, as it is easily guessed after drawing its tree. To prove it, define Define h(x) := 1{x≥16}, x ∈ R, notice that h(x ∧ y) = h(x)h(y), so that Yn = h(Mn) and so
Yn+1 = h(Mn+1) = h(Mn ∧ (SnCn+1)) = Ynh(SnCn+1) . Then by the independence lemma
EQn[f(Sn+1,Yn+1)] = EQn[f(SnCn+1,Ynh(SnCn+1))] = z(Sn,Yn),

4
SOLUTION OF FINAL EXAM M5MF22 2019/2020
where
(e) The risk neutral pricing formula gives
z(s, y) := EQ[f(sCn+1, yh(sCn+1))]. V n = E Qn [ V n + 1 ]
1+r
(f) One could choose X to be either (S,M) or (S,Y).
1st solution If we take X = (S, M ) then, using the results of item (3) we
1 g(Sn, Mn), 1+r
vn(s, m) = 1 vn+1(su, m∧(su))+ 2 vn+1(sd, m∧(sd)), 0 ≤ n ≤ N−1, 3(1+r) 3(1+r)
where of course vN (s, m) = 1{m≥16} .
2nd solution If we take X = (S, Y ) then, using the results of item (4) we
1 z(Sn, Yn), 1+r
get that
vn(Sn, Mn) = Vn = EQn [ Vn+1 ] = 1 EQn [vn+1(Sn+1, Mn+1)] =
where
which leads to the formula
1+r 1+r
g(s, m) := EQ[vn+1(sCn+1, m ∧ (sCn+1))],
get that
vn(Sn, Yn) = Vn = EQn [ Vn+1 ] = 1 EQn [vn+1(Sn+1, Yn+1)] =
where
which leads to the formula
1+r 1+r
z(s, y) := EQ[vn+1(sCn+1, yh(sCn+1))],
vn(s, y) = 1 vn+1(su, yh(su)) + 2 vn+1(sd, yh(sd)), 3(1+r) 3(1+r)
0 ≤ n ≤ N − 1, 3. Exercise 3, similarly seen in Lectures and Problems
where of course vN (s, y) = 1 − y.
(a) The risk neutral pricing formula gives that the price of the forward-start is
V0 = 1 EQ󰀃(ST −KST0)+󰀄. (1+r)T
(b) The following implies at once (i) and (ii):
(i and ii)
It is enough to show that, for each i = 0,1…,T − 1, under the EMM Q the random variables
Rk+1:=Sk+1, k=i,i+1,…,T−1, Sk
are IID, and each Rk+1 is independent of Fi. This holds since, by definition
of Q
Q(Rk+1 =u|ω1,…,ωk)=p ̃:= (1+r)−d
u−d
does not depend on ω1, . . . , ωk (i.e. Rk+1 is independent of Fk) and
(R1,…,Rk) is a function of ω1,…,ωk (i.e. it is Fk-measurable).

(8)
(iii)
SOLUTION OF FINAL EXAM M5MF22 2019/2020 5
From (i) and (ii) it follows that the random vector (Rk)k=i+1,…,T−1 is independent of Fi: for example because the independence lemma gives thatforanyfunctionfT :RT−k →R
E QT − 1 ( f T ( R k + 1 , . . . , R T ) ) = f T − 1 ( R k + 1 , . . . , R T − 1 ) ,
where
fT −1(rk+1, . . . , rT −1) := EQ[fT (rk+1, . . . , rT −1, RT )].
Thus using the tower property of the conditional expectation we get EQk (fT (Rk+1,…,RT )) = EQk (fT−1(Rk+1,…,RT−1)),
and working by induction (/iterating the above reasoning) we get that EQk (fT (Rk+1, . . . , RT )) = EQk (fk+1(Rk+1)),
and the latter is constant and equals c := EQ(fk+1(Rk+1)), since Rk+1 is independent of Fk.
Thus, if W := fT (Vk+1), for any Fk-measurable random variable Y we get that
(c)
(d)
EQ[Y W] = EQ[EQk [Y W]] = EQ[Y EQk [W]] = EQ[Y c] = cEQ[Y ] = EQ[W]EQ[Y ], so Vk+1 is independent of Fk.
(iv) Since ST =RT0+1···RT isafunction(RT0+1,…,RT),itisindependent ST0
of FT0 .
Since the discounted stock price is a martingale under P ̃,
1 E ̃(ST0)= 1 E ̃(S0)=S0, andsoE ̃(ST0)=S0(1+r)T0. (1+r)T0 (1+r)0
Since ST0 > 0 we can write (ST −KST0 )+ as the product of the two independent 󰀓 󰀔+
SinceE ̃(ST0)=x(1+r)T0 andx>0wegetthat
V0 =x 1 E ̃󰀥󰀕ST −K󰀖+󰀦= 1 E ̃󰀥󰀕xST −Kx󰀖+󰀦.
(1 + r)T−T0 ST0 (1 + r)T−T0 ST0 Since the (Rk)k are IIDs, the random variables
xST =xRT0+1 ···RT, ST−T0 =S0R1 ···RT−T0 ST0
have the same law (under Q), and so
V0= 1 E ̃󰁫(ST−T0 −Kx)+󰁬=c(T−T0,Kx). (1+r)T−T0
random variables ST0 and ST ST0
− K , and so
V0 = 1 E ̃(ST0)E ̃󰀥󰀕ST −K󰀖+󰀦,
(1 + r)T ST0
which one could of course also have derived using the independence lemma.

6
(a)
SOLUTION OF FINAL EXAM M5MF22 2019/2020
4. Exercise 4, unseen
The market is arbitrage-free by the FTAP, since the set of EMM is
M = {(−1 + 5t + 5s, 2 − 8t − 6s, 2t, t, s) : t, s ∈ R} ∩ (0, ∞)5; this set non-empty iff such is N ∩ (0, ∞)2 , where
N :={(−1+5t+5s,2−8t−6s):t,s≥0}.
Drawing N allows to verify that N ∩ (0, ∞)2 ∕= ∅; for example one can choose
(b)
(c)
(9) (d) (10)
(11)
(12)
(e) (13)
(14)
󰀕1 2 1 1 1󰀖T
Since X1 is not replicable, p is not an arbitrage-free price. To build an arbitrage,
t = 1/20, s = 1/5 and thus obtain
Q = (−1 + 5t + 5s, 2 − 8t − 6s, 2t, t, s) = 4 , 5 , 10 , 20 , 5 ∈ M.
consider h∗ s.t. V p,h∗ ≥ X P a.s., and do this: short-sell one derivative at 11
price p, buy h∗ underlying S, and deposit the remaining money p − S01 − S02 in the bank. This leads to the final payoff V p,h∗ − X , which by definition is
11
positive, and is not a.s. zero (otherwise X1 would be replicable).
Since Q∗ is a martingale measure it satisfies p = 1 EQ∗ (V p,h∗ ). Since V p,h∗ ≥ 1+r1 1
X Q∗ a.s., the identity EQ∗ (X ) = EQ∗ (V p,h∗ ) shows that 111
Vp,h∗ =X Q∗ a.s.. 11
The first problem could be written either as
p ̄:=min{x:(x,h)∈R×R2 satisfiesVx,h ≥X a.s., h ≥0}, 111
or as
We choose to consider the second form, since it leads to a simpler-looking dual problem (with one variable less than the other). The dual of (11) is then
d ̄:= max{EQ(X1) : Q ∈ M ̄ },
M ̄ :={QprobaonΩ: EQ(S1−S01)≤0, EQ(S12−S02)=0}.
Since M ̄ ⊇ M ∕= ∅, M ̄ is not empty, so the dual problem is feasible. To apply the strong duality theorem and conclude that the two problems have solution
̄1
and p ̄ = d, one can either observe that the primal is feasible , or that the dual
is solvable2.
The first problem could be written either as
p ̃:=min{x:(x,h)∈R×R2 satisfies Vx,h ≥X a.s., h =1}, 111
or as
where
p ̄:=min{x:(x,h ,h )∈R×R ×RsatisfiesVx,h ≥X a.s.}, 12+11
p ̃:=min{x:(x,h )∈R×Rsatisfies: Vx,(1,h2) ≥X a.s.}. 211
1 󰁓x,h
For h = 0 and x big enough we have V1 = x ≥ X1(ωi) for all i
2Since the set of q ∈ R4+ s.t. 4i=1 qi = 1 (which corresponds to the set of probabilities on Ω) is bounded, so is its subset M ̄ . Thus the dual problem (16) is solvable, since it is the problem of maximising a continuous (in fact, linear) function on the closed and bounded (and thus compact) s e t M ̄ .

SOLUTION OF FINAL EXAM M5MF22 2019/2020 7
We choose to consider the second form, since it leads to a simpler-looking dual problem: one with 2 constraints and 4 variables, instead of one with 3 constraints and 5 variables. In fact, since
Vx,(1,h2) ≥X ⇐⇒x+h (S2 −S2)≥X −(S1 −S1), 11210110
we can (and choose to) rewrite (14) as the problem of super-hedging the deriv- ative with payoff X1 − (S1 − S01) by trading in the (B, S2) market, since we are more familiar with it. Thus we consider the problem
(15) p ̃:=min{x:(x,h)∈R×Rsatisfies: Vx,h2 ≥X −(S1−S1)a.s.}, 2 1110
(16)
(f)
whose dual is where
d ̃:= max{EQ(X1 − (S1 − S01)) : Q ∈ M ̃ }, M ̃ :={QprobaonΩ: EQ(S12−S02)=0}.
is the set of martingale measures for the market (B,S2).
Since the primal (15) has only two variables, we can easily solve it by graphical inspection, which we will presently do. Let us write (15) explicitly as the problem of minimising x over
󰀻󰁁󰁁󰁁󰁁 󰀳󰁅 1 󰀴󰁆 󰀳󰁅 − 2 󰀴󰁆 󰀳󰁅 3 󰀴󰁆 󰀼󰁁󰁁󰁁󰁁 (x,h )∈D:=󰀿(x,h )∈R2 :x󰁅󰁅 1 󰁆󰁆+h 󰁅󰁅 13 󰁆󰁆≥󰁅󰁅 01 󰁆󰁆󰁀
1 1 −4
Drawing the set D shows that the first and third inequality imply the others,
2 󰁁󰁁 2 󰁅󰁃 󰁆󰁄 2󰁅󰁃 󰁆󰁄 󰁅󰁃 󰁆󰁄󰁁󰁁 󰁁󰁁󰀽 1 2 0󰁁󰁁󰀾
so that D is the unbounded ’triangle’
D={(x,h2)∈R2 :x󰀕 1 󰀖+h2󰀕 −2 󰀖≥󰀕 3 󰀖}
131
with vertex (x, h2 ) = 1 (11, −2). Thus the optimal value is p ̃ = 11 , and the
(17)
minimiser is (x ̃, h ̃2) = 1 (11, −2). Notice (for later use) that it satisfies the 1st 5
and 3rd inequality defining D with equality; and that instead it satisfies the 2nd, 4th and 5th inequalities with strict inequality.
The dual problem has 5 variables which satisfy 2 constraints3, so there are
only 3 free variables. One could also solve it applying two iterations of the
Fourier-Motzkin elimination algorithm (seen in class), or use other LP methods
(e.g. the simplex method, or just evaluate the objective function at all extreme
points) which we didn’t cover them in class since it would have taken too long.
Let us instead implement a simpler solution. Notice that, having solved the
primal problem, we have a lot of information about the solution of the dual
problem. First, by the strong duality theorem we have that the optimal value
d ̃ of the dual problem also equals p ̃ = 11 , so the dual solution Q ̃ satisfies 5
E Q ̃ [ X 1 − ( S 1 1 − S 01 ) ] = 1 1 . 5
This brings down the number of free variables from 3 to 2, so we would already be in a position to solve this problem by graphical inspection; however, we
55
3The 5 variables qi ∈ R+, i ≤ 5 satisfy the 2 constraints 󰁓i qi = 1, EQ(S12 − S02) = 0.

8
SOLUTION OF FINAL EXAM M5MF22 2019/2020
can simplify it further. Indeed, by the ’complementary slackness’ condition condition
x ̃+h ̃2(S12−S02)=X1−(S1−S01) Q ̃a.s.,
which was proved to hold in item (3), we have that q ̃ = q ̃ = q ̃ = 0, since
245 x ̃+h ̃2(S12−S02)(ωi)>(X1−(S1−S01))(ωi) fori=2,4,5
as mentioned before. Asking that q ̃ ∈ M ̃ satisfies (17) we get that q ̃ , q ̃ satisfy 13
q ̃+q ̃=1, −2q ̃+3q ̃=0 3q ̃+q ̃=11.
131313
5
whose unique solution is q ̃ = 3 , q ̃ = 2 . Thus the dual optimiser is
1535
(a)
󰀕2 3 󰀖T q ̃= 5,0,5,0,0 .
5. Exercise 5, mastery question, seen in problems
We compute first the discounted stocks values as S ̄ = S = 3 and S ̄ = 001
( 1 8 )
S1/(1 + r), i.e.
󰀻󰁁󰀿 1 S ̄1(ω)=󰁁3 󰀽5
󰀻󰁁󰀿 − 2 ifω=x3. 󰀽 2
i f ω = x 1 ifω=x2 ifω=x3.
i f ω = x 1
ifω=x2 , sothat(S ̄1−S ̄0)(ω)=󰁁 0
̄Q ̄
RecallthatQ∈MifS󰀻=E [S],QisaprobabilityandQ∼P,i.e. iff
01
qi := Q({xi}) satisfy 󰀿
󰁁󰁁󰀽 1 2 3
Subtracting the second line from the first line we get 2 = 2q2 + 4q3, so writing s:=q3 wegetq2 =1−2sandthesecondlinenowgives
q1 =1−(1−2s)−s=s.
Imposing qi > 0 we obtain that the set of qi’s corresponding to M is
󰀻󰀿 󰀳󰁃 s 󰀴󰁄 󰀕 1󰀖󰀼󰁀 (EMM) 󰀽q(s):= 1−2s :s∈ 0,2 󰀾.
s
Noticeforlaterusethat 󰀳 0 󰀴 1 󰀳 1 󰀴
q ( 0 ) = 󰁃 1 󰁄 , q ( ) = 󰁃 02 󰁄 021
2
We will denote with Qs the probability such that (Qs({ωi}))i is the vector q(s),
and with P0, P1 the end-points of the segment M ̄ , i.e. the probabilities Qs with
s = 0, 1 corresponding to the vectors (18). 2
(b) The set of undiscounted attainable wealths is the affine subspace
󰀻󰀿 ̄ ̄ 󰀳󰁃1/5−2∆0󰀴󰁄 󰀼󰁀 (19) 󰀽(1+r)(x+∆0(S1 −S0))=3 1/5 :∆0 ∈R󰀾.
1/5 + 2∆0
3=q +3q +5q 1=q1 +q2 +q3
qi >0fori=1,2,3

SOLUTION OF FINAL EXAM M5MF22 2019/2020 9
(c) 1st solution Now let us instead simply solve the maximization problem by taking derivatives. We need to solve the optimization problem
max Eu(B1(x + ∆0(S ̄1 − S ̄0))). ∆0 ∈R
We then use (19) and see that we need to maximize
f(∆0):= 2 ln(3−6∆0)+ 5 ln(3)+ 3 ln(3+6∆0). 10 5 10 5 10 5
,
actuallymakesurethisisamaximimum,weshouldalsocheckthatf (∆0)<0; alternatively, it suffices to notice that f is a concave function (since such is the logarithm), so f′(∆ ̄0) = 0 implies that ∆ ̄0 is a maximizer. Notice how, in this example (as it often happens in very simple examples), the standard optimization approach leads to very simple computations; this generally fails to be true where there are multiple time steps, and does not handle constraints well (one needs to introduce Lagrange multipliers). More- over, this method is not well suited for problems in continuous time, plus it does not allow to develop any theory. 2nd and 3rd solution Let us now see two additional (related) ways to solve the problem, using martingale measures. The terminal wealth of the strategy ∆0 is given by X1(∆0) := (1 + r)(x + ∆0(S ̄1 − S ̄0)), where x = 1/5 is the initial capital. Following Pliska’s textbook, to the optimal final wealth Xˆ1 satisfies U′(Xˆ)= 1 󰀕λdP0+λdP1󰀖 1 1+r 0dP 1dP for some λi > 0, i = 0, 1, which are determined by asking that Xˆ1 is replicable. We now have two choices, and two corresponding ways to solve the problem. Replicability can be expressed by asking that Xˆ1(λ0,λ1) (found by inverting the above equation) satisfies
EPi 󰀣Xˆ1(λ0,λ1)󰀤 = x, i = 0,1, 1+r
which is a system of two unknowns in the two variables λ0,λ1. Having thus found the optimal final wealth Xˆ1, one can then solve the equation Xˆ1 =
To do this, we compute the first derivative
f′(∆0)= 2 · −6 + 3 · 6
10 3 −6∆0 10 3 +6∆0 55
and set it equal to zero. This gives
3 −6∆0 3 +6∆0 5=5,
23
fromwhichweget 3(1 −1)=5∆0 andsotheoptimalstrategyis∆ ̄0 = 1 . To 52 3 ′′ ̄50
(20)
(21)
(22)

10
(23)
(24)
SOLUTION OF FINAL EXAM M5MF22 2019/2020
X1 (∆0 ) to find the optimal trading strategy ∆ˆ 0 . Let us do this explicitly.
Using U′(x) = 1/x we write (21) as
Xˆ1=󰀃 1 󰀄
1+r λ0dP0 +λ1dP1 dP dP
and then using (EMM) and (18) we write this as 󰀻󰁁󰁁󰁁󰁁󰀿󰁁x = 2
󰁁󰁁 0
󰁁󰁁 1
5λ x1 = 1
󰁁󰁁 2λ0 󰁁3 󰀽x2 = 5λ1
where xi := Xˆ1 (ωi) and in the first equality we used that 1+r
󰀕 0λ0 + 1 λ1 󰀖 2 1/ 2 =
2 5λ1 10
(25)
(26)
(27)
(28)
and analogous calculations are used for the other two equalities. Using (18) we compute
EP0 󰀣Xˆ1(λ0,λ1)󰀤 = x1, EP1 󰀣Xˆ1(λ0,λ1)󰀤 = 1×0 + 1×2, 1+r 1+r 2 2
and then, using (24), (22) becomes
1 =x, 1 =x,
and since x = 1/5 this gives λ0 = 5 = λ1. Plugging this into (24) gives 2 󰀳4󰀴
Xˆ 1 = 3 󰁃 5 󰁄 , 25 6
and finally we solve Xˆ1 = X1(∆0) using (19), finding that ∆0 = 1/50; thus the optimal strategy is ∆ˆ 0 = 1/50.
Alternatively, to express that Xˆ1 is replicable we can use that Xˆ1 belongs to the set in (19); we are thus lead to solve the system of three equations (one
2λ0 2λ1
for each ω)
U′(X(∆))= 1 󰀕λdP0+λdP1󰀖 10 1+r0dP1dP
in the three unknowns ∆0,λ0,λ1. Of course solving a system in 3 unknowns is slightly harder than solving one in 2 unknowns and then another in 1 unknown, so this second method is slightly harder, in general. Using U′(x) = 1/x we write (27) as
X1(∆0) = 󰀃 1 󰀄 1+r λ0dP0 +λ1dP1
dP
dP

SOLUTION OF FINAL EXAM M5MF22 2019/2020 11
and then󰀻using (EMM), (18) and (19) we write this explicitly as
󰁁1 2
󰁁󰁁󰀿󰁁 − 2 ∆ =
󰁁󰁁5 0 5λ 󰁁󰁁 1
󰁁󰁁 1 = 1 , w h e r e s ∈ 󰀕 0 , 1 󰀖 , ∆ 0 ∈ R . 󰁁52λ0 2
󰁁1 3 󰀽 5 + 2∆0 = 5λ1
The second equality now gives λ0 = 5/2 and summing the first and third equality we get 2 = 1/λ1 and so λ1 = 5 . Plugging this into the third equality
52
now gives ∆0 = 1/50; thus the optimal strategy is ∆ˆ 0 = 1/50.
Notice that, instead of using Lagrange multipliers λ0,λ1, we can reparam-
eterize (21) in a way which you may be more familiar with. Indeed, from the
theory of optimal investment you know that U′(Xˆ1) = cdQs , and this is closely dPdQs 4
related to the above: just rewrite the right-hand side of (27) as c dP for some c > 0 and for some5 s ∈ 󰀃0,1󰀄. We can thus use c,s instead of λ0,λ1 as
2
parameters. To find Qˆ,c and ∆0 we use (19) to write the (vector) equation
Xˆ 1 ( ω ) = 1 d P ( ω ) , ω ∈ Ω a s 󰀻󰁁󰁁󰁁󰁁󰀿 󰀕 c d Qˆ 󰀖
31−2∆ =1·2 󰁁󰁁 0
󰁁󰁁󰁁5 c10s
󰁁󰁁 3 󰀕 1 󰀖 = 1 · 1 ,
w h e r e s ∈ 󰀕 0 , 1 󰀖 , c > 0 , ∆ 0 ∈ R ,
󰁁󰁁 󰀕 5 󰀖 c 2 ( 1 − 2 s ) 2
󰁁1 13 󰀽3 5+2∆0 =c·10s
and then find the unique solution to the above system of 3 equations in 3
variables. In fact, in the present setting of log utility things simplify a little,
as we can compute the value of c without even solving the above system: since
U′(x) = 1/x we get Xˆ1 = 1 dP , and so we can compute EQˆ [Xˆ1] without even
c d Qˆ
x ( 1 + r ) = E Qˆ [ Xˆ 1 ] = 1 E Qˆ [ d P ] = 1 E P [ d P d Qˆ ] = 1 .
knowing Qˆ, since
This way we found that c = 1/(x(1 + r)) = 5 , and plugging this into the
the first equation).
4Of course c is given by c := 1 (λ0 +λ1). 1+r
50
c dQˆ c dQˆdP c 3
system of equations, from the second equation we get s = 1/4, and so the third equation gives that the optimal strategy is ∆0 = 1 (which of course also solves
5Since M is convex, any convex combination of P0 and P1 is in M.