Introduction

Tutorials

Reference

Installing WellSim

How WellSim works

Well fluid flow

WellSim models a steady state discharging wellbore. Steady state means that the flow of the geothermal fluid is stable, and does not change with time. The discharge could be to atmosphere, or through piping to a power station.

The well fluid

The fluid discharging up the well can be liquid, dry steam or two-phase (both liquid and vapour). A well can have the same type of fluid throughout, but often a well has liquid flow lower down, which flashes to two-phase above a certain depth as the pressure decreases up the well.

The well fluid is not simply pure water, but usually contains a range of solids and gases:

Enter CO2 and NaCl concentrations in total fluid.

Flow regime

In two-phase flow, the liquid and vapour parts can travel together in different ways, called the flow regime. The flow regime depends on the relative speed of the two parts and the relative amount of each. The latter is called the dryness: the ratio of mass of vapour to total mass of fluid.

As the two-phase fluid travels up the wellbore, the amount of vapour usually increases, and therefore the dryness increases. Typical flow regimes up the wellbore, in order of increasing dryness, are bubble, slug, churn or froth, annular or annular-mist, mist. Just above the flash point, the flow regime:


Finding well data

CO2 and NaCl concentrations

These are usually the same throughout the well if there are no secondary feedzones, so you can enter values measured at the wellhead for downwell values. Enter CO2 and NaCl concentrations in total fluid.

Drawdown factors at the deepest feedzone, from:

In this help guide, MY WELL's deepest feedzone's relationship is Linear, and the feedzone factor is 0.118 bar/t/hr.

Enthalpy at the deepest feedzone

If the reservoir is single-phase water, as most are, use a static temperature survey to find reservoir temperature and use steam tables to calculate reservoir enthalpy. This is equal to the enthalpy in the well at the deepest feedzone provided it doesn't flash in the feedzone. For most discharging wells the energy loss up the well from friction and heat loss to the surrounding rock is small, therefore the enthalpy only decreases slightly up the well.

In this help guide, MY WELL's enthalpy at the deepest feedzone is 1,524.52 kJ/kg and at the wellhead is 1,500 kJ/kg.

Fluid type at the deepest feedzone

Look at the Flow Regime at the deepest feedzone; if it is Liquid (below the flash point) then choose Liquid; otherwise choose Two-phase.

Formation temperatures

From a static temperature survey.

Reservoir pressure

This is the undisturbed reservoir pressure, at a distance from any well. Find from:

In this help guide, MY WELL's reservoir pressure is 200 barg.

Depths

Depth type can be:

Note:

Start depth: (the depth where a simulation is to start):

Finish depth: (the depth where a simulation is to end):

Depth increment: WellSim calculates the simulation values at this increment along the wellbore. If too big, the simulation might fail or will be less accurate. If too small, the simulation will take longer and there might be too much data. 50 is usually a good value.


Feedzones

A feedzone (also called a loss zone or permeable zone) is a zone of permeable rock down the wellbore that produces or accepts fluid. In WellSim all such zones are called feedzones:


Note:

Feedzone relationship and factors

WellSim needs to know the properties of a feedzone, so it can calculate the mass flowrate produced or accepted through the feedzone. WellSim models a feedzone with:

And:

For a discharging well, the reservoir pressure forces fluid into the well, so P_res is greater than P_feed, and the feedzone relationships are:

Feedzone relationship Feedzone relationship (for discharge)
Linear P_res - P_feed = a x W
Mass flow W is (fairly) constant
Quadratic P_res - P_feed = a x W + b x W x W
Steam W = c x (P_res x P_res - P_feed x P_feed) to the power of d

For an injection well, the well pressure forces fluid into the reservoir, so P_feed is greater than P_res, and the feedzone relationships are:

Feedzone relationship Feedzone relationship (for discharge)
Linear P_feed - P_res = a x W
Quadratic P_feed - P_res = a x W + b x W x W
Power law W = e x (P_feed x P_feed - P_res x P_res) to the power of f

Where:

For example:

For every feedzone you must enter the depth of the feedzone, the feedzone relationship and factors, and usually the reservoir pressure at the feedzone. You will normally find these from downwell measurements. For the feedzone relationship:

Note for an example of modelling a feedzone see here.

Feedzones during discharge and injection


Discharge simulations

The main use of a discharge simulation is to run output simulations. Before you do this, try to get the discharge simulation as accurate as possible, for example by doing a matching analysis as described here. As better well measurements become available, rerun the discharge simulations and output simulations.

TopDown or BottomUp

A discharge simulation can be TopDown or BottomUp:

How WellSim calculates a discharge simulation


Note:

The simulation is only in the wellbore where fluid is flowing; therefore:

  1. The simulation does not extend:

    • Out beyond the wellhead.

    • In the wellbore below the deepest feedzone. If you specify a finish depth below the deepest feed, WellSim will calculate the correct conditions down to the deepest feed, but the calculated conditions below this will be meaningless.

    • Out of the well and into the reservoir through the deepest feedzone.

  2. The simulation does not need to know the properties of the deepest feedzone (nor the reservoir pressure at the deepest feedzone).

    The simulation does need to know the properties of any secondary feedzones, because these affect the flow of fluid in the well. Specify these in a secondary feedzone dataset for thge well.

WellSim's equations

WellSim applies some theoretical and empirical equations in order to calculate the conditions along the wellbore.

The theoretical equations are the conservation of mass, the conservation of energy and the conservation of momentum. In addition, where the flow is purely single phase (liquid or dry steam) there are theoretical equations governing the flow. However, there are no such theoretical equations for two-phase flow, and WellSim uses empirical equations developed by engineers. You can choose two types of equation:

Note that simulations for deviated wells with two-phase flow are less accurate than for vertical wells, because flow regimes have been studied only for vertical wells. The flow is likely to transition from one regime to another at different physical conditions (pressure/temperature/flow) in a deviated well because gravity will pull the fluid towards the side of the well.

Simulation error: Solution did not converge

At some points in a wellbore conditions change rapidly, for example at the flash point, where the wellbore changes diameter or at a secondary feedzone. If by chance WellSim's algorithms try to calculate conditions at a depth near such a point, then the calculated conditions can oscillate from one state to another, and WellSim can not calculate accurate conditions. WellSim detects this, stops the algorithm and gives the error Solution did not converge. WellSim uses flow simulations throughout, so this error can happen anywhere in WellSim.

Fix the error by changing the simulation's depth increment slightly.


Output simulations

An output simulation requires data in the wellbore at the deepest feedzone. The simplest way to provide this by specifying a discharge simulation (which contains most of the required data), or else you can just enter data at the deepest feedzone. Discharging a well at a steady state is expensive, so an output simulation is geared to using measurements at only one (maybe two) mass flowrates.

TopDown, BottomUp or TestData output simulations

There are three types of output simulations (TopDown, BottomUp or TestData); use the one appropriate to the measurements that you have and what you want to achieve:

1 - TopDown output simulations - for actual wells

Use TopDown output simulations to calculate output curves for actual wells.

For a TopDown output simulation:

Drawdown relationship Specify
Linear One TopDown discharge simulation
Quadratic Two TopDown discharge simulations
Steam One TopDown discharge simulation, plus enter the steam exponent

2 - BottomUp output simulations - for what-if scenarios

Use BottomUp output simulations to model the effects of future changes in the well or field (what-if scenarios). For example, you can find the effect on the output curve of a different wellbore diameter or the effect of a different reservoir pressure.

For a BottomUp output simulation:

Drawdown relationship Specify
Linear One BottomUp discharge simulation
Quadratic Two BottomUp discharge simulations
Steam One BottomUp discharge simulation plus the steam exponent

A BottomUp output simulation has several options. Until you become familiar with output simulations, we suggest using BottomUp output simulations for what-if scenarios by following these steps (these are for Linear and Steam; for Quadratic, create two BottomUp discharge simulations):

  1. Make a copy of an existing TopDown discharge simulation for the well and open the copy for editing.

  2. Change Test Direction to BottomUp.

  3. Change some of the discharge simulation's data to suit your what-if scenario. For example, to find the effect of a different wellbore diameter, change the geometry configuration to a new one, with different diameters. You must assume that the data you change would not affect any of the data you don't change.

  4. Run the BottomUp discharge simulation.

  5. Create a new BottomUp output simulation:

    • Specify your new BottomUp discharge simulation.

    • Un-tick Calc Drawdown and enter drawdown factors for deepest feedzone; usually use factors that WellSim has calculated for an earlier TopDown output simulation for the well.

    • Enter other data to suit your what-if scenario, for example enter the known reservoir pressure or, if your what-if scenario involves a different reservoir pressure, enter a different pressure.

  6. Run the BottomUp output simulation.

There are different degrees of what-if scenario:

3 - TestData output simulations - for data at the deepest feedzone

Normally use a TestData output simulation to calculate a preliminary output curve from injection measurements from a well's completion tests, see this tutorial. You could use a TestData output simulation for what-if scenarios, but it is usually simpler to run a BottomUp output simulation, described above.

For a TestData output simulation:

How WellSim calculates an output simulation

An output simulation calculates conditions from the undisturbed reservoir up to the wellhead for a range of mass flowrates. Therefore, the output simulation needs to know information about:

An output simulation proceeds like this:

  1. If it can and if you ask it to, it will calculate the drawdown factors. For a linear simulation:

    a = (P_res - P_feed) / W

    and P_res - P_feed must obviously be at the flow rate W.

  2. It runs BottomUp discharge simulations from the undisturbed reservoir, across the deepest feedzone and up the well to the wellhead for the range of mass flowrates that you specify. For each mass flowrate:

    • First, it calculates the pressure in the well at the deepest feed. For a Linear simulation:

      P_feed = P_res - a x W

      Where W and P_feed are for the particular flow simulation being run.

    • Then it does a BottomUp discharge simulation, using this data:

      • For the two fluid parameters: P_feed calculated above and the parameter you select to be the Constant Parameter; usually enthalpy because it is easiest to estimate.

      • For the fluid impurities: values you enter for the output simulation.

      • For the well data: a geometry configuration, the secondary feedzones (if the well has any secondary feedzones) any formation temperatures. For TopDown and BottomUp output simulations, WellSim extracts these from the discharge simulation that you specify.

  3. Finally, it extracts from these BottomUp discharge simulations data (in particular pressure) at the wellhead and at the deepest feed, which it stores as the output simulation. Then it deletes these BottomUp discharge simulations.


Injection simulations

An injection simulation is similar to a discharge simulation, except the fluid goes into the well:


Injectivity simulations

An injectivity simulation is similar to an output simulation, except the fluid goes into the well.

During a well's completion tests, it is easy to inject a well at several relatively low wellhead pressures and measure the mass flowrates; an injectivity simulation is geared to use these measurements. The result of the injectivity simulation is also wellhead pressure and mass flowrates. In effect, what WellSim does is to extrapolate the low-pressure measurements to higher pressures and mass flowrates.

TopDown, BottomUp or TestData injectivity simulations

Choose TestData, TopDown or BottomUp depending on the measurements you have and what you want to achieve. It is usually best to make measurements so that you can choose TestData, because this will calculate the injectivity factors and the reservoir pressure. TopDown or BottomUp require you to estimate reservoir pressure, and it is hard to do this straight after drilling, when pressure near well is likely to be considerably higher than the actual reservoir pressure.


When to choose TestData:

TestData is usually the best choice. Choose TestData when you:

Enter the injection measurements into a measured injectivity curve and use this for the injectivity simulation read how:

You might suspect secondary loss zones from:

Fluid loss at a secondary loss zone will slightly affect the downhole pressure and temperature profiles but will strongly affect the apparent injectivity factor at the deepest feedzone.


When to choose TopDown:

Choose TopDown if you only have measurements at one or two mass flowrates for an actual well, or you suspect there are secondary losszones. Use the measurements to run one or two TopDown injection simulations, then use them for the TopDown injectivity simulation read how.

The accuracy of a TopDown injectivity simulation depends on the accuracy of its TopDown injection simulation(s). If you have pressure measurements at several mass flowrates:


When to choose BottomUp:

Choose BottomUp if you want to run what-if scenarios, for example to find how the injectivity curve changes with changes in reservoir pressure. The general method is the same as for a what-if scenario for an output simulation read more, and you need to run one or two BottomUp injection simulations first.


Note:

Injection Test Type Injectivity factors Reservoir pressure
TopDown Is calculated Specify
BottomUp Is calculated or specify Specify
TestData Is calculated or specify Is calculated or specify

Choosing an injectivity relationship

Choose Linear, Quadratic or Power Law. Normally, choose Linear unless:

Choosing the injectivity relationship from the shape of the measured injectivity curve

If friction is low, then the shape of the measured injectivity curve will be the same as the shape of the pressure/mass flowrate curve at the deepest feedzone (the injectivity relationship). And therefore you can find the injectivity relationship from the shape of the measured injectivity curve:

  1. For your measured injectivity curve, look at a quickgraph of pressure (left axis) against mass flowrate (bottom axis).

  2. Imagine a straight line fitted to the points on the graph (and not through the 0,0 point of the graph). In the diagrams below, your imagined line is purple and the orange crosses are your measured injectivity points.

Then:

Here's an example

There are four measurements on the measured injectivity curve:

However

Therefore, Linear is usually a good choice because it is simpler.

How WellSim calculates an injectivity simulation

An injectivity simulation is essentially the same as an output simulation. However, a TestData injectivity simulation is different to a TestData output simulation because: