Application of automatic differentiation for the simulation of nonisothermal, multiphase flow in geothermal reservoirs Page: 3 of 8
This article is part of the collection entitled: Office of Scientific & Technical Information Technical Reports and was provided to Digital Library by the UNT Libraries Government Documents Department.
The following text was automatically extracted from the image on this page using optical character recognition software:
PROCEEDINGS, Twenty-Seventh Workshop on Geothermal Reservoir Engineering
Stanford University, Stanford, California, January 28-30, 2002
APPLICATION OF AUTOMATIC DIFFERENTIATION FOR THE SIMULATION OF
NONISOTHERMAL, MULTIPHASE FLOW IN GEOTHERMAL RESERVOIRS
Jong G. Kim' and Stefan Finsterle2
Argonne National Laboratory
9700 S. Cass Avenue
Argonne, IL 60439, U.S.A
2Lawrence Berkeley National Laboratory
One Cyclotron Road, Mail Stop 90-1116
Berkeley, CA 94720
Simulation of nonisothermal, multiphase flow
through fractured geothermal reservoirs involves the
solution of a system of strongly nonlinear algebraic
equations. The Newton-Raphson method used to
solve such a nonlinear system of equations requires
the evaluation of a Jacobian matrix. In this paper we
discuss automatic differentiation (AD) as a method
for analytically computing the Jacobian matrix of
derivatives. Robustness and efficiency of the AD-
generated derivative codes are compared with a
conventional derivative computation approach based
on first-order finite differences.
Numerical modeling techniques play an important
role in engineering geothermal field operations.
Mass, momentum, and energy balance considerations
result in a set of partial differential equations (PDEs)
describing fluid and heat transport in fractured porous
media. Analytical solutions to these PDEs are
available only for very specific and limited cases.
Therefore, numerical approaches (such as finite-
difference, finite-element, and finite-volume
methods) are often used to obtain an approximate
solution at discrete points in space and time. In these
numerical approaches, the differential equations are
reduced to a set of linear and nonlinear algebraic
equations relating all the involved primary
thermodynamic variables (such as pressure,
temperature, and phase saturation) to each discretized
grid point. Thus, the efficiency of a numerical
simulator is determined to a large extent by the
efficiency and robustness of the solvers for these
To solve nonlinear algebraic equations, reservoir
engineers often use some variation of Newton's
method. In Newton's iteration scheme, for a given set
of nonlinear algebraic equations R(x) = 0 and a given
initial guess x0, a sequence of solution increments
xp, - x9 is computed until a predefined convergence
tolerance is met:
R (x+1 - x )= -R(xp)
Here, aR/ax is the Jacobian matrix of the partial
derivative of the given nonlinear function R with
respect to the independent primary variable x. Here,
the function R represents the residuals of the
discretized mass-balance equation for each
component in each gridblock at the new time level.
Conventionally, the Jacobian matrix is computed by
the first-order finite difference (FD) method:
It is not straightforward to select an appropriate step
size Ax or increment factor S , where Ax = S x.
Values for S that are either too small or too large
can introduce serious round-off or truncation errors.
Furthermore, if highly nonlinear functions are
involved, these errors can lead to a breakdown of the
Newton iteration. In addition to the numerical
accuracy problem, the computational cost of this
method can be high for a large-sized problem, since it
requires n+1 functional computations for a Jacobian
matrix with n columns.
As an alternative to the FD method, automatic
differentiation (AD) provides accurate and fast
calculations of partial derivatives. In this paper, we
describe how the AD technique can be used within
the structure of an existing geothermal flow simulator
Here’s what’s next.
This article can be searched. Note: Results may vary based on the legibility of text within the document.
Tools / Downloads
Get a copy of this page or view the extracted text.
Citing and Sharing
Basic information for referencing this web page. We also provide extended guidance on usage rights, references, copying or embedding.
Reference the current page of this Article.
Kim, Jong G. & Finsterle, Stefan. Application of automatic differentiation for the simulation of nonisothermal, multiphase flow in geothermal reservoirs, article, January 8, 2002; Berkeley, California. (digital.library.unt.edu/ark:/67531/metadc736480/m1/3/: accessed April 21, 2018), University of North Texas Libraries, Digital Library, digital.library.unt.edu; crediting UNT Libraries Government Documents Department.