SlideShare a Scribd company logo
1 of 71
Download to read offline
Optimal Trading Strategies
Stochastic Control
Haksun Li
haksun.li@numericalmethod.com
www.numericalmethod.com
Speaker Profile
 Dr. Haksun Li
 CEO, Numerical Method Inc.
 (Ex-)Adjunct Professors, Industry Fellow, Advisor,
Consultant with the National University of Singapore,
Nanyang Technological University, Fudan University,
the Hong Kong University of Science and Technology.
 Quantitative Trader/Analyst, BNPP, UBS
 PhD, Computer Sci, University of Michigan Ann Arbor
 M.S., Financial Mathematics, University of Chicago
 B.S., Mathematics, University of Chicago
2
References
 Optimal Pairs Trading: A Stochastic Control
Approach. Mudchanatongsuk, S., Primbs, J.A., Wong,
W. Dept. of Manage. Sci. & Eng., Stanford Univ.,
Stanford, CA. 2008.
 Optimal Trend Following Trading Rules. Dai, M.,
Zhang, Q., Zhu Q. J. 2011
3
Mean Reversion Trading
4
Stochastic Control
 We model the difference between the log-returns of
two assets as an Ornstein-Uhlenbeck process.
 We compute the optimal position to take as a function
of the deviation from the equilibrium.
 This is done by solving the corresponding the
Hamilton-Jacobi-Bellman equation.
5
Formulation
 Assume a risk free asset 𝑀𝑑, which satisfies
 𝑑𝑀𝑑 = π‘Ÿπ‘€π‘‘ 𝑑𝑑
 Assume two assets,𝐴 𝑑 and 𝐡𝑑.
 Assume 𝐡𝑑follows a geometric Brownian motion.
 𝑑𝐡𝑑 = πœ‡π΅π‘‘ 𝑑𝑑 + πœŽπ΅π‘‘ 𝑑𝑧𝑑
 π‘₯ 𝑑is the spread between the two assets.
 π‘₯𝑑 = log 𝐴 𝑑 βˆ’ log 𝐡𝑑
6
Ornstein-Uhlenbeck Process
 We assume the spread, the basket that we want to
trade, follows a mean-reverting process.
 𝑑π‘₯𝑑 = π‘˜ πœƒ βˆ’ π‘₯𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑
 πœƒ is the long term equilibrium to which the spread
reverts.
 π‘˜ is the rate of reversion. It must be positive to ensure
stability around the equilibrium value.
7
Instantaneous Correlation
 Let 𝜌 denote the instantaneous correlation coefficient
between 𝑧 and πœ”.
 𝐸 π‘‘πœ” 𝑑 𝑑𝑧𝑑 = 𝜌𝜌𝜌
8
Univariate Ito’s Lemma
9
 Assume
 𝑑𝑋𝑑 = πœ‡ 𝑑 𝑑𝑑 + πœŽπ‘‘ 𝑑𝐡𝑑
 𝑓 𝑑, 𝑋𝑑 is twice differentiable of two real variables
 We have
 𝑑𝑑 𝑑, 𝑋𝑑 =
πœ•πœ•
πœ•πœ•
+ πœ‡ 𝑑
πœ•πœ•
πœ•πœ•
+
πœŽπ‘‘
2
2
πœ•2 𝑓
πœ•π‘₯2 𝑑𝑑 + πœŽπ‘‘
πœ•πœ•
πœ•πœ•
𝑑𝐡𝑑
Log example
 For G.B.M., 𝑑𝑋𝑑 = πœ‡π‘‹π‘‘ 𝑑𝑑 + πœŽπ‘‹π‘‘ 𝑑𝑧𝑑, 𝑑 log 𝑋𝑑 =?
 𝑓 π‘₯ = log π‘₯

πœ•π‘“
πœ•π‘‘
= 0

πœ•π‘“
πœ•π‘₯
=
1
π‘₯

πœ•2 𝑓
πœ•π‘₯2 = βˆ’
1
π‘₯2
 𝑑 log 𝑋𝑑 = πœ‡π‘‹π‘‘
1
𝑋𝑑
+
πœŽπ‘‹π‘‘
2
2
βˆ’
1
𝑋𝑑
2 𝑑𝑑 + πœŽπ‘‹π‘‘
1
𝑋𝑑
𝑑𝐡𝑑
 = πœ‡ βˆ’
𝜎2
2
𝑑𝑑 + πœŽπ‘‘π΅π‘‘
10
Multivariate Ito’s Lemma
11
 Assume
 𝑋𝑑 = 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛 is a vector Ito process
 𝑓 π‘₯1𝑑, π‘₯2𝑑, β‹― , π‘₯ 𝑛𝑛 is twice differentiable
 We have
 𝑑𝑑 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛
 = βˆ‘
πœ•
πœ•π‘₯ 𝑖
𝑛
𝑖=1 𝑓 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛 𝑑𝑋𝑖 𝑑
 +
1
2
βˆ‘ βˆ‘
πœ•2
πœ•π‘₯ 𝑖 πœ•π‘₯ 𝑗
𝑛
𝑗=1
𝑛
𝑖=1 𝑓 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛 𝑑 𝑋𝑖, 𝑋𝑗 𝑑
Multivariate Example
 log 𝐴 𝑑 = π‘₯ 𝑑 + log 𝐡𝑑
 𝐴 𝑑 = exp π‘₯ 𝑑 + log 𝐡𝑑

πœ•π΄ 𝑑
πœ•π‘₯ 𝑑
= exp π‘₯ 𝑑 + log 𝐡𝑑 = 𝐴 𝑑

πœ•π΄ 𝑑
πœ•π΅π‘‘
= exp π‘₯ 𝑑 + log 𝐡𝑑
1
𝐡𝑑
=
𝐴 𝑑
𝐡𝑑

πœ•2 𝐴 𝑑
πœ•π‘₯ 𝑑
2 =
πœ•π΄ 𝑑
πœ•π‘₯ 𝑑
= 𝐴 𝑑

πœ•2 𝐴 𝑑
πœ•π΅π‘‘
2 =
πœ•
πœ•π΅π‘‘
𝐴 𝑑
𝐡𝑑
= 0

πœ•2 𝐴 𝑑
πœ•π΅π‘‘ πœ•π‘₯ 𝑑
=
πœ•
πœ•π΅π‘‘
πœ•π΄ 𝑑
πœ•π‘₯ 𝑑
=
πœ•π΄ 𝑑
πœ•π΅π‘‘
=
𝐴 𝑑
𝐡𝑑
12
What is the Dynamic of Asset At?
 πœ•π΄ 𝑑 =
πœ•π΄ 𝑑
πœ•πœ•
𝑑π‘₯ 𝑑 +
πœ•π΄ 𝑑
πœ•π΅π‘‘
𝑑𝐡𝑑 +
1
2
πœ•2 𝐴 𝑑
πœ•π‘₯2 𝑑π‘₯ 𝑑
2 +
πœ•2 𝐴 𝑑
πœ•π΅π‘‘ πœ•π‘₯
𝑑π‘₯ 𝑑 𝑑𝐡𝑑
 = 𝐴 𝑑 𝑑π‘₯ 𝑑 +
𝐴 𝑑
𝐡𝑑
𝑑𝐡𝑑 +
1
2
𝐴 𝑑 𝑑π‘₯ 𝑑
2 +
𝐴 𝑑
𝐡𝑑
𝑑π‘₯ 𝑑 𝑑𝐡𝑑
 = 𝐴 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 +
𝐴 𝑑
𝐡𝑑
πœ‡π΅π‘‘ 𝑑𝑑 + πœŽπ΅π‘‘ 𝑑𝑧𝑑 +
1
2
𝐴 𝑑 πœ‚2 𝑑𝑑 +
𝐴 𝑑
𝐡𝑑
πœŒπœ‚πœ‚π΅π‘‘ 𝑑𝑑
13
Dynamic of Asset At
 πœ•π΄ 𝑑 = 𝐴 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 + 𝐴 𝑑 πœ‡π‘‘π‘‘ + πœŽπ‘‘π‘§π‘‘ +
1
2
𝐴 𝑑 πœ‚2
𝑑𝑑 + 𝐴 𝑑 πœŒπœ‚πœ‚π‘‘π‘‘
 = 𝐴 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + πœ‡ +
1
2
πœ‚2
+ 𝜌𝜌𝜌 𝑑𝑑 + 𝐴 𝑑 πœ‚πœ‚πœ” 𝑑 +
𝐴 𝑑 πœŽπ‘‘π‘§π‘‘
 = 𝐴 𝑑 πœ‡ + π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
πœ‚2
+ 𝜌𝜌𝜌 𝑑𝑑 + πœŽπ‘‘π‘§π‘‘ + πœ‚πœ‚πœ” 𝑑
14
Notations
 𝑉𝑑: the value of a self-financing pairs trading portfolio
 β„Ž 𝑑:the portfolio weight for stock A
 β„Ž 𝑑
οΏ½ = βˆ’β„Ž 𝑑:the portfolio weight for stock B
15
Self-Financing Portfolio Dynamic

𝑑𝑉𝑑
𝑉𝑑
= β„Ž 𝑑
𝑑𝐴 𝑑
𝐴 𝑑
+ β„Ž 𝑑
οΏ½ 𝑑𝐡𝑑
𝐡𝑑
+
𝑑𝑀𝑑
𝑀𝑑
 =
β„Ž 𝑑 πœ‡ + π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
πœ‚2
+ 𝜌𝜌𝜌 𝑑𝑑 + πœŽπ‘‘π‘§π‘‘ + πœ‚πœ‚πœ” 𝑑 βˆ’
β„Ž 𝑑 πœ‡π‘‘π‘‘ + πœŽπ‘‘π‘§π‘‘ + π‘Ÿπ‘Ÿπ‘Ÿ
 = β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
πœ‚2 + 𝜌𝜌𝜌 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 + π‘Ÿπ‘Ÿπ‘Ÿ
 = β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
πœ‚2
+ 𝜌𝜌𝜌 + π‘Ÿ 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑
16
Power Utility
 Investor preference:
 π‘ˆ π‘₯ = π‘₯ 𝛾
 π‘₯ β‰₯ 0
 0 < 𝛾 < 1
17
Problem Formulation
 max
β„Ž 𝑑
𝐸 𝑉𝑇
𝛾
, s.t.,
 𝑉 0 = 𝑣0, x 0 = π‘₯0
 𝑑π‘₯𝑑 = π‘˜ πœƒ βˆ’ π‘₯𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑
 𝑑𝑉𝑑 = β„Ž 𝑑 𝑑π‘₯ 𝑑 = β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑
 Note that we simplify GBM to BM of 𝑉𝑑, and remove
some constants.
18
Dynamic Programming
19
 Consider a stage problem to minimize (or maximize)
the accumulated costs over a system path.
s0
s11
s12
time
t = 0 t = 1
S21
S22
s23
t = 2
3
2
3
5
Cost = 𝑐3 + βˆ‘ 𝑐𝑑
2
𝑑=0
s3
s12
5
4
3
1
5
Dynamic Programming Formulation
 State change: π‘₯ π‘˜+1 = π‘“π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜
 π‘˜: time
 π‘₯ π‘˜: state
 𝑒 π‘˜: control decision selected at time π‘˜
 πœ” π‘˜: a random noise
 Cost: 𝑔 𝑁 π‘₯ 𝑁 + βˆ‘ 𝑔 π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜
π‘βˆ’1
π‘˜=0
 Objective: minimize (maximize) the expected cost.
 We need to take expectation to account for the noise, πœ” π‘˜.
20
Principle of Optimality
 Let πœ‹βˆ—
= πœ‡0
βˆ—, πœ‡1
βˆ—, β‹― , πœ‡ π‘βˆ’1
βˆ— be an optimal policy for
the basic problem, and assume that when using πœ‹βˆ—
, a
give state π‘₯𝑖 occurs at time 𝑖 with positive probability.
Consider the sub-problem whereby we are at π‘₯𝑖 at time
𝑖 and wish to minimize the β€œcost-to-go” from time 𝑖 to
time 𝑁.
 𝐸 𝑔 𝑁 π‘₯ 𝑁 + βˆ‘ 𝑔 π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜
π‘βˆ’1
π‘˜=𝑖
 Then the truncated policy πœ‡π‘–
βˆ—, πœ‡π‘–+1
βˆ—, β‹― , πœ‡ π‘βˆ’1
βˆ— is
optimal for this sub-problem.
21
Dynamic Programming Algorithm
 For every initial state π‘₯0, the optimal cost π½βˆ—
π‘₯ π‘˜ of the
basic problem is equal to 𝐽0 π‘₯0 , given by the last step
of the following algorithm, which proceeds backward
in time from period 𝑁 βˆ’ 1 to period 0:
 𝐽 𝑁 π‘₯ 𝑁 = 𝑔 𝑁 π‘₯ 𝑁
 𝐽 π‘˜ π‘₯ π‘˜ = min
𝑒 π‘˜
𝐸 𝑔 π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜ + 𝐽 π‘˜+1 π‘“π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜
22
Value function
 Terminal condition:
 𝐺 𝑇, 𝑉, π‘₯ = 𝑉 𝛾
 DP equation:
 𝐺 𝑑, 𝑉𝑑, π‘₯𝑑 = mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸 𝐺 𝑑 + 𝑑𝑑, 𝑉𝑑+𝑑𝑑, π‘₯𝑑+𝑑𝑑
 𝐺 𝑑, 𝑉𝑑, π‘₯𝑑 = mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸 𝐺 𝑑, 𝑉𝑑, π‘₯𝑑 + Δ𝐺
 By Ito’s lemma:
 Δ𝐺 =
𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 𝑑𝑑 + 𝐺 π‘₯ 𝑑π‘₯ +
1
2
𝐺 𝑉𝑉 𝑑𝑑 2 +
1
2
𝐺 π‘₯π‘₯ 𝑑π‘₯ 2 +
𝐺 𝑉π‘₯ 𝑑𝑉 𝑑𝑑
23
Hamilton-Jacobi-Bellman Equation
 Cancel 𝐺 𝑑, 𝑉𝑑, π‘₯ 𝑑 on both LHS and RHS.
 Divide by time discretization, Δ𝑑.
 Take limit as Δ𝑑 β†’ 0, hence Ito.
 0 = mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸 Δ𝐺
 mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 𝑑𝑑 + 𝐺 π‘₯ 𝑑𝑑 +
1
2
𝐺 𝑉𝑉 𝑑𝑑 2 +
1
2
𝐺 π‘₯π‘₯ 𝑑𝑑 2 + 𝐺 𝑉𝑉 𝑑𝑑 𝑑𝑑 =
0
 The optimal portfolio position is β„Ž 𝑑
βˆ—
.
24
HJB for Our Portfolio Value
 mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 𝑑𝑑 + 𝐺 π‘₯ 𝑑𝑑 +
1
2
𝐺 𝑉𝑉 𝑑𝑑 2 +
1
2
𝐺 π‘₯π‘₯ 𝑑𝑑 2 + 𝐺 𝑉𝑉 𝑑𝑑 𝑑𝑑 =
0
 mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸
𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 + 𝐺 π‘₯ 𝑑𝑑 +
1
2
𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑
2
+
1
2
𝐺 π‘₯π‘₯ 𝑑𝑑 2
+
𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 𝑑𝑑
= 0
 mπ‘Žπ‘Ž
β„Ž 𝑑
𝐸
𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 +
𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 +
1
2
𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑
2
+
1
2
𝐺 π‘₯π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑
2
+
𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 Γ— π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑
= 0
25
Taking Expectation
 All πœ‚πœ‚πœ” 𝑑 disapper because of the expectation operator.
 Only the deterministic 𝑑𝑑 terms remain.
 Divide LHR and RHS by 𝑑𝑑.
 mπ‘Žπ‘Ž
β„Ž 𝑑
𝐺𝑑 + 𝐺 𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
𝐺 𝑉𝑉 β„Ž 𝑑 πœ‚ 2
+
1
2
𝐺 π‘₯π‘₯ πœ‚2
+𝐺 𝑉𝑉 β„Ž 𝑑 πœ‚2
= 0
26
Dynamic Programming Solution
 Solve for the cost-to-go function, 𝐺𝑑.
 Assume that the optimal policy is β„Ž 𝑑
βˆ—
.
27
First Order Condition
 Differentiate w.r.t. β„Ž 𝑑.
 𝐺 𝑉 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + β„Ž 𝑑
βˆ—
𝐺 𝑉𝑉 πœ‚2
+ 𝐺 𝑉𝑉 πœ‚2
= 0
 β„Ž 𝑑
βˆ—
= βˆ’
𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2
 In order to determine the optimal position, β„Ž 𝑑
βˆ—
, we
need to solve for 𝐺 to get 𝐺 𝑉, 𝐺 𝑉𝑉, and 𝐺 𝑉𝑉.
28
The Partial Differential Equation (1)

𝐺𝑑 βˆ’
𝐺 𝑉
𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2
2
+
1
2
𝐺 π‘₯π‘₯ πœ‚2
βˆ’
𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2
= 0
29
The Partial Differential Equation (2)

𝐺𝑑 βˆ’
𝐺 𝑉 π‘˜ πœƒ βˆ’ π‘₯ 𝑑
𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2 +
𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 +
1
2
𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 2
𝐺 𝑉𝑉 πœ‚2 +
1
2
𝐺 π‘₯π‘₯ πœ‚2
βˆ’
𝐺 𝑉𝑉
𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉
= 0
30
Dis-equilibrium
 Let 𝑏 = π‘˜ πœƒ βˆ’ π‘₯ 𝑑 . Rewrite:
 𝐺𝑑 βˆ’ 𝐺 𝑉 𝑏
𝐺 𝑉 𝑏+𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏 +
1
2
𝐺 𝑉 𝑏+𝐺 𝑉𝑉 πœ‚2 2
𝐺 𝑉𝑉 πœ‚2 +
1
2
𝐺 π‘₯π‘₯ πœ‚2
βˆ’
𝐺 𝑉𝑉
𝐺 𝑉 𝑏+𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉
= 0
 Multiply by 𝐺 𝑉𝑉 πœ‚2
.
 𝐺𝑑 𝐺 𝑉𝑉 πœ‚2 βˆ’ 𝐺 𝑉 𝑏 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏𝐺 𝑉𝑉 πœ‚2 +
1
2
𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2
+
1
2
𝐺 π‘₯π‘₯ 𝐺 𝑉𝑉 πœ‚4
βˆ’
𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 = 0
31
Simplification
 Note that
 βˆ’πΊ 𝑉 𝑏 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 +
1
2
𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2 βˆ’
𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2
= βˆ’
1
2
𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2
 The PDE becomes
 𝐺𝑑 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏𝐺 𝑉𝑉 πœ‚2 +
1
2
𝐺 π‘₯π‘₯ 𝐺 𝑉𝑉 πœ‚4 βˆ’
1
2
𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2 = 0
32
The Partial Differential Equation (3)
 𝐺𝑑 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏𝐺 𝑉𝑉 πœ‚2 +
1
2
𝐺 π‘₯π‘₯ 𝐺 𝑉𝑉 πœ‚4 βˆ’
1
2
𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2
= 0
33
Ansatz for G
 𝐺 𝑑, 𝑉, π‘₯ = 𝑓 𝑑, π‘₯ 𝑉 𝛾
 𝐺 𝑇, 𝑉, π‘₯ = 𝑉 𝛾
 𝑓 𝑇, π‘₯ = 1
 𝐺𝑑 = 𝑉 𝛾
𝑓𝑑
 𝐺 𝑉 = 𝛾𝑉 π›Ύβˆ’1 𝑓
 𝐺 𝑉𝑉 = 𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2 𝑓
 𝐺 π‘₯ = 𝑉 𝛾 𝑓π‘₯
 𝐺 𝑉π‘₯ = 𝛾𝑉 π›Ύβˆ’1
𝑓π‘₯
 𝐺 π‘₯π‘₯ = 𝑉 𝛾
𝑓π‘₯π‘₯
34
Another PDE (1)
 𝑉 𝛾
𝑓𝑑 𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2
π‘“πœ‚2
+ 𝑉 𝛾
𝑓π‘₯ 𝑏𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2
π‘“πœ‚2
+
1
2
𝑉 𝛾
𝑓π‘₯π‘₯ 𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2
π‘“πœ‚4
βˆ’
1
2
𝛾𝑉 π›Ύβˆ’1
𝑓𝑏 + 𝛾𝑉 π›Ύβˆ’1
𝑓π‘₯ πœ‚2 2
= 0
 Divide by 𝛾 𝛾 βˆ’ 1 πœ‚2 𝑉2π›Ύβˆ’2.
 𝑓𝑑 𝑓 + 𝑓π‘₯ 𝑏𝑓 +
1
2
𝑓π‘₯π‘₯ π‘“πœ‚2
βˆ’
𝛾
2 π›Ύβˆ’1
𝑓
𝑏
πœ‚
+ 𝑓π‘₯ πœ‚
2
= 0
35
Ansatz for 𝑓
 𝑓𝑓𝑑 + 𝑏𝑏𝑓π‘₯ +
1
2
πœ‚2
𝑓𝑓π‘₯π‘₯ βˆ’
𝛾
2 π›Ύβˆ’1
𝑏
πœ‚
𝑓 + πœ‚π‘“π‘₯
2
= 0
 𝑓 𝑑, π‘₯ = 𝑔 𝑑 exp π‘₯π‘₯ 𝑑 + π‘₯2 𝛼 𝑑 = 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼
 𝑓𝑑 =
𝑔𝑑 exp π‘₯π‘₯ + π‘₯2
𝛼 + 𝑔 exp π‘₯π‘₯ + π‘₯2
𝛼 π‘₯𝛽𝑑 + π‘₯2
𝛼 𝑑
 𝑓π‘₯ = 𝑔 exp π‘₯π‘₯ + π‘₯2
𝛼 𝛽 + 2π‘₯π‘₯
 𝑓π‘₯π‘₯ =
𝑔 exp π‘₯π‘₯ + π‘₯2
𝛼 𝛽 + 2π‘₯π‘₯ 2
+ 𝑔 exp π‘₯π‘₯ + π‘₯2
𝛼 2𝛼

𝑓π‘₯
𝑓
= 𝛽 + 2𝛼𝛼
36
Boundary Conditions
 𝑓 𝑇, π‘₯ = 𝑔 𝑇 exp π‘₯π‘₯ 𝑇 + π‘₯2 𝛼 𝑇 = 1
 𝑔 𝑇 = 1
 𝛼 𝑇 = 0
 𝛽 𝑇 = 0
37
Yet Another PDE (1)
 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝑔𝑑 exp π‘₯π‘₯ + π‘₯2 𝛼 + 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑 +
𝑏𝑏 exp π‘₯π‘₯ + π‘₯2
𝛼 𝑔 exp π‘₯π‘₯ + π‘₯2
𝛼 𝛽 + 2π‘₯π‘₯ +
1
2
πœ‚2 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯ 2 + 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 2𝛼 βˆ’
𝛾
2 π›Ύβˆ’1
𝑏
πœ‚
𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 + πœ‚πœ‚ exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯
2
= 0
 Divide by g exp π‘₯π‘₯ + π‘₯2
𝛼 exp π‘₯π‘₯ + π‘₯2
𝛼 .
 𝑔𝑑 + 𝑔 π‘₯𝛽𝑑 + π‘₯2
𝛼 𝑑 + 𝑏𝑏 𝛽 + 2π‘₯π‘₯ +
1
2
πœ‚2
𝑔 𝛽 + 2π‘₯π‘₯ 2
+ 𝑔 2𝛼 βˆ’
𝛾
2 π›Ύβˆ’1
𝑔
𝑏
πœ‚
+ πœ‚ 𝛽 + 2π‘₯π‘₯
2
= 0
 𝑔𝑑 + 𝑔 π‘₯𝛽𝑑 + π‘₯2
𝛼 𝑑 + 𝑏𝑏 𝛽 + 2π‘₯π‘₯ +
1
2
πœ‚2
𝑔 𝛽 + 2π‘₯π‘₯ 2
+ πœ‚2
𝑔𝑔 βˆ’
𝛾
2 π›Ύβˆ’1
𝑔
𝑏
πœ‚
+ πœ‚ 𝛽 + 2π‘₯π‘₯
2
= 0
38
Yet Another PDE (2)
 πœ† =
𝛾
2 π›Ύβˆ’1
 𝑔𝑑 + 𝑔 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑 + 𝑏𝑏 𝛽 + 2π‘₯π‘₯ +
1
2
πœ‚2 𝑔 𝛽 + 2π‘₯π‘₯ 2 + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘”
𝑏
πœ‚
+ πœ‚ 𝛽 + 2π‘₯π‘₯
2
= 0
39
Expansion in π‘₯
 𝑔𝑑 + 𝑔𝑔𝛽𝑑 + 𝑔π‘₯2
𝛼 𝑑 + 𝑏𝑏𝛽 + 2π‘₯π‘₯𝑏𝑏 +
1
2
πœ‚2
𝑔 𝛽2
+ 4π‘₯2
𝛼2
+ 4π‘₯π‘₯π‘₯ + πœ‚2
𝑔𝑔 βˆ’
πœ†π‘”
𝑏2
πœ‚2 + πœ‚2
𝛽2
+ 4πœ‚2
π‘₯2
𝛼2
+ 2𝑏𝑏 + 4𝑏𝑏𝑏 + 4πœ‚2
π‘₯π‘₯π‘₯ = 0
 𝑔𝑑 + 𝑔𝑔𝛽𝑑 + 𝑔π‘₯2
𝛼 𝑑 + π‘˜ πœƒ βˆ’ π‘₯ 𝑔𝛽 + 2π‘₯π‘₯π‘˜ πœƒ βˆ’ π‘₯ 𝑔 +
1
2
πœ‚2 𝑔 𝛽2 + 4π‘₯2 𝛼2 + 4π‘₯π‘₯π‘₯ + πœ‚2 𝑔𝑔 βˆ’
πœ†π‘”
π‘˜2 πœƒβˆ’π‘₯ 2
πœ‚2 + πœ‚2
𝛽2
+ 4πœ‚2
π‘₯2
𝛼2
+ 2π‘˜ πœƒ βˆ’ π‘₯ 𝛽 + 4π‘˜ πœƒ βˆ’ π‘₯ π‘₯π‘₯ + 4πœ‚2
π‘₯π‘₯π‘₯ = 0
 𝑔𝑑 + 𝑔𝑔𝛽𝑑 + 𝑔π‘₯2
𝛼 𝑑 + π‘˜π‘˜π›½π›½ βˆ’ π‘˜π‘˜π›½π‘₯ + 2π‘₯π‘₯π‘˜π‘˜πœƒ βˆ’ 2π›Όπ‘˜π‘˜π‘₯2
+
1
2
πœ‚2
𝑔𝛽2
+
2πœ‚2
𝑔π‘₯2
𝛼2
+ 2πœ‚2
𝑔𝑔𝑔𝑔 + πœ‚2
𝑔𝑔 βˆ’
πœ†π‘”
πœ‚2 π‘˜2
πœƒ2
+ 2
πœ†π‘”
πœ‚2 π‘˜2
πœƒπ‘₯ βˆ’
πœ†π‘”
πœ‚2 π‘˜2
π‘₯2
βˆ’ πœ†π‘”πœ‚2
𝛽2
βˆ’
4πœ†π‘”πœ‚2
π‘₯2
𝛼2
βˆ’ 2πœ†π‘”π‘”π›½π›½ + 2πœ†π‘”π‘”π›½π‘₯ βˆ’ 4πœ†π‘”π‘”πœƒπœƒπœƒ + 4πœ†π‘”π‘”π‘₯2
𝛼 βˆ’ 4πœ†π‘”πœ‚2
π‘₯π‘₯π‘₯ = 0
40
Grouping in π‘₯
 𝑔𝑑 + π‘˜π‘˜π›½π›½ +
1
2
πœ‚2
𝑔𝛽2
+ πœ‚2
𝑔𝑔 βˆ’
πœ†π‘”
πœ‚2 π‘˜2
πœƒ2
βˆ’ πœ†π‘”πœ‚2
𝛽2
βˆ’ 2πœ†π‘”π‘”π›½π›½ +
𝑔𝛽𝑑 βˆ’ π‘˜π‘˜π›½ + 2π›Όπ‘˜π‘˜πœƒ + 2πœ‚2
𝑔𝑔𝑔 + 2
πœ†π‘”
πœ‚2 π‘˜2
πœƒ + 2πœ†π‘”π‘”π›½ βˆ’ 4πœ†π‘”π‘”πœƒπœƒ βˆ’ 4πœ†π‘”πœ‚2
𝛼𝛼 π‘₯ +
𝑔𝛼 𝑑 βˆ’ 2π›Όπ‘˜π‘˜ + 2πœ‚2
𝑔𝛼2
βˆ’
πœ†π‘”
πœ‚2 π‘˜2
βˆ’ 4πœ†π‘”πœ‚2
𝛼2
+ 4πœ†π‘”π‘”π›Ό π‘₯2
= 0
41
The Three PDE’s (1)
 𝑔𝛼 𝑑 βˆ’ 2π›Όπ‘˜π‘˜ + 2πœ‚2
𝑔𝛼2
βˆ’
πœ†π‘”
πœ‚2 π‘˜2
βˆ’ 4πœ†π‘”πœ‚2
𝛼2
+ 4πœ†π‘”π‘”π›Ό =
0
 𝑔𝛽𝑑 βˆ’ π‘˜π‘˜π›½ + 2π›Όπ‘˜π‘˜πœƒ + 2πœ‚2 𝑔𝑔𝑔 + 2
πœ†π‘”
πœ‚2 π‘˜2 πœƒ + 2πœ†π‘”π‘”π›½ βˆ’
4πœ†π‘”π‘”πœƒπœƒ βˆ’ 4πœ†π‘”πœ‚2
𝛼𝛼 = 0
 𝑔𝑑 + π‘˜π‘˜π›½π›½ +
1
2
πœ‚2
𝑔𝛽2
+ πœ‚2
𝑔𝑔 βˆ’
πœ†π‘”
πœ‚2 π‘˜2
πœƒ2
βˆ’ πœ†π‘”πœ‚2
𝛽2
βˆ’
2πœ†π‘”π‘”π›½π›½ = 0
42
PDE in 𝛼
 𝛼 𝑑 + 2πœ‚2
βˆ’ 4πœ†πœ†2
𝛼2
+ 4πœ†π‘˜ βˆ’ 2π‘˜ 𝛼 βˆ’
πœ†
πœ‚2 π‘˜2
= 0
 𝛼 𝑑 =
πœ†
πœ‚2 π‘˜2
+ 2π‘˜ 1 βˆ’ 2πœ† 𝛼 + 2πœ‚2
2πœ† βˆ’ 1 𝛼2
43
PDE in 𝛽, 𝛼
 𝛽𝑑 βˆ’ π‘˜π›½ + 2πœ‚2
𝛼𝛼 + 2πœ†π‘˜π›½ βˆ’ 4πœ†πœ†2
𝛼𝛼 βˆ’ 4πœ†π‘˜πœƒπœƒ +
2
πœ†
πœ‚2 π‘˜2
πœƒ + 2π›Όπ‘˜πœƒ = 0
 𝛽𝑑 =
π‘˜ βˆ’ 2πœ‚2 𝛼 βˆ’ 2πœ†π‘˜ + 4πœ†πœ†2 𝛼 𝛽 +
4πœ†π‘˜πœƒπœƒ βˆ’ 2
πœ†
πœ‚2 π‘˜2 πœƒ βˆ’ 2π›Όπ‘˜πœƒ
44
PDE in 𝛽, 𝛼, 𝑔
 𝑔𝑑 + π‘˜π‘˜π›½π›½ +
1
2
πœ‚2
𝑔𝛽2
+ πœ‚2
𝑔𝑔 βˆ’
πœ†π‘”
πœ‚2 π‘˜2
πœƒ2
βˆ’ πœ†π‘”πœ‚2
𝛽2
βˆ’
2πœ†π‘”π‘”π›½π›½ = 0
 𝑔𝑑 = βˆ’π‘˜π‘˜π›½π›½ βˆ’
1
2
πœ‚2 𝑔𝛽2 βˆ’ πœ‚2 𝑔𝑔 +
πœ†π‘”
πœ‚2 π‘˜2 πœƒ2 + πœ†π‘”πœ‚2 𝛽2 +
2πœ†π‘”π‘”π›½π›½
 𝑔𝑑 =
𝑔 βˆ’π‘˜π›½π›½ βˆ’
1
2
πœ‚2
𝛽2
βˆ’ πœ‚2
𝛼 +
πœ†
πœ‚2 π‘˜2
πœƒ2
+ πœ†πœ†2
𝛽2
+ 2πœ†π‘˜π›½π›½
45
Riccati Equation
 A Riccati equation is any ordinary differential equation
that is quadratic in the unknown function.
 𝛼 𝑑 =
πœ†
πœ‚2 π‘˜2
+ 2π‘˜ 1 βˆ’ 2πœ† 𝛼 + 2πœ‚2
2πœ† βˆ’ 1 𝛼2
 𝛼 𝑑 = 𝐴0 + 𝐴1 𝛼 + 𝐴2 𝛼2
46
Solving a Riccati Equation by Integration
 Suppose a particular solution, 𝛼1, can be found.
 𝛼 = 𝛼1 +
1
𝑧
is the general solution, subject to some
boundary condition.
47
Particular Solution
 Either 𝛼1 or 𝛼2 is a particular solution to the ODE.
This can be verified by mere substitution.
 𝛼1,2 =
βˆ’π΄1Β± 𝐴1
2
βˆ’4𝐴2 𝐴0
2𝐴2
48
𝑧 Substitution
 Suppose 𝛼 = 𝛼1 +
1
𝑧
.

1
𝑧
Μ‡
= 𝐴0 + 𝐴1 𝛼1 +
1
𝑧
+ 𝐴2 𝛼1 +
1
𝑧
2
 = 𝐴0 + 𝐴1 𝛼1 + 𝐴1
1
𝑧
+ 𝐴2 𝛼1
2
+ 𝐴2
1
𝑧2 + 2𝐴2
𝛼1
𝑧
 = 𝐴0 + 𝐴1 𝛼1 + 𝐴1
1
𝑧
+ 𝐴2 𝛼1
2
+ 𝐴2
1
𝑧2 + 2𝐴2
𝛼1
𝑧
 = 𝐴0 + 𝐴1 𝛼1 + 𝐴2 𝛼1
2
+
𝐴1+2𝛼1 𝐴2
𝑧
+
𝐴2
𝑧2
goes to 0 by the definition of 𝛼1
49
Solving 𝑧

1
𝑧
Μ‡
=
𝐴1+2𝛼1 𝐴2
𝑧
+
𝐴2
𝑧2
 βˆ’
1
𝑧2 𝑧̇ =
𝐴1+2𝛼1 𝐴2
𝑧
+
𝐴2
𝑧2
 1st order linear ODE
 𝑧̇ + 𝐴1 + 2𝛼1 𝐴2 𝑧 = βˆ’π΄2
 𝑧 𝑑 =
βˆ’π΄2
𝐴1+2𝛼1 𝐴2
+ 𝐢exp βˆ’ 𝐴1 + 2𝛼1 𝐴2 𝑑
50
Solving for 𝛼
 𝛼 = 𝛼1 +
1
βˆ’π΄2
𝐴1+2𝛼1 𝐴2
+𝐢expβˆ’ 𝐴1+2𝛼1 𝐴2 𝑑
 boundary condition:
 𝛼 𝑇 = 0
 𝛼1 +
1
βˆ’π΄2
𝐴1+2𝛼1 𝐴2
+𝐢expβˆ’ 𝐴1+2𝛼1 𝐴2 𝑇
= 0
 𝐢exp βˆ’ 𝐴1 + 2𝛼1 𝐴2 𝑇 = βˆ’
1
𝛼1
+
𝐴2
𝐴1+2𝛼1 𝐴2
 𝐢 = exp 𝐴1 + 2𝛼1 𝐴2 𝑇
𝐴2
𝐴1+2𝛼1 𝐴2
βˆ’
1
𝛼1
51
𝛼 Solution (1)
 𝛼 = 𝛼1 +
1
βˆ’π΄2
𝐴1+2𝛼1 𝐴2
+𝐢expβˆ’ 𝐴1+2𝛼1 𝐴2 𝑑
 =
𝛼1 +
1
βˆ’π΄2
𝐴1+2𝛼1 𝐴2
+exp 𝐴1+2𝛼1 𝐴2 𝑇
𝐴2
𝐴1+2𝛼1 𝐴2
βˆ’
1
𝛼1
exp βˆ’ 𝐴1+2𝛼1 𝐴2 𝑑
 = 𝛼1 +
1
βˆ’π΄2
𝐴1+2𝛼1 𝐴2
+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘
𝐴2
𝐴1+2𝛼1 𝐴2
βˆ’
1
𝛼1
 = 𝛼1 +
𝛼1 𝐴1+2𝛼1 𝐴2
βˆ’π›Ό1 𝐴2+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ 𝛼1 𝐴2βˆ’π΄1βˆ’2𝛼1 𝐴2
52
𝛼 Solution (2)
 𝛼 = 𝛼1 +
𝛼1 𝐴1+2𝛼1 𝐴2
βˆ’π›Ό1 𝐴2+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ βˆ’π΄1βˆ’π›Ό1 𝐴2
 = 𝛼1 1 βˆ’
𝐴1+2𝛼1 𝐴2
𝐴2+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘
𝐴1
𝛼1
+𝐴2
 = 𝛼1 1 βˆ’
𝐴1
𝐴2
+2𝛼1
1+
𝐴1
𝛼1 𝐴2
+1 exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘
53
𝛼 Solution (3)
 𝛼 𝑑 =
π‘˜
2πœ‚2 1 βˆ’ 1 βˆ’ 𝛾 +
2 1βˆ’π›Ύ
1+ 1βˆ’
2
1βˆ’ 1βˆ’π›Ύ
exp 2π‘˜
1βˆ’π›Ύ
π‘‡βˆ’π‘‘
54
Solving 𝛽
 𝛽𝑑 = π‘˜ βˆ’ 2πœ‚2
𝛼 βˆ’ 2πœ†π‘˜ + 4πœ†πœ†2
𝛼 𝛽 + 4πœ†π‘˜πœƒπœƒ βˆ’ 2
πœ†
πœ‚2 π‘˜2
πœƒ βˆ’ 2π›Όπ‘˜πœƒ
 Let 𝜏 = 𝑇 βˆ’ 𝑑
 𝛽̂ 𝜏 = 𝛽 𝑇 βˆ’ 𝑑
 𝛽̂ 𝜏 𝜏 = βˆ’π›½π‘‘ 𝜏
 βˆ’π›½Μ‚ 𝜏 𝜏 = 𝛽𝑑 𝜏 = π‘˜ βˆ’ 2πœ‚2
𝛼 𝜏 βˆ’ 2πœ†π‘˜ + 4πœ†πœ†2
𝛼 𝜏 𝛽 𝜏 +
4πœ†π‘˜πœƒπœƒ 𝜏 βˆ’ 2
πœ†
πœ‚2 π‘˜2 πœƒ βˆ’ 2𝛼 𝜏 π‘˜πœƒ
 𝛽̂ 𝜏 𝜏 =
βˆ’π‘˜ + 2πœ‚2
𝛼� + 2πœ†π‘˜ βˆ’ 4πœ†πœ†2
𝛼� 𝛽̂ + βˆ’4πœ†π‘˜πœƒπ›ΌοΏ½ + 2
πœ†
πœ‚2 π‘˜2
πœƒ + 2π›ΌοΏ½π‘˜πœƒ
 𝛽̂ 𝜏 𝜏 =
2πœ† βˆ’ 1 π‘˜ + 2πœ‚2
𝛼� 1 βˆ’ 2πœ† 𝛽̂ + 2π›ΌοΏ½π‘˜πœƒ 1 βˆ’ 2πœ† + 2
πœ†
πœ‚2 π‘˜2
πœƒ
55
First Order Non-Constant Coefficients
 𝛽̂ 𝜏 = 𝐡1 𝛽̂ + 𝐡2
 𝐡1 𝜏 = 2πœ† βˆ’ 1 π‘˜ + 2πœ‚2
𝛼� 1 βˆ’ 2πœ†
 𝐡2 𝜏 = 2π›ΌοΏ½π‘˜πœƒ 1 βˆ’ 2πœ† + 2
πœ†
πœ‚2 π‘˜2 πœƒ
56
Integrating Factor (1)
 𝛽̂ 𝜏 βˆ’ 𝐡1 𝛽̂ = 𝐡2
 We try to find an integrating factor πœ‡ = πœ‡ 𝜏 s.t.

𝑑
π‘‘πœ
πœ‡π›½Μ‚ = πœ‡
𝑑𝛽�
π‘‘πœ
+ 𝛽̂ π‘‘πœ‡
π‘‘πœ
= πœ‡π΅2
 Divide LHS and RHS by πœ‡π›½Μ‚.

1
𝛽�
𝑑𝛽�
𝑑𝑑
+
1
πœ‡
π‘‘πœ‡
π‘‘πœ
=
𝐡2
𝛽�
 By comparison,
 βˆ’π΅1 =
1
πœ‡
π‘‘πœ‡
π‘‘πœ
57
Integrating Factor (2)
 ∫ βˆ’π΅1 π‘‘πœ = ∫
π‘‘πœ‡
πœ‡
= log πœ‡ + 𝐢
 πœ‡ = exp ∫ βˆ’π΅1 π‘‘πœ
 πœ‡π›½Μ‚ = ∫ πœ‡π΅2 π‘‘πœ + 𝐢
 𝛽̂ =
∫ πœ‡π΅2 π‘‘πœ+𝐢
πœ‡
 𝛽̂ =
∫ exp ∫ βˆ’π΅1 𝑑𝑒 𝐡2 π‘‘πœ+𝐢
exp ∫ βˆ’π΅1 π‘‘πœ
58
𝛽̂ Solution
 𝛽̂ =
∫ exp ∫ βˆ’π΅1 𝑒 𝑑𝑑
𝜏
0
𝐡2 𝑠 𝑑𝑠
𝜏
0
exp ∫ βˆ’π΅1 𝑒 𝑑𝑒
𝜏
0
+ 𝐢
 𝛽̂ 𝜏 =
exp ∫ 𝐡1 𝑒 𝑑𝑑
𝜏
0 ∫ exp ∫ βˆ’π΅1 𝑒 𝑑𝑑
𝑠
0
𝐡2 𝑠 𝑑𝑑
𝜏
0
+ 𝐢
59
𝐡1, 𝐡2
 ∫ 𝐡1 𝑠 𝑑𝑑
𝜏
0
= ∫ 2πœ† βˆ’ 1 π‘˜ + 2πœ‚2
1 βˆ’ 2πœ† 𝛼 𝑠 𝑑𝑑
𝜏
0
 𝐼2 = ∫ exp ∫ βˆ’π΅1 𝑒 𝑑𝑑
𝑠
0
𝐡2 𝑠 𝑑𝑑
𝜏
0
60
𝛽 Solution
 𝛽 𝑑 =
π‘˜πœƒ
πœ‚2 1 + 1 βˆ’ 𝛾
exp 2π‘˜
1βˆ’π›Ύ
π‘‡βˆ’π‘‘ βˆ’1
1+ 1βˆ’
2
1βˆ’ 1βˆ’π›Ύ
exp 2π‘˜
1βˆ’π›Ύ
π‘‡βˆ’π‘‘
61
Solving 𝑔
 𝑔𝑑 =
𝑔 βˆ’π‘˜π›½π›½ βˆ’
1
2
πœ‚2
𝛽2
βˆ’ πœ‚2
𝛼 +
πœ†
πœ‚2 π‘˜2
πœƒ2
+ πœ†πœ†2
𝛽2
+ 2πœ†π‘˜π›½π›½
 With𝛼 and 𝛽 solved, we are now ready to solve 𝑔𝑑.

𝑔 𝑑
𝑔
= 𝐺 𝑑

𝑑
𝑑𝑠
log 𝑔𝑑 =
𝑔 𝑑
𝑔
= 𝐺
 log 𝑔𝑑 = ∫ 𝐺𝐺𝐺 + 𝐢
 𝑔𝑑 = 𝐢exp ∫ 𝐺𝑑𝑑 = exp βˆ’ ∫ 𝐺𝐺𝐺
𝑇
0
exp ∫ 𝐺𝐺𝐺
𝑑
0
 𝑔𝑑 = exp βˆ’ ∫ 𝐺𝐺𝐺
𝑇
𝑑
62
Computing the Optimal Position
 β„Ž 𝑑 βˆ— = βˆ’
𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2
𝐺 𝑉𝑉 πœ‚2
 = βˆ’
𝛾𝑉 π›Ύβˆ’1 𝑓 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝛾𝑉 π›Ύβˆ’1 𝑓π‘₯ πœ‚2
𝛾 π›Ύβˆ’1 𝑉 π›Ύβˆ’2 π‘“πœ‚2
 = βˆ’
𝑉𝑓 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝑉𝑓π‘₯ πœ‚2
π›Ύβˆ’1 π‘“πœ‚2
 = βˆ’
𝑉
π›Ύβˆ’1 πœ‚2
𝑓 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝑓π‘₯ πœ‚2
𝑓
 = βˆ’
𝑉
π›Ύβˆ’1 πœ‚2 π‘˜ πœƒ βˆ’ π‘₯𝑑 +
𝑓π‘₯
𝑓
πœ‚2
 =
𝑉
1βˆ’π›Ύ πœ‚2 π‘˜ πœƒ βˆ’ π‘₯𝑑 + πœ‚2 𝛽 + 2𝛼𝛼
 =
𝑉
1βˆ’π›Ύ
βˆ’
π‘˜
πœ‚2 π‘₯𝑑 βˆ’ πœƒ + 2𝛼𝛼 + 𝛽
63
The Optimal Position
 β„Ž 𝑑 βˆ—
=
𝑉𝑑
1βˆ’π›Ύ
βˆ’
π‘˜
πœ‚2 π‘₯ 𝑑 βˆ’ πœƒ + 2𝛼 𝑑 π‘₯ 𝑑 + 𝛽 𝑑
 β„Ž 𝑑 βˆ—~ βˆ’
π‘˜
πœ‚2 π‘₯ 𝑑 βˆ’ πœƒ
64
P&L for Simulated Data
 The portfolio increases from $1000 to $4625 in one year.
65
Parameter Estimation
 Can be done using Maximum Likelihood.
 Evaluation of parameter sensitivity can be done by
Monte Carlo simulation.
 In real trading, it is better to be conservative about the
parameters.
 Better underestimate the mean-reverting speed
 Better overestimate the noise
 To account for parameter regime changes, we can use:
 a hidden Markov chain model
 moving calibration window
66
Trend Following Trading
67
Two-State Markov Model
68
 π‘‘π‘†π‘Ÿ = π‘†π‘Ÿ πœ‡ 𝛼 π‘Ÿ 𝑑𝑑 + πœŽπœŽπ΅π‘Ÿ
𝛼 π‘Ÿ = 0
DOWN
TREND
𝛼 π‘Ÿ = 1
UP TREND
q p
1-q
1-p
Buying and Selling Decisions
69
 𝑑 ≀ 𝜏1
0
≀ 𝜈1
0
≀ 𝜏2
0
≀ 𝜈2
0
≀ β‹― ≀ 𝜏 𝑛
0 ≀ 𝜈 𝑛
0 ≀ β‹― ≀ 𝑇
Optimal Trend Following Strategy
70
Trading SSE 2001 – 2011
71

More Related Content

What's hot

On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...
On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...
On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...IJMER
Β 
ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©
ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©
ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©MohammedRazzaqSalman
Β 
Solving Poisson Equation using Conjugate Gradient Method and its implementation
Solving Poisson Equation using Conjugate Gradient Methodand its implementationSolving Poisson Equation using Conjugate Gradient Methodand its implementation
Solving Poisson Equation using Conjugate Gradient Method and its implementationJongsu "Liam" Kim
Β 
Intro to Quant Trading Strategies (Lecture 6 of 10)
Intro to Quant Trading Strategies (Lecture 6 of 10)Intro to Quant Trading Strategies (Lecture 6 of 10)
Intro to Quant Trading Strategies (Lecture 6 of 10)Adrian Aley
Β 
A05330107
A05330107A05330107
A05330107IOSR-JEN
Β 
Ejercicios resueltos de analisis matematico 1
Ejercicios resueltos de analisis matematico 1Ejercicios resueltos de analisis matematico 1
Ejercicios resueltos de analisis matematico 1tinardo
Β 
Intro to Quant Trading Strategies (Lecture 7 of 10)
Intro to Quant Trading Strategies (Lecture 7 of 10)Intro to Quant Trading Strategies (Lecture 7 of 10)
Intro to Quant Trading Strategies (Lecture 7 of 10)Adrian Aley
Β 
B.tech ii unit-2 material beta gamma function
B.tech ii unit-2 material beta gamma functionB.tech ii unit-2 material beta gamma function
B.tech ii unit-2 material beta gamma functionRai University
Β 
Lecture 5 backpropagation
Lecture 5 backpropagationLecture 5 backpropagation
Lecture 5 backpropagationParveenMalik18
Β 
Gamma beta functions-1
Gamma   beta functions-1Gamma   beta functions-1
Gamma beta functions-1Selvaraj John
Β 
Fdocuments.in sugeno style-fuzzy-inference
Fdocuments.in sugeno style-fuzzy-inferenceFdocuments.in sugeno style-fuzzy-inference
Fdocuments.in sugeno style-fuzzy-inferenceSudhansuPanda15
Β 
A brief introduction to finite difference method
A brief introduction to finite difference methodA brief introduction to finite difference method
A brief introduction to finite difference methodPrateek Jha
Β 
Study Material Numerical Solution of Odinary Differential Equations
Study Material Numerical Solution of Odinary Differential EquationsStudy Material Numerical Solution of Odinary Differential Equations
Study Material Numerical Solution of Odinary Differential EquationsMeenakshisundaram N
Β 
Stochastic optimal control &amp; rl
Stochastic optimal control &amp; rlStochastic optimal control &amp; rl
Stochastic optimal control &amp; rlChoiJinwon3
Β 
Lecture 2 fuzzy inference system
Lecture 2  fuzzy inference systemLecture 2  fuzzy inference system
Lecture 2 fuzzy inference systemParveenMalik18
Β 
A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...
A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...
A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...IJRES Journal
Β 
Backpropagation: Understanding How to Update ANNs Weights Step-by-Step
Backpropagation: Understanding How to Update ANNs Weights Step-by-StepBackpropagation: Understanding How to Update ANNs Weights Step-by-Step
Backpropagation: Understanding How to Update ANNs Weights Step-by-StepAhmed Gad
Β 
Machine Learning - Reinforcement Learning
Machine Learning - Reinforcement LearningMachine Learning - Reinforcement Learning
Machine Learning - Reinforcement LearningJY Chun
Β 

What's hot (20)

On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...
On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...
On ranges and null spaces of a special type of operator named 𝝀 βˆ’ π’‹π’†π’„π’•π’Šπ’π’. – ...
Β 
ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©
ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©
ΨͺΨ·Ψ¨ΩŠΩ‚Ψ§Ψͺ Ψ§Ω„Ω…ΨΉΨ§Ψ―Ω„Ψ§Ψͺ Ψ§Ω„ΨͺΩΨ§ΨΆΩ„ΩŠΨ©
Β 
Solving Poisson Equation using Conjugate Gradient Method and its implementation
Solving Poisson Equation using Conjugate Gradient Methodand its implementationSolving Poisson Equation using Conjugate Gradient Methodand its implementation
Solving Poisson Equation using Conjugate Gradient Method and its implementation
Β 
Intro to Quant Trading Strategies (Lecture 6 of 10)
Intro to Quant Trading Strategies (Lecture 6 of 10)Intro to Quant Trading Strategies (Lecture 6 of 10)
Intro to Quant Trading Strategies (Lecture 6 of 10)
Β 
A05330107
A05330107A05330107
A05330107
Β 
Ejercicios resueltos de analisis matematico 1
Ejercicios resueltos de analisis matematico 1Ejercicios resueltos de analisis matematico 1
Ejercicios resueltos de analisis matematico 1
Β 
Intro to Quant Trading Strategies (Lecture 7 of 10)
Intro to Quant Trading Strategies (Lecture 7 of 10)Intro to Quant Trading Strategies (Lecture 7 of 10)
Intro to Quant Trading Strategies (Lecture 7 of 10)
Β 
B.tech ii unit-2 material beta gamma function
B.tech ii unit-2 material beta gamma functionB.tech ii unit-2 material beta gamma function
B.tech ii unit-2 material beta gamma function
Β 
Lecture 5 backpropagation
Lecture 5 backpropagationLecture 5 backpropagation
Lecture 5 backpropagation
Β 
Gamma beta functions-1
Gamma   beta functions-1Gamma   beta functions-1
Gamma beta functions-1
Β 
Fdocuments.in sugeno style-fuzzy-inference
Fdocuments.in sugeno style-fuzzy-inferenceFdocuments.in sugeno style-fuzzy-inference
Fdocuments.in sugeno style-fuzzy-inference
Β 
285 294
285 294285 294
285 294
Β 
A brief introduction to finite difference method
A brief introduction to finite difference methodA brief introduction to finite difference method
A brief introduction to finite difference method
Β 
Study Material Numerical Solution of Odinary Differential Equations
Study Material Numerical Solution of Odinary Differential EquationsStudy Material Numerical Solution of Odinary Differential Equations
Study Material Numerical Solution of Odinary Differential Equations
Β 
Stochastic optimal control &amp; rl
Stochastic optimal control &amp; rlStochastic optimal control &amp; rl
Stochastic optimal control &amp; rl
Β 
Lecture 2 fuzzy inference system
Lecture 2  fuzzy inference systemLecture 2  fuzzy inference system
Lecture 2 fuzzy inference system
Β 
Restricted boltzmann machine
Restricted boltzmann machineRestricted boltzmann machine
Restricted boltzmann machine
Β 
A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...
A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...
A Mathematical Model for the Enhancement of Stress Induced Hypoglycaemia by A...
Β 
Backpropagation: Understanding How to Update ANNs Weights Step-by-Step
Backpropagation: Understanding How to Update ANNs Weights Step-by-StepBackpropagation: Understanding How to Update ANNs Weights Step-by-Step
Backpropagation: Understanding How to Update ANNs Weights Step-by-Step
Β 
Machine Learning - Reinforcement Learning
Machine Learning - Reinforcement LearningMachine Learning - Reinforcement Learning
Machine Learning - Reinforcement Learning
Β 

Similar to Intro to Quantitative Investment (Lecture 4 of 6)

Intro to Quant Trading Strategies (Lecture 3 of 10)
Intro to Quant Trading Strategies (Lecture 3 of 10)Intro to Quant Trading Strategies (Lecture 3 of 10)
Intro to Quant Trading Strategies (Lecture 3 of 10)Adrian Aley
Β 
BSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICS
BSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICSBSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICS
BSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICSRai University
Β 
Semana 16 desigualdades ii Γ‘lgebra-uni ccesa007
Semana 16   desigualdades  ii   Γ‘lgebra-uni ccesa007Semana 16   desigualdades  ii   Γ‘lgebra-uni ccesa007
Semana 16 desigualdades ii Γ‘lgebra-uni ccesa007Demetrio Ccesa Rayme
Β 
Semana 07 division de polinomios i Γ‘lgebra-uni ccesa007
Semana 07   division de polinomios i Γ‘lgebra-uni ccesa007Semana 07   division de polinomios i Γ‘lgebra-uni ccesa007
Semana 07 division de polinomios i Γ‘lgebra-uni ccesa007Demetrio Ccesa Rayme
Β 
Antiderivatives: Power, Sum and Difference
Antiderivatives: Power, Sum and DifferenceAntiderivatives: Power, Sum and Difference
Antiderivatives: Power, Sum and DifferenceRivenBarquilla
Β 
Semana 26 logaritmos Γ‘lgebra uni ccesa007
Semana 26 logaritmos Γ‘lgebra uni ccesa007Semana 26 logaritmos Γ‘lgebra uni ccesa007
Semana 26 logaritmos Γ‘lgebra uni ccesa007Demetrio Ccesa Rayme
Β 
Btech_II_ engineering mathematics_unit2
Btech_II_ engineering mathematics_unit2Btech_II_ engineering mathematics_unit2
Btech_II_ engineering mathematics_unit2Rai University
Β 
Differentiation (Part 1).pptx
Differentiation (Part 1).pptxDifferentiation (Part 1).pptx
Differentiation (Part 1).pptxSakibAhmed402053
Β 
Semana 24 funciones iv Γ‘lgebra uni ccesa007
Semana 24 funciones iv Γ‘lgebra uni ccesa007Semana 24 funciones iv Γ‘lgebra uni ccesa007
Semana 24 funciones iv Γ‘lgebra uni ccesa007Demetrio Ccesa Rayme
Β 
Engineering Analysis -Third Class.ppsx
Engineering Analysis -Third Class.ppsxEngineering Analysis -Third Class.ppsx
Engineering Analysis -Third Class.ppsxHebaEng
Β 
MAT 230 CH 7 Notes 7.4 (1).pptx
MAT 230 CH 7 Notes 7.4 (1).pptxMAT 230 CH 7 Notes 7.4 (1).pptx
MAT 230 CH 7 Notes 7.4 (1).pptxMarkVincentDoria1
Β 
Semana 11 numeros complejos ii Γ‘lgebra-uni ccesa007
Semana 11   numeros complejos ii   Γ‘lgebra-uni ccesa007Semana 11   numeros complejos ii   Γ‘lgebra-uni ccesa007
Semana 11 numeros complejos ii Γ‘lgebra-uni ccesa007Demetrio Ccesa Rayme
Β 
Functions ppt Dr Frost Maths Mixed questions
Functions ppt Dr Frost Maths Mixed questionsFunctions ppt Dr Frost Maths Mixed questions
Functions ppt Dr Frost Maths Mixed questionsgcutbill
Β 
Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...
Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...
Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...IOSRJM
Β 
Piii taller transformaciones lineales
Piii taller transformaciones linealesPiii taller transformaciones lineales
Piii taller transformaciones linealesJHANDRYALCIVARGUAJAL
Β 
UNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptx
UNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptxUNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptx
UNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptxbestmorfingamer
Β 
Operation of functions and Composite function.pdf
Operation of functions and Composite function.pdfOperation of functions and Composite function.pdf
Operation of functions and Composite function.pdfSerGeo5
Β 
Reducible equation to quadratic form
Reducible equation to quadratic formReducible equation to quadratic form
Reducible equation to quadratic formMahrukhShehzadi1
Β 

Similar to Intro to Quantitative Investment (Lecture 4 of 6) (20)

Intro to Quant Trading Strategies (Lecture 3 of 10)
Intro to Quant Trading Strategies (Lecture 3 of 10)Intro to Quant Trading Strategies (Lecture 3 of 10)
Intro to Quant Trading Strategies (Lecture 3 of 10)
Β 
BSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICS
BSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICSBSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICS
BSC_COMPUTER _SCIENCE_UNIT-2_DISCRETE MATHEMATICS
Β 
Semana 16 desigualdades ii Γ‘lgebra-uni ccesa007
Semana 16   desigualdades  ii   Γ‘lgebra-uni ccesa007Semana 16   desigualdades  ii   Γ‘lgebra-uni ccesa007
Semana 16 desigualdades ii Γ‘lgebra-uni ccesa007
Β 
Semana 07 division de polinomios i Γ‘lgebra-uni ccesa007
Semana 07   division de polinomios i Γ‘lgebra-uni ccesa007Semana 07   division de polinomios i Γ‘lgebra-uni ccesa007
Semana 07 division de polinomios i Γ‘lgebra-uni ccesa007
Β 
Antiderivatives: Power, Sum and Difference
Antiderivatives: Power, Sum and DifferenceAntiderivatives: Power, Sum and Difference
Antiderivatives: Power, Sum and Difference
Β 
Semana 26 logaritmos Γ‘lgebra uni ccesa007
Semana 26 logaritmos Γ‘lgebra uni ccesa007Semana 26 logaritmos Γ‘lgebra uni ccesa007
Semana 26 logaritmos Γ‘lgebra uni ccesa007
Β 
Btech_II_ engineering mathematics_unit2
Btech_II_ engineering mathematics_unit2Btech_II_ engineering mathematics_unit2
Btech_II_ engineering mathematics_unit2
Β 
Differentiation (Part 1).pptx
Differentiation (Part 1).pptxDifferentiation (Part 1).pptx
Differentiation (Part 1).pptx
Β 
Semana 24 funciones iv Γ‘lgebra uni ccesa007
Semana 24 funciones iv Γ‘lgebra uni ccesa007Semana 24 funciones iv Γ‘lgebra uni ccesa007
Semana 24 funciones iv Γ‘lgebra uni ccesa007
Β 
Engineering Analysis -Third Class.ppsx
Engineering Analysis -Third Class.ppsxEngineering Analysis -Third Class.ppsx
Engineering Analysis -Third Class.ppsx
Β 
MAT 230 CH 7 Notes 7.4 (1).pptx
MAT 230 CH 7 Notes 7.4 (1).pptxMAT 230 CH 7 Notes 7.4 (1).pptx
MAT 230 CH 7 Notes 7.4 (1).pptx
Β 
Semana 11 numeros complejos ii Γ‘lgebra-uni ccesa007
Semana 11   numeros complejos ii   Γ‘lgebra-uni ccesa007Semana 11   numeros complejos ii   Γ‘lgebra-uni ccesa007
Semana 11 numeros complejos ii Γ‘lgebra-uni ccesa007
Β 
Functions ppt Dr Frost Maths Mixed questions
Functions ppt Dr Frost Maths Mixed questionsFunctions ppt Dr Frost Maths Mixed questions
Functions ppt Dr Frost Maths Mixed questions
Β 
Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...
Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...
Least Square Plane and Leastsquare Quadric Surface Approximation by Using Mod...
Β 
Piii taller transformaciones lineales
Piii taller transformaciones linealesPiii taller transformaciones lineales
Piii taller transformaciones lineales
Β 
Ch 5 integration
Ch 5 integration  Ch 5 integration
Ch 5 integration
Β 
UNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptx
UNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptxUNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptx
UNEC__1709djdjejsjdjdjsjsjsjsjΓΌjsj657487.pptx
Β 
Integral indefinida
Integral indefinidaIntegral indefinida
Integral indefinida
Β 
Operation of functions and Composite function.pdf
Operation of functions and Composite function.pdfOperation of functions and Composite function.pdf
Operation of functions and Composite function.pdf
Β 
Reducible equation to quadratic form
Reducible equation to quadratic formReducible equation to quadratic form
Reducible equation to quadratic form
Β 

More from Adrian Aley

Intro to Quant Trading Strategies (Lecture 10 of 10)
Intro to Quant Trading Strategies (Lecture 10 of 10)Intro to Quant Trading Strategies (Lecture 10 of 10)
Intro to Quant Trading Strategies (Lecture 10 of 10)Adrian Aley
Β 
Intro to Quant Trading Strategies (Lecture 9 of 10)
Intro to Quant Trading Strategies (Lecture 9 of 10)Intro to Quant Trading Strategies (Lecture 9 of 10)
Intro to Quant Trading Strategies (Lecture 9 of 10)Adrian Aley
Β 
Intro to Quant Trading Strategies (Lecture 8 of 10)
Intro to Quant Trading Strategies (Lecture 8 of 10)Intro to Quant Trading Strategies (Lecture 8 of 10)
Intro to Quant Trading Strategies (Lecture 8 of 10)Adrian Aley
Β 
Intro to Quant Trading Strategies (Lecture 4 of 10)
Intro to Quant Trading Strategies (Lecture 4 of 10)Intro to Quant Trading Strategies (Lecture 4 of 10)
Intro to Quant Trading Strategies (Lecture 4 of 10)Adrian Aley
Β 
Intro to Quant Trading Strategies (Lecture 2 of 10)
Intro to Quant Trading Strategies (Lecture 2 of 10)Intro to Quant Trading Strategies (Lecture 2 of 10)
Intro to Quant Trading Strategies (Lecture 2 of 10)Adrian Aley
Β 
Intro to Quant Trading Strategies (Lecture 1 of 10)
Intro to Quant Trading Strategies (Lecture 1 of 10)Intro to Quant Trading Strategies (Lecture 1 of 10)
Intro to Quant Trading Strategies (Lecture 1 of 10)Adrian Aley
Β 
Intro to Quantitative Investment (Lecture 6 of 6)
Intro to Quantitative Investment (Lecture 6 of 6)Intro to Quantitative Investment (Lecture 6 of 6)
Intro to Quantitative Investment (Lecture 6 of 6)Adrian Aley
Β 
Intro to Quantitative Investment (Lecture 5 of 6)
Intro to Quantitative Investment (Lecture 5 of 6)Intro to Quantitative Investment (Lecture 5 of 6)
Intro to Quantitative Investment (Lecture 5 of 6)Adrian Aley
Β 
Intro to Quantitative Investment (Lecture 3 of 6)
Intro to Quantitative Investment (Lecture 3 of 6)Intro to Quantitative Investment (Lecture 3 of 6)
Intro to Quantitative Investment (Lecture 3 of 6)Adrian Aley
Β 
Intro to Quantitative Investment (Lecture 2 of 6)
Intro to Quantitative Investment (Lecture 2 of 6)Intro to Quantitative Investment (Lecture 2 of 6)
Intro to Quantitative Investment (Lecture 2 of 6)Adrian Aley
Β 
Intro to Quantitative Investment (Lecture 1 of 6)
Intro to Quantitative Investment (Lecture 1 of 6)Intro to Quantitative Investment (Lecture 1 of 6)
Intro to Quantitative Investment (Lecture 1 of 6)Adrian Aley
Β 

More from Adrian Aley (11)

Intro to Quant Trading Strategies (Lecture 10 of 10)
Intro to Quant Trading Strategies (Lecture 10 of 10)Intro to Quant Trading Strategies (Lecture 10 of 10)
Intro to Quant Trading Strategies (Lecture 10 of 10)
Β 
Intro to Quant Trading Strategies (Lecture 9 of 10)
Intro to Quant Trading Strategies (Lecture 9 of 10)Intro to Quant Trading Strategies (Lecture 9 of 10)
Intro to Quant Trading Strategies (Lecture 9 of 10)
Β 
Intro to Quant Trading Strategies (Lecture 8 of 10)
Intro to Quant Trading Strategies (Lecture 8 of 10)Intro to Quant Trading Strategies (Lecture 8 of 10)
Intro to Quant Trading Strategies (Lecture 8 of 10)
Β 
Intro to Quant Trading Strategies (Lecture 4 of 10)
Intro to Quant Trading Strategies (Lecture 4 of 10)Intro to Quant Trading Strategies (Lecture 4 of 10)
Intro to Quant Trading Strategies (Lecture 4 of 10)
Β 
Intro to Quant Trading Strategies (Lecture 2 of 10)
Intro to Quant Trading Strategies (Lecture 2 of 10)Intro to Quant Trading Strategies (Lecture 2 of 10)
Intro to Quant Trading Strategies (Lecture 2 of 10)
Β 
Intro to Quant Trading Strategies (Lecture 1 of 10)
Intro to Quant Trading Strategies (Lecture 1 of 10)Intro to Quant Trading Strategies (Lecture 1 of 10)
Intro to Quant Trading Strategies (Lecture 1 of 10)
Β 
Intro to Quantitative Investment (Lecture 6 of 6)
Intro to Quantitative Investment (Lecture 6 of 6)Intro to Quantitative Investment (Lecture 6 of 6)
Intro to Quantitative Investment (Lecture 6 of 6)
Β 
Intro to Quantitative Investment (Lecture 5 of 6)
Intro to Quantitative Investment (Lecture 5 of 6)Intro to Quantitative Investment (Lecture 5 of 6)
Intro to Quantitative Investment (Lecture 5 of 6)
Β 
Intro to Quantitative Investment (Lecture 3 of 6)
Intro to Quantitative Investment (Lecture 3 of 6)Intro to Quantitative Investment (Lecture 3 of 6)
Intro to Quantitative Investment (Lecture 3 of 6)
Β 
Intro to Quantitative Investment (Lecture 2 of 6)
Intro to Quantitative Investment (Lecture 2 of 6)Intro to Quantitative Investment (Lecture 2 of 6)
Intro to Quantitative Investment (Lecture 2 of 6)
Β 
Intro to Quantitative Investment (Lecture 1 of 6)
Intro to Quantitative Investment (Lecture 1 of 6)Intro to Quantitative Investment (Lecture 1 of 6)
Intro to Quantitative Investment (Lecture 1 of 6)
Β 

Recently uploaded

Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...makika9823
Β 
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escortsranjana rawat
Β 
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptxFinTech Belgium
Β 
Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024Bladex
Β 
OAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptx
OAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptxOAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptx
OAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptxhiddenlevers
Β 
Call US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure serviceCall US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure servicePooja Nehwal
Β 
Instant Issue Debit Cards - School Designs
Instant Issue Debit Cards - School DesignsInstant Issue Debit Cards - School Designs
Instant Issue Debit Cards - School Designsegoetzinger
Β 
Dividend Policy and Dividend Decision Theories.pptx
Dividend Policy and Dividend Decision Theories.pptxDividend Policy and Dividend Decision Theories.pptx
Dividend Policy and Dividend Decision Theories.pptxanshikagoel52
Β 
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130Suhani Kapoor
Β 
Instant Issue Debit Cards - High School Spirit
Instant Issue Debit Cards - High School SpiritInstant Issue Debit Cards - High School Spirit
Instant Issue Debit Cards - High School Spiritegoetzinger
Β 
call girls in Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈ
call girls in  Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈcall girls in  Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈ
call girls in Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈ9953056974 Low Rate Call Girls In Saket, Delhi NCR
Β 
The Economic History of the U.S. Lecture 18.pdf
The Economic History of the U.S. Lecture 18.pdfThe Economic History of the U.S. Lecture 18.pdf
The Economic History of the U.S. Lecture 18.pdfGale Pooley
Β 
Stock Market Brief Deck for 4/24/24 .pdf
Stock Market Brief Deck for 4/24/24 .pdfStock Market Brief Deck for 4/24/24 .pdf
Stock Market Brief Deck for 4/24/24 .pdfMichael Silva
Β 
High Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
High Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsHigh Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
High Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur Escortsranjana rawat
Β 
Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...
Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...
Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...Pooja Nehwal
Β 
How Automation is Driving Efficiency Through the Last Mile of Reporting
How Automation is Driving Efficiency Through the Last Mile of ReportingHow Automation is Driving Efficiency Through the Last Mile of Reporting
How Automation is Driving Efficiency Through the Last Mile of ReportingAggregage
Β 
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptxFinTech Belgium
Β 
letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...
letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...
letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...Henry Tapper
Β 
fca-bsps-decision-letter-redacted (1).pdf
fca-bsps-decision-letter-redacted (1).pdffca-bsps-decision-letter-redacted (1).pdf
fca-bsps-decision-letter-redacted (1).pdfHenry Tapper
Β 
20240429 Calibre April 2024 Investor Presentation.pdf
20240429 Calibre April 2024 Investor Presentation.pdf20240429 Calibre April 2024 Investor Presentation.pdf
20240429 Calibre April 2024 Investor Presentation.pdfAdnet Communications
Β 

Recently uploaded (20)

Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Independent Lucknow Call Girls 8923113531WhatsApp Lucknow Call Girls make you...
Β 
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Maya Call 7001035870 Meet With Nagpur Escorts
Β 
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
05_Annelore Lenoir_Docbyte_MeetupDora&Cybersecurity.pptx
Β 
Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024Bladex Earnings Call Presentation 1Q2024
Bladex Earnings Call Presentation 1Q2024
Β 
OAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptx
OAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptxOAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptx
OAT_RI_Ep19 WeighingTheRisks_Apr24_TheYellowMetal.pptx
Β 
Call US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure serviceCall US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure service
Call US πŸ“ž 9892124323 βœ… Kurla Call Girls In Kurla ( Mumbai ) secure service
Β 
Instant Issue Debit Cards - School Designs
Instant Issue Debit Cards - School DesignsInstant Issue Debit Cards - School Designs
Instant Issue Debit Cards - School Designs
Β 
Dividend Policy and Dividend Decision Theories.pptx
Dividend Policy and Dividend Decision Theories.pptxDividend Policy and Dividend Decision Theories.pptx
Dividend Policy and Dividend Decision Theories.pptx
Β 
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
VIP Call Girls Service Dilsukhnagar Hyderabad Call +91-8250192130
Β 
Instant Issue Debit Cards - High School Spirit
Instant Issue Debit Cards - High School SpiritInstant Issue Debit Cards - High School Spirit
Instant Issue Debit Cards - High School Spirit
Β 
call girls in Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈ
call girls in  Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈcall girls in  Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈ
call girls in Nand Nagri (DELHI) πŸ” >ΰΌ’9953330565πŸ” genuine Escort Service πŸ”βœ”οΈβœ”οΈ
Β 
The Economic History of the U.S. Lecture 18.pdf
The Economic History of the U.S. Lecture 18.pdfThe Economic History of the U.S. Lecture 18.pdf
The Economic History of the U.S. Lecture 18.pdf
Β 
Stock Market Brief Deck for 4/24/24 .pdf
Stock Market Brief Deck for 4/24/24 .pdfStock Market Brief Deck for 4/24/24 .pdf
Stock Market Brief Deck for 4/24/24 .pdf
Β 
High Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
High Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsHigh Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
High Class Call Girls Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Β 
Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...
Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...
Independent Call Girl Number in Kurla MumbaiπŸ“² Pooja Nehwal 9892124323 πŸ’ž Full ...
Β 
How Automation is Driving Efficiency Through the Last Mile of Reporting
How Automation is Driving Efficiency Through the Last Mile of ReportingHow Automation is Driving Efficiency Through the Last Mile of Reporting
How Automation is Driving Efficiency Through the Last Mile of Reporting
Β 
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
02_Fabio Colombo_Accenture_MeetupDora&Cybersecurity.pptx
Β 
letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...
letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...
letter-from-the-chair-to-the-fca-relating-to-british-steel-pensions-scheme-15...
Β 
fca-bsps-decision-letter-redacted (1).pdf
fca-bsps-decision-letter-redacted (1).pdffca-bsps-decision-letter-redacted (1).pdf
fca-bsps-decision-letter-redacted (1).pdf
Β 
20240429 Calibre April 2024 Investor Presentation.pdf
20240429 Calibre April 2024 Investor Presentation.pdf20240429 Calibre April 2024 Investor Presentation.pdf
20240429 Calibre April 2024 Investor Presentation.pdf
Β 

Intro to Quantitative Investment (Lecture 4 of 6)

  • 1. Optimal Trading Strategies Stochastic Control Haksun Li haksun.li@numericalmethod.com www.numericalmethod.com
  • 2. Speaker Profile  Dr. Haksun Li  CEO, Numerical Method Inc.  (Ex-)Adjunct Professors, Industry Fellow, Advisor, Consultant with the National University of Singapore, Nanyang Technological University, Fudan University, the Hong Kong University of Science and Technology.  Quantitative Trader/Analyst, BNPP, UBS  PhD, Computer Sci, University of Michigan Ann Arbor  M.S., Financial Mathematics, University of Chicago  B.S., Mathematics, University of Chicago 2
  • 3. References  Optimal Pairs Trading: A Stochastic Control Approach. Mudchanatongsuk, S., Primbs, J.A., Wong, W. Dept. of Manage. Sci. & Eng., Stanford Univ., Stanford, CA. 2008.  Optimal Trend Following Trading Rules. Dai, M., Zhang, Q., Zhu Q. J. 2011 3
  • 5. Stochastic Control  We model the difference between the log-returns of two assets as an Ornstein-Uhlenbeck process.  We compute the optimal position to take as a function of the deviation from the equilibrium.  This is done by solving the corresponding the Hamilton-Jacobi-Bellman equation. 5
  • 6. Formulation  Assume a risk free asset 𝑀𝑑, which satisfies  𝑑𝑀𝑑 = π‘Ÿπ‘€π‘‘ 𝑑𝑑  Assume two assets,𝐴 𝑑 and 𝐡𝑑.  Assume 𝐡𝑑follows a geometric Brownian motion.  𝑑𝐡𝑑 = πœ‡π΅π‘‘ 𝑑𝑑 + πœŽπ΅π‘‘ 𝑑𝑧𝑑  π‘₯ 𝑑is the spread between the two assets.  π‘₯𝑑 = log 𝐴 𝑑 βˆ’ log 𝐡𝑑 6
  • 7. Ornstein-Uhlenbeck Process  We assume the spread, the basket that we want to trade, follows a mean-reverting process.  𝑑π‘₯𝑑 = π‘˜ πœƒ βˆ’ π‘₯𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑  πœƒ is the long term equilibrium to which the spread reverts.  π‘˜ is the rate of reversion. It must be positive to ensure stability around the equilibrium value. 7
  • 8. Instantaneous Correlation  Let 𝜌 denote the instantaneous correlation coefficient between 𝑧 and πœ”.  𝐸 π‘‘πœ” 𝑑 𝑑𝑧𝑑 = 𝜌𝜌𝜌 8
  • 9. Univariate Ito’s Lemma 9  Assume  𝑑𝑋𝑑 = πœ‡ 𝑑 𝑑𝑑 + πœŽπ‘‘ 𝑑𝐡𝑑  𝑓 𝑑, 𝑋𝑑 is twice differentiable of two real variables  We have  𝑑𝑑 𝑑, 𝑋𝑑 = πœ•πœ• πœ•πœ• + πœ‡ 𝑑 πœ•πœ• πœ•πœ• + πœŽπ‘‘ 2 2 πœ•2 𝑓 πœ•π‘₯2 𝑑𝑑 + πœŽπ‘‘ πœ•πœ• πœ•πœ• 𝑑𝐡𝑑
  • 10. Log example  For G.B.M., 𝑑𝑋𝑑 = πœ‡π‘‹π‘‘ 𝑑𝑑 + πœŽπ‘‹π‘‘ 𝑑𝑧𝑑, 𝑑 log 𝑋𝑑 =?  𝑓 π‘₯ = log π‘₯  πœ•π‘“ πœ•π‘‘ = 0  πœ•π‘“ πœ•π‘₯ = 1 π‘₯  πœ•2 𝑓 πœ•π‘₯2 = βˆ’ 1 π‘₯2  𝑑 log 𝑋𝑑 = πœ‡π‘‹π‘‘ 1 𝑋𝑑 + πœŽπ‘‹π‘‘ 2 2 βˆ’ 1 𝑋𝑑 2 𝑑𝑑 + πœŽπ‘‹π‘‘ 1 𝑋𝑑 𝑑𝐡𝑑  = πœ‡ βˆ’ 𝜎2 2 𝑑𝑑 + πœŽπ‘‘π΅π‘‘ 10
  • 11. Multivariate Ito’s Lemma 11  Assume  𝑋𝑑 = 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛 is a vector Ito process  𝑓 π‘₯1𝑑, π‘₯2𝑑, β‹― , π‘₯ 𝑛𝑛 is twice differentiable  We have  𝑑𝑑 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛  = βˆ‘ πœ• πœ•π‘₯ 𝑖 𝑛 𝑖=1 𝑓 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛 𝑑𝑋𝑖 𝑑  + 1 2 βˆ‘ βˆ‘ πœ•2 πœ•π‘₯ 𝑖 πœ•π‘₯ 𝑗 𝑛 𝑗=1 𝑛 𝑖=1 𝑓 𝑋1𝑑, 𝑋2𝑑, β‹― , 𝑋 𝑛𝑛 𝑑 𝑋𝑖, 𝑋𝑗 𝑑
  • 12. Multivariate Example  log 𝐴 𝑑 = π‘₯ 𝑑 + log 𝐡𝑑  𝐴 𝑑 = exp π‘₯ 𝑑 + log 𝐡𝑑  πœ•π΄ 𝑑 πœ•π‘₯ 𝑑 = exp π‘₯ 𝑑 + log 𝐡𝑑 = 𝐴 𝑑  πœ•π΄ 𝑑 πœ•π΅π‘‘ = exp π‘₯ 𝑑 + log 𝐡𝑑 1 𝐡𝑑 = 𝐴 𝑑 𝐡𝑑  πœ•2 𝐴 𝑑 πœ•π‘₯ 𝑑 2 = πœ•π΄ 𝑑 πœ•π‘₯ 𝑑 = 𝐴 𝑑  πœ•2 𝐴 𝑑 πœ•π΅π‘‘ 2 = πœ• πœ•π΅π‘‘ 𝐴 𝑑 𝐡𝑑 = 0  πœ•2 𝐴 𝑑 πœ•π΅π‘‘ πœ•π‘₯ 𝑑 = πœ• πœ•π΅π‘‘ πœ•π΄ 𝑑 πœ•π‘₯ 𝑑 = πœ•π΄ 𝑑 πœ•π΅π‘‘ = 𝐴 𝑑 𝐡𝑑 12
  • 13. What is the Dynamic of Asset At?  πœ•π΄ 𝑑 = πœ•π΄ 𝑑 πœ•πœ• 𝑑π‘₯ 𝑑 + πœ•π΄ 𝑑 πœ•π΅π‘‘ 𝑑𝐡𝑑 + 1 2 πœ•2 𝐴 𝑑 πœ•π‘₯2 𝑑π‘₯ 𝑑 2 + πœ•2 𝐴 𝑑 πœ•π΅π‘‘ πœ•π‘₯ 𝑑π‘₯ 𝑑 𝑑𝐡𝑑  = 𝐴 𝑑 𝑑π‘₯ 𝑑 + 𝐴 𝑑 𝐡𝑑 𝑑𝐡𝑑 + 1 2 𝐴 𝑑 𝑑π‘₯ 𝑑 2 + 𝐴 𝑑 𝐡𝑑 𝑑π‘₯ 𝑑 𝑑𝐡𝑑  = 𝐴 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 + 𝐴 𝑑 𝐡𝑑 πœ‡π΅π‘‘ 𝑑𝑑 + πœŽπ΅π‘‘ 𝑑𝑧𝑑 + 1 2 𝐴 𝑑 πœ‚2 𝑑𝑑 + 𝐴 𝑑 𝐡𝑑 πœŒπœ‚πœ‚π΅π‘‘ 𝑑𝑑 13
  • 14. Dynamic of Asset At  πœ•π΄ 𝑑 = 𝐴 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 + 𝐴 𝑑 πœ‡π‘‘π‘‘ + πœŽπ‘‘π‘§π‘‘ + 1 2 𝐴 𝑑 πœ‚2 𝑑𝑑 + 𝐴 𝑑 πœŒπœ‚πœ‚π‘‘π‘‘  = 𝐴 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + πœ‡ + 1 2 πœ‚2 + 𝜌𝜌𝜌 𝑑𝑑 + 𝐴 𝑑 πœ‚πœ‚πœ” 𝑑 + 𝐴 𝑑 πœŽπ‘‘π‘§π‘‘  = 𝐴 𝑑 πœ‡ + π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 πœ‚2 + 𝜌𝜌𝜌 𝑑𝑑 + πœŽπ‘‘π‘§π‘‘ + πœ‚πœ‚πœ” 𝑑 14
  • 15. Notations  𝑉𝑑: the value of a self-financing pairs trading portfolio  β„Ž 𝑑:the portfolio weight for stock A  β„Ž 𝑑 οΏ½ = βˆ’β„Ž 𝑑:the portfolio weight for stock B 15
  • 16. Self-Financing Portfolio Dynamic  𝑑𝑉𝑑 𝑉𝑑 = β„Ž 𝑑 𝑑𝐴 𝑑 𝐴 𝑑 + β„Ž 𝑑 οΏ½ 𝑑𝐡𝑑 𝐡𝑑 + 𝑑𝑀𝑑 𝑀𝑑  = β„Ž 𝑑 πœ‡ + π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 πœ‚2 + 𝜌𝜌𝜌 𝑑𝑑 + πœŽπ‘‘π‘§π‘‘ + πœ‚πœ‚πœ” 𝑑 βˆ’ β„Ž 𝑑 πœ‡π‘‘π‘‘ + πœŽπ‘‘π‘§π‘‘ + π‘Ÿπ‘Ÿπ‘Ÿ  = β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 πœ‚2 + 𝜌𝜌𝜌 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 + π‘Ÿπ‘Ÿπ‘Ÿ  = β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 πœ‚2 + 𝜌𝜌𝜌 + π‘Ÿ 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 16
  • 17. Power Utility  Investor preference:  π‘ˆ π‘₯ = π‘₯ 𝛾  π‘₯ β‰₯ 0  0 < 𝛾 < 1 17
  • 18. Problem Formulation  max β„Ž 𝑑 𝐸 𝑉𝑇 𝛾 , s.t.,  𝑉 0 = 𝑣0, x 0 = π‘₯0  𝑑π‘₯𝑑 = π‘˜ πœƒ βˆ’ π‘₯𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑  𝑑𝑉𝑑 = β„Ž 𝑑 𝑑π‘₯ 𝑑 = β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑  Note that we simplify GBM to BM of 𝑉𝑑, and remove some constants. 18
  • 19. Dynamic Programming 19  Consider a stage problem to minimize (or maximize) the accumulated costs over a system path. s0 s11 s12 time t = 0 t = 1 S21 S22 s23 t = 2 3 2 3 5 Cost = 𝑐3 + βˆ‘ 𝑐𝑑 2 𝑑=0 s3 s12 5 4 3 1 5
  • 20. Dynamic Programming Formulation  State change: π‘₯ π‘˜+1 = π‘“π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜  π‘˜: time  π‘₯ π‘˜: state  𝑒 π‘˜: control decision selected at time π‘˜  πœ” π‘˜: a random noise  Cost: 𝑔 𝑁 π‘₯ 𝑁 + βˆ‘ 𝑔 π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜ π‘βˆ’1 π‘˜=0  Objective: minimize (maximize) the expected cost.  We need to take expectation to account for the noise, πœ” π‘˜. 20
  • 21. Principle of Optimality  Let πœ‹βˆ— = πœ‡0 βˆ—, πœ‡1 βˆ—, β‹― , πœ‡ π‘βˆ’1 βˆ— be an optimal policy for the basic problem, and assume that when using πœ‹βˆ— , a give state π‘₯𝑖 occurs at time 𝑖 with positive probability. Consider the sub-problem whereby we are at π‘₯𝑖 at time 𝑖 and wish to minimize the β€œcost-to-go” from time 𝑖 to time 𝑁.  𝐸 𝑔 𝑁 π‘₯ 𝑁 + βˆ‘ 𝑔 π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜ π‘βˆ’1 π‘˜=𝑖  Then the truncated policy πœ‡π‘– βˆ—, πœ‡π‘–+1 βˆ—, β‹― , πœ‡ π‘βˆ’1 βˆ— is optimal for this sub-problem. 21
  • 22. Dynamic Programming Algorithm  For every initial state π‘₯0, the optimal cost π½βˆ— π‘₯ π‘˜ of the basic problem is equal to 𝐽0 π‘₯0 , given by the last step of the following algorithm, which proceeds backward in time from period 𝑁 βˆ’ 1 to period 0:  𝐽 𝑁 π‘₯ 𝑁 = 𝑔 𝑁 π‘₯ 𝑁  𝐽 π‘˜ π‘₯ π‘˜ = min 𝑒 π‘˜ 𝐸 𝑔 π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜ + 𝐽 π‘˜+1 π‘“π‘˜ π‘₯ π‘˜, 𝑒 π‘˜, πœ” π‘˜ 22
  • 23. Value function  Terminal condition:  𝐺 𝑇, 𝑉, π‘₯ = 𝑉 𝛾  DP equation:  𝐺 𝑑, 𝑉𝑑, π‘₯𝑑 = mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 𝐺 𝑑 + 𝑑𝑑, 𝑉𝑑+𝑑𝑑, π‘₯𝑑+𝑑𝑑  𝐺 𝑑, 𝑉𝑑, π‘₯𝑑 = mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 𝐺 𝑑, 𝑉𝑑, π‘₯𝑑 + Δ𝐺  By Ito’s lemma:  Δ𝐺 = 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 𝑑𝑑 + 𝐺 π‘₯ 𝑑π‘₯ + 1 2 𝐺 𝑉𝑉 𝑑𝑑 2 + 1 2 𝐺 π‘₯π‘₯ 𝑑π‘₯ 2 + 𝐺 𝑉π‘₯ 𝑑𝑉 𝑑𝑑 23
  • 24. Hamilton-Jacobi-Bellman Equation  Cancel 𝐺 𝑑, 𝑉𝑑, π‘₯ 𝑑 on both LHS and RHS.  Divide by time discretization, Δ𝑑.  Take limit as Δ𝑑 β†’ 0, hence Ito.  0 = mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 Δ𝐺  mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 𝑑𝑑 + 𝐺 π‘₯ 𝑑𝑑 + 1 2 𝐺 𝑉𝑉 𝑑𝑑 2 + 1 2 𝐺 π‘₯π‘₯ 𝑑𝑑 2 + 𝐺 𝑉𝑉 𝑑𝑑 𝑑𝑑 = 0  The optimal portfolio position is β„Ž 𝑑 βˆ— . 24
  • 25. HJB for Our Portfolio Value  mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 𝑑𝑑 + 𝐺 π‘₯ 𝑑𝑑 + 1 2 𝐺 𝑉𝑉 𝑑𝑑 2 + 1 2 𝐺 π‘₯π‘₯ 𝑑𝑑 2 + 𝐺 𝑉𝑉 𝑑𝑑 𝑑𝑑 = 0  mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 + 𝐺 π‘₯ 𝑑𝑑 + 1 2 𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 2 + 1 2 𝐺 π‘₯π‘₯ 𝑑𝑑 2 + 𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 𝑑𝑑 = 0  mπ‘Žπ‘Ž β„Ž 𝑑 𝐸 𝐺𝑑 𝑑𝑑 + 𝐺 𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 + 𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 + 1 2 𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 2 + 1 2 𝐺 π‘₯π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 2 + 𝐺 𝑉𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + β„Ž 𝑑 πœ‚πœ‚πœ” 𝑑 Γ— π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝑑𝑑 + πœ‚πœ‚πœ” 𝑑 = 0 25
  • 26. Taking Expectation  All πœ‚πœ‚πœ” 𝑑 disapper because of the expectation operator.  Only the deterministic 𝑑𝑑 terms remain.  Divide LHR and RHS by 𝑑𝑑.  mπ‘Žπ‘Ž β„Ž 𝑑 𝐺𝑑 + 𝐺 𝑉 β„Ž 𝑑 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 𝐺 𝑉𝑉 β„Ž 𝑑 πœ‚ 2 + 1 2 𝐺 π‘₯π‘₯ πœ‚2 +𝐺 𝑉𝑉 β„Ž 𝑑 πœ‚2 = 0 26
  • 27. Dynamic Programming Solution  Solve for the cost-to-go function, 𝐺𝑑.  Assume that the optimal policy is β„Ž 𝑑 βˆ— . 27
  • 28. First Order Condition  Differentiate w.r.t. β„Ž 𝑑.  𝐺 𝑉 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + β„Ž 𝑑 βˆ— 𝐺 𝑉𝑉 πœ‚2 + 𝐺 𝑉𝑉 πœ‚2 = 0  β„Ž 𝑑 βˆ— = βˆ’ 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2  In order to determine the optimal position, β„Ž 𝑑 βˆ— , we need to solve for 𝐺 to get 𝐺 𝑉, 𝐺 𝑉𝑉, and 𝐺 𝑉𝑉. 28
  • 29. The Partial Differential Equation (1)  𝐺𝑑 βˆ’ 𝐺 𝑉 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2 2 + 1 2 𝐺 π‘₯π‘₯ πœ‚2 βˆ’ 𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2 = 0 29
  • 30. The Partial Differential Equation (2)  𝐺𝑑 βˆ’ 𝐺 𝑉 π‘˜ πœƒ βˆ’ π‘₯ 𝑑 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ π‘˜ πœƒ βˆ’ π‘₯ 𝑑 + 1 2 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 2 𝐺 𝑉𝑉 πœ‚2 + 1 2 𝐺 π‘₯π‘₯ πœ‚2 βˆ’ 𝐺 𝑉𝑉 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 = 0 30
  • 31. Dis-equilibrium  Let 𝑏 = π‘˜ πœƒ βˆ’ π‘₯ 𝑑 . Rewrite:  𝐺𝑑 βˆ’ 𝐺 𝑉 𝑏 𝐺 𝑉 𝑏+𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏 + 1 2 𝐺 𝑉 𝑏+𝐺 𝑉𝑉 πœ‚2 2 𝐺 𝑉𝑉 πœ‚2 + 1 2 𝐺 π‘₯π‘₯ πœ‚2 βˆ’ 𝐺 𝑉𝑉 𝐺 𝑉 𝑏+𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 = 0  Multiply by 𝐺 𝑉𝑉 πœ‚2 .  𝐺𝑑 𝐺 𝑉𝑉 πœ‚2 βˆ’ 𝐺 𝑉 𝑏 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏𝐺 𝑉𝑉 πœ‚2 + 1 2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2 + 1 2 𝐺 π‘₯π‘₯ 𝐺 𝑉𝑉 πœ‚4 βˆ’ 𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 = 0 31
  • 32. Simplification  Note that  βˆ’πΊ 𝑉 𝑏 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 + 1 2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2 βˆ’ 𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 = βˆ’ 1 2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2  The PDE becomes  𝐺𝑑 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏𝐺 𝑉𝑉 πœ‚2 + 1 2 𝐺 π‘₯π‘₯ 𝐺 𝑉𝑉 πœ‚4 βˆ’ 1 2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2 = 0 32
  • 33. The Partial Differential Equation (3)  𝐺𝑑 𝐺 𝑉𝑉 πœ‚2 + 𝐺 π‘₯ 𝑏𝐺 𝑉𝑉 πœ‚2 + 1 2 𝐺 π‘₯π‘₯ 𝐺 𝑉𝑉 πœ‚4 βˆ’ 1 2 𝐺 𝑉 𝑏 + 𝐺 𝑉𝑉 πœ‚2 2 = 0 33
  • 34. Ansatz for G  𝐺 𝑑, 𝑉, π‘₯ = 𝑓 𝑑, π‘₯ 𝑉 𝛾  𝐺 𝑇, 𝑉, π‘₯ = 𝑉 𝛾  𝑓 𝑇, π‘₯ = 1  𝐺𝑑 = 𝑉 𝛾 𝑓𝑑  𝐺 𝑉 = 𝛾𝑉 π›Ύβˆ’1 𝑓  𝐺 𝑉𝑉 = 𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2 𝑓  𝐺 π‘₯ = 𝑉 𝛾 𝑓π‘₯  𝐺 𝑉π‘₯ = 𝛾𝑉 π›Ύβˆ’1 𝑓π‘₯  𝐺 π‘₯π‘₯ = 𝑉 𝛾 𝑓π‘₯π‘₯ 34
  • 35. Another PDE (1)  𝑉 𝛾 𝑓𝑑 𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2 π‘“πœ‚2 + 𝑉 𝛾 𝑓π‘₯ 𝑏𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2 π‘“πœ‚2 + 1 2 𝑉 𝛾 𝑓π‘₯π‘₯ 𝛾 𝛾 βˆ’ 1 𝑉 π›Ύβˆ’2 π‘“πœ‚4 βˆ’ 1 2 𝛾𝑉 π›Ύβˆ’1 𝑓𝑏 + 𝛾𝑉 π›Ύβˆ’1 𝑓π‘₯ πœ‚2 2 = 0  Divide by 𝛾 𝛾 βˆ’ 1 πœ‚2 𝑉2π›Ύβˆ’2.  𝑓𝑑 𝑓 + 𝑓π‘₯ 𝑏𝑓 + 1 2 𝑓π‘₯π‘₯ π‘“πœ‚2 βˆ’ 𝛾 2 π›Ύβˆ’1 𝑓 𝑏 πœ‚ + 𝑓π‘₯ πœ‚ 2 = 0 35
  • 36. Ansatz for 𝑓  𝑓𝑓𝑑 + 𝑏𝑏𝑓π‘₯ + 1 2 πœ‚2 𝑓𝑓π‘₯π‘₯ βˆ’ 𝛾 2 π›Ύβˆ’1 𝑏 πœ‚ 𝑓 + πœ‚π‘“π‘₯ 2 = 0  𝑓 𝑑, π‘₯ = 𝑔 𝑑 exp π‘₯π‘₯ 𝑑 + π‘₯2 𝛼 𝑑 = 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼  𝑓𝑑 = 𝑔𝑑 exp π‘₯π‘₯ + π‘₯2 𝛼 + 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑  𝑓π‘₯ = 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯  𝑓π‘₯π‘₯ = 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯ 2 + 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 2𝛼  𝑓π‘₯ 𝑓 = 𝛽 + 2𝛼𝛼 36
  • 37. Boundary Conditions  𝑓 𝑇, π‘₯ = 𝑔 𝑇 exp π‘₯π‘₯ 𝑇 + π‘₯2 𝛼 𝑇 = 1  𝑔 𝑇 = 1  𝛼 𝑇 = 0  𝛽 𝑇 = 0 37
  • 38. Yet Another PDE (1)  𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝑔𝑑 exp π‘₯π‘₯ + π‘₯2 𝛼 + 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑 + 𝑏𝑏 exp π‘₯π‘₯ + π‘₯2 𝛼 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯ + 1 2 πœ‚2 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯ 2 + 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 2𝛼 βˆ’ 𝛾 2 π›Ύβˆ’1 𝑏 πœ‚ 𝑔 exp π‘₯π‘₯ + π‘₯2 𝛼 + πœ‚πœ‚ exp π‘₯π‘₯ + π‘₯2 𝛼 𝛽 + 2π‘₯π‘₯ 2 = 0  Divide by g exp π‘₯π‘₯ + π‘₯2 𝛼 exp π‘₯π‘₯ + π‘₯2 𝛼 .  𝑔𝑑 + 𝑔 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑 + 𝑏𝑏 𝛽 + 2π‘₯π‘₯ + 1 2 πœ‚2 𝑔 𝛽 + 2π‘₯π‘₯ 2 + 𝑔 2𝛼 βˆ’ 𝛾 2 π›Ύβˆ’1 𝑔 𝑏 πœ‚ + πœ‚ 𝛽 + 2π‘₯π‘₯ 2 = 0  𝑔𝑑 + 𝑔 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑 + 𝑏𝑏 𝛽 + 2π‘₯π‘₯ + 1 2 πœ‚2 𝑔 𝛽 + 2π‘₯π‘₯ 2 + πœ‚2 𝑔𝑔 βˆ’ 𝛾 2 π›Ύβˆ’1 𝑔 𝑏 πœ‚ + πœ‚ 𝛽 + 2π‘₯π‘₯ 2 = 0 38
  • 39. Yet Another PDE (2)  πœ† = 𝛾 2 π›Ύβˆ’1  𝑔𝑑 + 𝑔 π‘₯𝛽𝑑 + π‘₯2 𝛼 𝑑 + 𝑏𝑏 𝛽 + 2π‘₯π‘₯ + 1 2 πœ‚2 𝑔 𝛽 + 2π‘₯π‘₯ 2 + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” 𝑏 πœ‚ + πœ‚ 𝛽 + 2π‘₯π‘₯ 2 = 0 39
  • 40. Expansion in π‘₯  𝑔𝑑 + 𝑔𝑔𝛽𝑑 + 𝑔π‘₯2 𝛼 𝑑 + 𝑏𝑏𝛽 + 2π‘₯π‘₯𝑏𝑏 + 1 2 πœ‚2 𝑔 𝛽2 + 4π‘₯2 𝛼2 + 4π‘₯π‘₯π‘₯ + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” 𝑏2 πœ‚2 + πœ‚2 𝛽2 + 4πœ‚2 π‘₯2 𝛼2 + 2𝑏𝑏 + 4𝑏𝑏𝑏 + 4πœ‚2 π‘₯π‘₯π‘₯ = 0  𝑔𝑑 + 𝑔𝑔𝛽𝑑 + 𝑔π‘₯2 𝛼 𝑑 + π‘˜ πœƒ βˆ’ π‘₯ 𝑔𝛽 + 2π‘₯π‘₯π‘˜ πœƒ βˆ’ π‘₯ 𝑔 + 1 2 πœ‚2 𝑔 𝛽2 + 4π‘₯2 𝛼2 + 4π‘₯π‘₯π‘₯ + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” π‘˜2 πœƒβˆ’π‘₯ 2 πœ‚2 + πœ‚2 𝛽2 + 4πœ‚2 π‘₯2 𝛼2 + 2π‘˜ πœƒ βˆ’ π‘₯ 𝛽 + 4π‘˜ πœƒ βˆ’ π‘₯ π‘₯π‘₯ + 4πœ‚2 π‘₯π‘₯π‘₯ = 0  𝑔𝑑 + 𝑔𝑔𝛽𝑑 + 𝑔π‘₯2 𝛼 𝑑 + π‘˜π‘˜π›½π›½ βˆ’ π‘˜π‘˜π›½π‘₯ + 2π‘₯π‘₯π‘˜π‘˜πœƒ βˆ’ 2π›Όπ‘˜π‘˜π‘₯2 + 1 2 πœ‚2 𝑔𝛽2 + 2πœ‚2 𝑔π‘₯2 𝛼2 + 2πœ‚2 𝑔𝑔𝑔𝑔 + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” πœ‚2 π‘˜2 πœƒ2 + 2 πœ†π‘” πœ‚2 π‘˜2 πœƒπ‘₯ βˆ’ πœ†π‘” πœ‚2 π‘˜2 π‘₯2 βˆ’ πœ†π‘”πœ‚2 𝛽2 βˆ’ 4πœ†π‘”πœ‚2 π‘₯2 𝛼2 βˆ’ 2πœ†π‘”π‘”π›½π›½ + 2πœ†π‘”π‘”π›½π‘₯ βˆ’ 4πœ†π‘”π‘”πœƒπœƒπœƒ + 4πœ†π‘”π‘”π‘₯2 𝛼 βˆ’ 4πœ†π‘”πœ‚2 π‘₯π‘₯π‘₯ = 0 40
  • 41. Grouping in π‘₯  𝑔𝑑 + π‘˜π‘˜π›½π›½ + 1 2 πœ‚2 𝑔𝛽2 + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” πœ‚2 π‘˜2 πœƒ2 βˆ’ πœ†π‘”πœ‚2 𝛽2 βˆ’ 2πœ†π‘”π‘”π›½π›½ + 𝑔𝛽𝑑 βˆ’ π‘˜π‘˜π›½ + 2π›Όπ‘˜π‘˜πœƒ + 2πœ‚2 𝑔𝑔𝑔 + 2 πœ†π‘” πœ‚2 π‘˜2 πœƒ + 2πœ†π‘”π‘”π›½ βˆ’ 4πœ†π‘”π‘”πœƒπœƒ βˆ’ 4πœ†π‘”πœ‚2 𝛼𝛼 π‘₯ + 𝑔𝛼 𝑑 βˆ’ 2π›Όπ‘˜π‘˜ + 2πœ‚2 𝑔𝛼2 βˆ’ πœ†π‘” πœ‚2 π‘˜2 βˆ’ 4πœ†π‘”πœ‚2 𝛼2 + 4πœ†π‘”π‘”π›Ό π‘₯2 = 0 41
  • 42. The Three PDE’s (1)  𝑔𝛼 𝑑 βˆ’ 2π›Όπ‘˜π‘˜ + 2πœ‚2 𝑔𝛼2 βˆ’ πœ†π‘” πœ‚2 π‘˜2 βˆ’ 4πœ†π‘”πœ‚2 𝛼2 + 4πœ†π‘”π‘”π›Ό = 0  𝑔𝛽𝑑 βˆ’ π‘˜π‘˜π›½ + 2π›Όπ‘˜π‘˜πœƒ + 2πœ‚2 𝑔𝑔𝑔 + 2 πœ†π‘” πœ‚2 π‘˜2 πœƒ + 2πœ†π‘”π‘”π›½ βˆ’ 4πœ†π‘”π‘”πœƒπœƒ βˆ’ 4πœ†π‘”πœ‚2 𝛼𝛼 = 0  𝑔𝑑 + π‘˜π‘˜π›½π›½ + 1 2 πœ‚2 𝑔𝛽2 + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” πœ‚2 π‘˜2 πœƒ2 βˆ’ πœ†π‘”πœ‚2 𝛽2 βˆ’ 2πœ†π‘”π‘”π›½π›½ = 0 42
  • 43. PDE in 𝛼  𝛼 𝑑 + 2πœ‚2 βˆ’ 4πœ†πœ†2 𝛼2 + 4πœ†π‘˜ βˆ’ 2π‘˜ 𝛼 βˆ’ πœ† πœ‚2 π‘˜2 = 0  𝛼 𝑑 = πœ† πœ‚2 π‘˜2 + 2π‘˜ 1 βˆ’ 2πœ† 𝛼 + 2πœ‚2 2πœ† βˆ’ 1 𝛼2 43
  • 44. PDE in 𝛽, 𝛼  𝛽𝑑 βˆ’ π‘˜π›½ + 2πœ‚2 𝛼𝛼 + 2πœ†π‘˜π›½ βˆ’ 4πœ†πœ†2 𝛼𝛼 βˆ’ 4πœ†π‘˜πœƒπœƒ + 2 πœ† πœ‚2 π‘˜2 πœƒ + 2π›Όπ‘˜πœƒ = 0  𝛽𝑑 = π‘˜ βˆ’ 2πœ‚2 𝛼 βˆ’ 2πœ†π‘˜ + 4πœ†πœ†2 𝛼 𝛽 + 4πœ†π‘˜πœƒπœƒ βˆ’ 2 πœ† πœ‚2 π‘˜2 πœƒ βˆ’ 2π›Όπ‘˜πœƒ 44
  • 45. PDE in 𝛽, 𝛼, 𝑔  𝑔𝑑 + π‘˜π‘˜π›½π›½ + 1 2 πœ‚2 𝑔𝛽2 + πœ‚2 𝑔𝑔 βˆ’ πœ†π‘” πœ‚2 π‘˜2 πœƒ2 βˆ’ πœ†π‘”πœ‚2 𝛽2 βˆ’ 2πœ†π‘”π‘”π›½π›½ = 0  𝑔𝑑 = βˆ’π‘˜π‘˜π›½π›½ βˆ’ 1 2 πœ‚2 𝑔𝛽2 βˆ’ πœ‚2 𝑔𝑔 + πœ†π‘” πœ‚2 π‘˜2 πœƒ2 + πœ†π‘”πœ‚2 𝛽2 + 2πœ†π‘”π‘”π›½π›½  𝑔𝑑 = 𝑔 βˆ’π‘˜π›½π›½ βˆ’ 1 2 πœ‚2 𝛽2 βˆ’ πœ‚2 𝛼 + πœ† πœ‚2 π‘˜2 πœƒ2 + πœ†πœ†2 𝛽2 + 2πœ†π‘˜π›½π›½ 45
  • 46. Riccati Equation  A Riccati equation is any ordinary differential equation that is quadratic in the unknown function.  𝛼 𝑑 = πœ† πœ‚2 π‘˜2 + 2π‘˜ 1 βˆ’ 2πœ† 𝛼 + 2πœ‚2 2πœ† βˆ’ 1 𝛼2  𝛼 𝑑 = 𝐴0 + 𝐴1 𝛼 + 𝐴2 𝛼2 46
  • 47. Solving a Riccati Equation by Integration  Suppose a particular solution, 𝛼1, can be found.  𝛼 = 𝛼1 + 1 𝑧 is the general solution, subject to some boundary condition. 47
  • 48. Particular Solution  Either 𝛼1 or 𝛼2 is a particular solution to the ODE. This can be verified by mere substitution.  𝛼1,2 = βˆ’π΄1Β± 𝐴1 2 βˆ’4𝐴2 𝐴0 2𝐴2 48
  • 49. 𝑧 Substitution  Suppose 𝛼 = 𝛼1 + 1 𝑧 .  1 𝑧 Μ‡ = 𝐴0 + 𝐴1 𝛼1 + 1 𝑧 + 𝐴2 𝛼1 + 1 𝑧 2  = 𝐴0 + 𝐴1 𝛼1 + 𝐴1 1 𝑧 + 𝐴2 𝛼1 2 + 𝐴2 1 𝑧2 + 2𝐴2 𝛼1 𝑧  = 𝐴0 + 𝐴1 𝛼1 + 𝐴1 1 𝑧 + 𝐴2 𝛼1 2 + 𝐴2 1 𝑧2 + 2𝐴2 𝛼1 𝑧  = 𝐴0 + 𝐴1 𝛼1 + 𝐴2 𝛼1 2 + 𝐴1+2𝛼1 𝐴2 𝑧 + 𝐴2 𝑧2 goes to 0 by the definition of 𝛼1 49
  • 50. Solving 𝑧  1 𝑧 Μ‡ = 𝐴1+2𝛼1 𝐴2 𝑧 + 𝐴2 𝑧2  βˆ’ 1 𝑧2 𝑧̇ = 𝐴1+2𝛼1 𝐴2 𝑧 + 𝐴2 𝑧2  1st order linear ODE  𝑧̇ + 𝐴1 + 2𝛼1 𝐴2 𝑧 = βˆ’π΄2  𝑧 𝑑 = βˆ’π΄2 𝐴1+2𝛼1 𝐴2 + 𝐢exp βˆ’ 𝐴1 + 2𝛼1 𝐴2 𝑑 50
  • 51. Solving for 𝛼  𝛼 = 𝛼1 + 1 βˆ’π΄2 𝐴1+2𝛼1 𝐴2 +𝐢expβˆ’ 𝐴1+2𝛼1 𝐴2 𝑑  boundary condition:  𝛼 𝑇 = 0  𝛼1 + 1 βˆ’π΄2 𝐴1+2𝛼1 𝐴2 +𝐢expβˆ’ 𝐴1+2𝛼1 𝐴2 𝑇 = 0  𝐢exp βˆ’ 𝐴1 + 2𝛼1 𝐴2 𝑇 = βˆ’ 1 𝛼1 + 𝐴2 𝐴1+2𝛼1 𝐴2  𝐢 = exp 𝐴1 + 2𝛼1 𝐴2 𝑇 𝐴2 𝐴1+2𝛼1 𝐴2 βˆ’ 1 𝛼1 51
  • 52. 𝛼 Solution (1)  𝛼 = 𝛼1 + 1 βˆ’π΄2 𝐴1+2𝛼1 𝐴2 +𝐢expβˆ’ 𝐴1+2𝛼1 𝐴2 𝑑  = 𝛼1 + 1 βˆ’π΄2 𝐴1+2𝛼1 𝐴2 +exp 𝐴1+2𝛼1 𝐴2 𝑇 𝐴2 𝐴1+2𝛼1 𝐴2 βˆ’ 1 𝛼1 exp βˆ’ 𝐴1+2𝛼1 𝐴2 𝑑  = 𝛼1 + 1 βˆ’π΄2 𝐴1+2𝛼1 𝐴2 +exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ 𝐴2 𝐴1+2𝛼1 𝐴2 βˆ’ 1 𝛼1  = 𝛼1 + 𝛼1 𝐴1+2𝛼1 𝐴2 βˆ’π›Ό1 𝐴2+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ 𝛼1 𝐴2βˆ’π΄1βˆ’2𝛼1 𝐴2 52
  • 53. 𝛼 Solution (2)  𝛼 = 𝛼1 + 𝛼1 𝐴1+2𝛼1 𝐴2 βˆ’π›Ό1 𝐴2+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ βˆ’π΄1βˆ’π›Ό1 𝐴2  = 𝛼1 1 βˆ’ 𝐴1+2𝛼1 𝐴2 𝐴2+exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ 𝐴1 𝛼1 +𝐴2  = 𝛼1 1 βˆ’ 𝐴1 𝐴2 +2𝛼1 1+ 𝐴1 𝛼1 𝐴2 +1 exp 𝐴1+2𝛼1 𝐴2 π‘‡βˆ’π‘‘ 53
  • 54. 𝛼 Solution (3)  𝛼 𝑑 = π‘˜ 2πœ‚2 1 βˆ’ 1 βˆ’ 𝛾 + 2 1βˆ’π›Ύ 1+ 1βˆ’ 2 1βˆ’ 1βˆ’π›Ύ exp 2π‘˜ 1βˆ’π›Ύ π‘‡βˆ’π‘‘ 54
  • 55. Solving 𝛽  𝛽𝑑 = π‘˜ βˆ’ 2πœ‚2 𝛼 βˆ’ 2πœ†π‘˜ + 4πœ†πœ†2 𝛼 𝛽 + 4πœ†π‘˜πœƒπœƒ βˆ’ 2 πœ† πœ‚2 π‘˜2 πœƒ βˆ’ 2π›Όπ‘˜πœƒ  Let 𝜏 = 𝑇 βˆ’ 𝑑  𝛽̂ 𝜏 = 𝛽 𝑇 βˆ’ 𝑑  𝛽̂ 𝜏 𝜏 = βˆ’π›½π‘‘ 𝜏  βˆ’π›½Μ‚ 𝜏 𝜏 = 𝛽𝑑 𝜏 = π‘˜ βˆ’ 2πœ‚2 𝛼 𝜏 βˆ’ 2πœ†π‘˜ + 4πœ†πœ†2 𝛼 𝜏 𝛽 𝜏 + 4πœ†π‘˜πœƒπœƒ 𝜏 βˆ’ 2 πœ† πœ‚2 π‘˜2 πœƒ βˆ’ 2𝛼 𝜏 π‘˜πœƒ  𝛽̂ 𝜏 𝜏 = βˆ’π‘˜ + 2πœ‚2 𝛼� + 2πœ†π‘˜ βˆ’ 4πœ†πœ†2 𝛼� 𝛽̂ + βˆ’4πœ†π‘˜πœƒπ›ΌοΏ½ + 2 πœ† πœ‚2 π‘˜2 πœƒ + 2π›ΌοΏ½π‘˜πœƒ  𝛽̂ 𝜏 𝜏 = 2πœ† βˆ’ 1 π‘˜ + 2πœ‚2 𝛼� 1 βˆ’ 2πœ† 𝛽̂ + 2π›ΌοΏ½π‘˜πœƒ 1 βˆ’ 2πœ† + 2 πœ† πœ‚2 π‘˜2 πœƒ 55
  • 56. First Order Non-Constant Coefficients  𝛽̂ 𝜏 = 𝐡1 𝛽̂ + 𝐡2  𝐡1 𝜏 = 2πœ† βˆ’ 1 π‘˜ + 2πœ‚2 𝛼� 1 βˆ’ 2πœ†  𝐡2 𝜏 = 2π›ΌοΏ½π‘˜πœƒ 1 βˆ’ 2πœ† + 2 πœ† πœ‚2 π‘˜2 πœƒ 56
  • 57. Integrating Factor (1)  𝛽̂ 𝜏 βˆ’ 𝐡1 𝛽̂ = 𝐡2  We try to find an integrating factor πœ‡ = πœ‡ 𝜏 s.t.  𝑑 π‘‘πœ πœ‡π›½Μ‚ = πœ‡ 𝑑𝛽� π‘‘πœ + 𝛽̂ π‘‘πœ‡ π‘‘πœ = πœ‡π΅2  Divide LHS and RHS by πœ‡π›½Μ‚.  1 𝛽� 𝑑𝛽� 𝑑𝑑 + 1 πœ‡ π‘‘πœ‡ π‘‘πœ = 𝐡2 𝛽�  By comparison,  βˆ’π΅1 = 1 πœ‡ π‘‘πœ‡ π‘‘πœ 57
  • 58. Integrating Factor (2)  ∫ βˆ’π΅1 π‘‘πœ = ∫ π‘‘πœ‡ πœ‡ = log πœ‡ + 𝐢  πœ‡ = exp ∫ βˆ’π΅1 π‘‘πœ  πœ‡π›½Μ‚ = ∫ πœ‡π΅2 π‘‘πœ + 𝐢  𝛽̂ = ∫ πœ‡π΅2 π‘‘πœ+𝐢 πœ‡  𝛽̂ = ∫ exp ∫ βˆ’π΅1 𝑑𝑒 𝐡2 π‘‘πœ+𝐢 exp ∫ βˆ’π΅1 π‘‘πœ 58
  • 59. 𝛽̂ Solution  𝛽̂ = ∫ exp ∫ βˆ’π΅1 𝑒 𝑑𝑑 𝜏 0 𝐡2 𝑠 𝑑𝑠 𝜏 0 exp ∫ βˆ’π΅1 𝑒 𝑑𝑒 𝜏 0 + 𝐢  𝛽̂ 𝜏 = exp ∫ 𝐡1 𝑒 𝑑𝑑 𝜏 0 ∫ exp ∫ βˆ’π΅1 𝑒 𝑑𝑑 𝑠 0 𝐡2 𝑠 𝑑𝑑 𝜏 0 + 𝐢 59
  • 60. 𝐡1, 𝐡2  ∫ 𝐡1 𝑠 𝑑𝑑 𝜏 0 = ∫ 2πœ† βˆ’ 1 π‘˜ + 2πœ‚2 1 βˆ’ 2πœ† 𝛼 𝑠 𝑑𝑑 𝜏 0  𝐼2 = ∫ exp ∫ βˆ’π΅1 𝑒 𝑑𝑑 𝑠 0 𝐡2 𝑠 𝑑𝑑 𝜏 0 60
  • 61. 𝛽 Solution  𝛽 𝑑 = π‘˜πœƒ πœ‚2 1 + 1 βˆ’ 𝛾 exp 2π‘˜ 1βˆ’π›Ύ π‘‡βˆ’π‘‘ βˆ’1 1+ 1βˆ’ 2 1βˆ’ 1βˆ’π›Ύ exp 2π‘˜ 1βˆ’π›Ύ π‘‡βˆ’π‘‘ 61
  • 62. Solving 𝑔  𝑔𝑑 = 𝑔 βˆ’π‘˜π›½π›½ βˆ’ 1 2 πœ‚2 𝛽2 βˆ’ πœ‚2 𝛼 + πœ† πœ‚2 π‘˜2 πœƒ2 + πœ†πœ†2 𝛽2 + 2πœ†π‘˜π›½π›½  With𝛼 and 𝛽 solved, we are now ready to solve 𝑔𝑑.  𝑔 𝑑 𝑔 = 𝐺 𝑑  𝑑 𝑑𝑠 log 𝑔𝑑 = 𝑔 𝑑 𝑔 = 𝐺  log 𝑔𝑑 = ∫ 𝐺𝐺𝐺 + 𝐢  𝑔𝑑 = 𝐢exp ∫ 𝐺𝑑𝑑 = exp βˆ’ ∫ 𝐺𝐺𝐺 𝑇 0 exp ∫ 𝐺𝐺𝐺 𝑑 0  𝑔𝑑 = exp βˆ’ ∫ 𝐺𝐺𝐺 𝑇 𝑑 62
  • 63. Computing the Optimal Position  β„Ž 𝑑 βˆ— = βˆ’ 𝐺 𝑉 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝐺 𝑉𝑉 πœ‚2 𝐺 𝑉𝑉 πœ‚2  = βˆ’ 𝛾𝑉 π›Ύβˆ’1 𝑓 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝛾𝑉 π›Ύβˆ’1 𝑓π‘₯ πœ‚2 𝛾 π›Ύβˆ’1 𝑉 π›Ύβˆ’2 π‘“πœ‚2  = βˆ’ 𝑉𝑓 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝑉𝑓π‘₯ πœ‚2 π›Ύβˆ’1 π‘“πœ‚2  = βˆ’ 𝑉 π›Ύβˆ’1 πœ‚2 𝑓 π‘˜ πœƒβˆ’π‘₯ 𝑑 +𝑓π‘₯ πœ‚2 𝑓  = βˆ’ 𝑉 π›Ύβˆ’1 πœ‚2 π‘˜ πœƒ βˆ’ π‘₯𝑑 + 𝑓π‘₯ 𝑓 πœ‚2  = 𝑉 1βˆ’π›Ύ πœ‚2 π‘˜ πœƒ βˆ’ π‘₯𝑑 + πœ‚2 𝛽 + 2𝛼𝛼  = 𝑉 1βˆ’π›Ύ βˆ’ π‘˜ πœ‚2 π‘₯𝑑 βˆ’ πœƒ + 2𝛼𝛼 + 𝛽 63
  • 64. The Optimal Position  β„Ž 𝑑 βˆ— = 𝑉𝑑 1βˆ’π›Ύ βˆ’ π‘˜ πœ‚2 π‘₯ 𝑑 βˆ’ πœƒ + 2𝛼 𝑑 π‘₯ 𝑑 + 𝛽 𝑑  β„Ž 𝑑 βˆ—~ βˆ’ π‘˜ πœ‚2 π‘₯ 𝑑 βˆ’ πœƒ 64
  • 65. P&L for Simulated Data  The portfolio increases from $1000 to $4625 in one year. 65
  • 66. Parameter Estimation  Can be done using Maximum Likelihood.  Evaluation of parameter sensitivity can be done by Monte Carlo simulation.  In real trading, it is better to be conservative about the parameters.  Better underestimate the mean-reverting speed  Better overestimate the noise  To account for parameter regime changes, we can use:  a hidden Markov chain model  moving calibration window 66
  • 68. Two-State Markov Model 68  π‘‘π‘†π‘Ÿ = π‘†π‘Ÿ πœ‡ 𝛼 π‘Ÿ 𝑑𝑑 + πœŽπœŽπ΅π‘Ÿ 𝛼 π‘Ÿ = 0 DOWN TREND 𝛼 π‘Ÿ = 1 UP TREND q p 1-q 1-p
  • 69. Buying and Selling Decisions 69  𝑑 ≀ 𝜏1 0 ≀ 𝜈1 0 ≀ 𝜏2 0 ≀ 𝜈2 0 ≀ β‹― ≀ 𝜏 𝑛 0 ≀ 𝜈 𝑛 0 ≀ β‹― ≀ 𝑇
  • 70. Optimal Trend Following Strategy 70
  • 71. Trading SSE 2001 – 2011 71