Python Series – Well Test Analysis

/, Technical/Python Series – Well Test Analysis

Python Series – Well Test Analysis

Solutions for Well-Test-Analysis: Part 1 — Introductory Considerations

Written by Anthony Jimenez1and Debora Martogi2, Edited by Debora Martogi


As many would agree, the diffusivity equation is one of the most important equations for a reservoir engineer. This equation is derived from the following three principles:

  • Conservation of mass (i.e., mass balance)

  • Fundamental flow equation (i.e., “Darcy’s Law”)

  • Equation of state (i.e., fluid compressibility relations)

For a complete, comprehensive review of the aforementioned fundamental principles, readers are encouraged to review the Back to the Basics: The Liquid Diffusivity Equation article by Jimenez (link).

To gain information regarding petroleum reservoirs (i.e., skin, average reservoir pressure, permeability, drainage shape, etc.), engineers design well tests such as pressure build-up following a period of production (drawdown). During this special, controlled event, the wellbore pressure is monitored and reported. The recorded pressure over time is then used to estimate key reservoir features. With this scenario understood, the remainder of this article will focus on the radial flow solution to the diffusivity equation and important plotting considerations.

Fundamental Considerations

Opening any reservoir engineering textbook, the reader is certain to find the following form of the diffusivity equation expressed for the radial flow geometry case (Eq. 1).

It is important to note that there are some implicit assumptions in this form, namely:

  • Negligible gravity effects

  • Negligible tangential flow

  • Flowing fluid is considered Newtonian

  • Isothermal flow conditions govern

  • Homogeneous porous media

The diffusivity equation can be recast in dimensionless form, as shown in Eq. 21. By doing so, we are normalizing the pressure and time characteristics of multiple reservoirs with varying reservoir features.

where the dimensionless pressure, pD , the dimensionless radius, rD , and the dimensionless time, tD , are1

Table 1 Conversion constants1


The reservoir characteristics listed in Eq. 3 include permeability, k , porosity, ϕ , fluid viscosity, μ , total compressibility, ct , formation volume factor, B , formation thickness, h , initial pressure, pi , and reservoir pressure, pr . rw is the well’s radius, while r and t are considered radial distance away from the well and time being considered, respectively.


A Discussion on Dimensionless Variables

Suppose the reader has experience with lower-level differential equations. In that case, they will remember that a particular solution to an Ordinary Differential Equation (ODE) can be solved generally when any given set of boundary conditions and/or initial conditions are provided.

This is similar to partial differential equations (PDEs), too. The uniqueness in solutions for the diffusivity equation arises2 in that all petroleum reservoirs have various characteristics related to (but not limited to):

  • Porosity

  • Permeability

  • Viscosity

  • Initial Pressure

  • Total Compressibility

Simplification and generalization of the mathematics involved can be performed by expressing the solution in the dimensionless form (Table 1), which at its core, is a simple grouping of relevant reservoir features.

When dimensionless pressure is plotted against dimensionless time in the log-log scale (Figure 1), a type curve is generated. A type curve is a dimensionless diagnostic plot representing the “pressure behavior of theoretical reservoirs with specific features such as wellbore storage, skin, etc.” (Gringarten et al., 1979)3. For this reason, although certain field case studies will be presented, meaningful attention will be placed on classical type curve solutions.


Introduction to Diagnostic Plots

Several forms of type curves are shown in Figure 1. One significant feature of these plots is that they can display a wide range of possible solutions for a given flow problem. Additionally, various plotting functions can provide meaningful insights into the reservoir fluid flow behavior(s). A few that the readers are encouraged to review are:

  • Pressure Derivative4

  • Beta Derivative5

  • Pressure Integral6

  • Pressure Integral-Derivative6

  • Chow Pressure Group7

Figure 1 – Overview of some notable type curves used in pressure-transient and rate-transient analysis1,8,9


At the present time, attention will be focused on the pressure and pressure derivative functions. Figure 2 shows an example of a diagnostic plot with these two plotting functions displayed. Presented without discussion are the following flow regimes that are evident from the diagnostic plot:

  • Wellbore storage distortion (Early-time)

  • Transitional flow with near-wellbore skin (Early-time)

  • Radial flow (Mid-time)

Figure 2 – Diagnostic plot for reservoir experiencing infinite-acting radial flow with the presence of wellbore storage and skin


The reader is encouraged to ponder upon these three flow regimes identified and their implications. Future articles will address each of these in detail.


Concluding Remarks

Although not the most appealing topic in reservoir engineering, this first article is necessary to establish a foundation upon which to build on. The authors believe that the reader should now have learned more about the following concepts:

  • General diffusivity equation for radial flow geometry

  • Critical assumptions implicit to diffusivity equation

  • Importance of dimensionless variables

  • The relevance of diagnostic plots

As more comprehension is developed in future articles, the discussion will move away from some of the abstract concepts and focus on the applications of the solutions developed.

Disclaimer: The Well Log is a non-profit publication aimed “purely” to educate students at Texas A&M University and beyond on information pertinent to the petroleum engineering industry. All articles are written by student volunteers based on information obtained through online sources and SPE publications. If you are the owner of any materials we cited and would like us to remove it from our publications, please contact The Well Log Editors at


1 T.A. Blasingame PETE 648 Lecture Notes.

2 in addition to typical initial and boundary conditions

3 Gringarten et al. (1979). A Comparison Between Skin and Wellbore Storage Type-Curves for Early-time Transient Analysis. 

4 Bourdet et al. (1983). A new set of type curves simplifies well test analysis. SPE-8205-MS

5 Hosseinpour-Zonoozi, N., Ilk, D., & Blasingame, T. A. (2006, January 1). The Pressure Derivative Revisited–Improved Formulations and Applications. SPE-103204-MS

6 Blasingame et al. (1989). Type-Curve Analysis using Pressure Integral Method. SPE-18799-MS

7 Ozkan, E., & Raghavan, R. (1991, September 1). New Solutions for Well-Test-Analysis Problems: Part 1-Analytical Considerations (includes associated papers 28666 and 29213). SPE-18615-PA

8 Palacio, J. C., & Blasingame, T. A. (1993, January 1). UNAVAILABLE – Decline-Curve Analysis With Type Curves – Analysis of Gas Well Production Data. Society of Petroleum Engineers. SPE-25909-MS

9 Doublet, L. E., Pande, P. K., McCollum, T. J., & Blasingame, T. A. (1994, January 1). Decline Curve Analysis Using Type Curves–Analysis of Oil Well Production Data Using Material Balance Time: Application to Field Cases. Society of Petroleum Engineers. SPE-28688-MS



Leave A Comment

Welcome Ags!

Welcome to the 2020-2021 academic year. Have a blast!