Upload
takoda
View
42
Download
5
Embed Size (px)
DESCRIPTION
Adjoint based gradient calculation - advantantages and challenges. Bjarne Foss, Ruben Ringset The Norwegian University of Science & Technology – NTNU IO center. Outline Motivation A simple example to illustrate the potential of adjoints Where are the hurdles? Conclusions. Motivation. - PowerPoint PPT Presentation
Citation preview
1
Adjoint based gradient calculation - advantantages and challenges
Bjarne Foss, Ruben RingsetThe Norwegian University of Science & Technology – NTNUIO center
Outline1. Motivation
2. A simple example to illustrate the potential of adjoints
3. Where are the hurdles?
4. Conclusions
2
Motivation
Norne fieldStatoilHydroEni, Petoro
Model
Data
3
for k=1 to N ...simulate(k) end
model well schedule
+
simulator forecast
timenow
Optimize
now
history
Parameter estimation
Uncertainty
Motivation
4
Reservoir Wells Pipelines Process Utilities Pipelines/tankers
Market
Inletseparator
Reservoir and well models
(Eclipse)
Network model(GAP, MaxPro,
OLGA)
Process model(HYSIS)
X 1
N G
L N G
C W 1
C 2
C W2 A / B
E 1 A
E 1 B
E 2
E 3
P r e - c o o l i n gP r e - c o o l i n gS e c t i o nS e c t i o n
L i q u e f a c t i o nL i q u e f a c t i o n S e c t i o nS e c t i o n
S u b - c o o l i n gS u b - c o o l i n gS e c t i o nS e c t i o n
C W3 A / B
C 1
C 3G
Application Value chain optimization
Application Value chain optimization
Motivation
Optimization requires a large number of gradient calculations
Efficient gradient computations are important
5
A simple example
kkkkk
kkkk
kkk
k
uuxxz
ukxkxx
uxk
xx
,2,1,2,1
,2,2,11,2
,12,2
,11,1
2.01.0
Output
)sin(
systemNonlinear
]2.01.0[ ],11[
10
01 ,
)sin(
21
Jacobians
,2
kk
kk
k
DC
Bkk
xkA
kk
kk
xku
xu
,1,2
2,2,1
law control leStabilizab
N
TNk
Tk
N
kk
Tk QxxRuuQzzJ
2
1][
2
1
function Objective1
0
6
A simple example
7
A simple example
8
length simulation theis where
with increases Runtime 2
N
NNwith
linearly increases Runtime
A simple example
9
Adjoint gradient computation
10
Adjoint gradient computation
Forward simulation
11
Adjoint gradient computation
One forward
simulation
One reverse
simulation
12
Forward method
N forward
simulations
(nested loops)
13
The output constraint challenge – possible remedies
Reducing the number of constraints• Enforcing them on parts of a prediction horizon• Lumping output constraints together
– One interesting application of this is found in the Standford GPRS reservoir simulator (Sarma et al, 2006)
0),0(min(),0(max(
,,,1,
,min1 1
max,,
maxmin
ik
N
k
N
iiik
Nkk
zzzzy
RzNkzzzz
z
14
The output constraint challenge
15
The output constraint challenge – possible remedies
Reducing the number of constraints• Enforcing them on parts of a prediction horizon• Lumping output constraints together
– One interesting application of this is found in the Standford GPRS reservoir simulator (Sarma et al, 2006)
0),0(min(),0(max(
,,,1,
,min1 1
max,,
maxmin
ik
N
k
N
iiik
Nkk
zzzzy
RzNkzzzz
z
Taking advantage of barrier or interior point optimization methods• Removing output constraints without introducing slack
variables• Model constraints (i.e. equality constraints) can be removed by
a single shooting method (in eg. MPC)
16
Adjoint based gradient calculation - advantantages and challenges
Conclusions• Adjoint based gradient
calculation may give huge improvements in run-time
• Output constraints is a challenge
17
18
Once again - A very simple example
ufuxf u )(2
1 22
u
Let
and assume that is the independent variable, i.e. Compute the gradient wrt
01),( uxuxg
)(),( uux
)1()(2
1 22 uxuxL Lagrangian function
du
dL
du
dx
x
L
u
LLu
du
duxxuLu
)1()1)(()(
u
Choose x
12))1(( uuuLu 0),( when 12 uxgufu
(”reverse simulation”)