54
How to speed up an ECLIPSE run: ECLIPSE Convergence Version 2 December 2009 1. Introduction .................................................................................................................................................................... 2 A case study.................................................................................................................................................................... 2 2. Background to timesteps and iterations .......................................................................................................................... 6 2.1 Reports of timesteps and iterations ........................................................................................................................... 7 3. Report Steps ................................................................................................................................................................... 8 4. Timesteps ....................................................................................................................................................................... 9 4.1 Maximum Timestep .................................................................................................................................................. 9 4.2 Maximum Timestep after a well change ................................................................................................................. 10 Summary: Using TUNING ........................................................................................................................................... 11 Rule 1 ....................................................................................................................................................................... 11 Rule 2 ....................................................................................................................................................................... 11 Rule 3 ....................................................................................................................................................................... 11 5. Non-Linear Convergence Criteria ................................................................................................................................ 12 5.1 A simple 1-variable example .................................................................................................................................. 13 5.2 Definition of convergence ...................................................................................................................................... 16 5.3 Definition of non-linear iterations .......................................................................................................................... 17 5.4 Two-variable example ............................................................................................................................................ 17 5.5 Definition of convergence ...................................................................................................................................... 21 5.6 Tracking the source of the problem ........................................................................................................................ 23 5.6.1 ECLIPSE 100 .................................................................................................................................................. 23 5.6.2 ECLIPSE 300 .................................................................................................................................................. 27 5.6.3 Discussion on Non-Linearity ........................................................................................................................... 30 5.6.4 Non-Linear Divergence ................................................................................................................................... 30 5.6.5 Summary: How to identify problem cells ........................................................................................................ 35 6. Improving the data ........................................................................................................................................................ 36 6.1 Messages,Comments, Warnings ............................................................................................................................. 36 6.2 Problems, Errors, Bugs and NaNs .......................................................................................................................... 37 6.3 What to look for in different Sections .................................................................................................................... 38 6.3.1 GRID data ....................................................................................................................................................... 38 6.3.2 SCAL data ....................................................................................................................................................... 40 6.3.3 PVT data.......................................................................................................................................................... 45 6.3.4 SOLUTION data ............................................................................................................................................. 48 6.3.5 SUMMARY section ........................................................................................................................................ 50 6.3.6 SCHEDULE data ............................................................................................................................................ 50 7. Summary: Convergence................................................................................................................................................ 52 7.1 Convergence problem Checklist ............................................................................................................................. 53

ECLIPSE Convergence

Embed Size (px)

DESCRIPTION

Eclipse Convergance error problem solving workflow

Citation preview

  • How to speed up an ECLIPSE run:

    ECLIPSE Convergence

    Version 2 December 2009

    1. Introduction .................................................................................................................................................................... 2 A case study .................................................................................................................................................................... 2

    2. Background to timesteps and iterations .......................................................................................................................... 6 2.1 Reports of timesteps and iterations ........................................................................................................................... 7

    3. Report Steps ................................................................................................................................................................... 8 4. Timesteps ....................................................................................................................................................................... 9

    4.1 Maximum Timestep .................................................................................................................................................. 9 4.2 Maximum Timestep after a well change ................................................................................................................. 10 Summary: Using TUNING ........................................................................................................................................... 11

    Rule 1 ....................................................................................................................................................................... 11 Rule 2 ....................................................................................................................................................................... 11 Rule 3 ....................................................................................................................................................................... 11

    5. Non-Linear Convergence Criteria ................................................................................................................................ 12 5.1 A simple 1-variable example .................................................................................................................................. 13 5.2 Definition of convergence ...................................................................................................................................... 16 5.3 Definition of non-linear iterations .......................................................................................................................... 17 5.4 Two-variable example ............................................................................................................................................ 17 5.5 Definition of convergence ...................................................................................................................................... 21 5.6 Tracking the source of the problem ........................................................................................................................ 23

    5.6.1 ECLIPSE 100 .................................................................................................................................................. 23 5.6.2 ECLIPSE 300 .................................................................................................................................................. 27 5.6.3 Discussion on Non-Linearity ........................................................................................................................... 30 5.6.4 Non-Linear Divergence ................................................................................................................................... 30 5.6.5 Summary: How to identify problem cells ........................................................................................................ 35

    6. Improving the data ........................................................................................................................................................ 36 6.1 Messages,Comments, Warnings ............................................................................................................................. 36 6.2 Problems, Errors, Bugs and NaNs .......................................................................................................................... 37 6.3 What to look for in different Sections .................................................................................................................... 38

    6.3.1 GRID data ....................................................................................................................................................... 38 6.3.2 SCAL data ....................................................................................................................................................... 40 6.3.3 PVT data.......................................................................................................................................................... 45 6.3.4 SOLUTION data ............................................................................................................................................. 48 6.3.5 SUMMARY section ........................................................................................................................................ 50 6.3.6 SCHEDULE data ............................................................................................................................................ 50

    7. Summary: Convergence ................................................................................................................................................ 52 7.1 Convergence problem Checklist ............................................................................................................................. 53

  • 1. Introduction

    This document describes how to improve the convergence and the speed of the

    ECLIPSE simulators by simple changes to the data file.

    The data chosen to model the reservoir may be such that the simulator can only

    solve the model by taking extremely short timesteps or excessive amounts of cpu

    time. Making small changes to the model or adding new options or new keywords

    can sometimes lead to dramatic improvements in the speed of the simulation

    without changing the results to engineering accuracy. We will show what

    changes can speed up the run in this way.

    If the data cannot be changed, convergence criteria can sometimes be chosen to

    improve simulator performance. You do not normally need to change convergence

    criteria, and we advise you not to do so unless necessary; internal parameters

    in ECLIPSE will usually give you a stable and robust solution for your model, in

    a reasonable cpu time, although of course a big complex model will take longer

    to run than a small simple model. In some cases, however, the results of a run

    can depend on the convergence criteria and how they are applied, and there is a

    trade-off between accuracy and speed. We will show how to detect these cases

    and how to choose suitable convergence criteria.

    Recognizing and correcting the cause of convergence problems is an important

    part of simulation. We will look at what you can do if a model fails to

    converge, or when it takes a long time to converge. We will show that:

    1. Failure to converge is not (usually) due to a bug in ECLIPSE. It is usually related to the data.

    2. Failure to converge Linear iterations is not always something to worry about.

    3. Failure to converge a minimum timestep can affect the validity of the results.

    ECLIPSE can output a lot of messages, warnings, etc. You need to know what

    should you do about them, which ones you can safely ignore, and which ones need

    some action from you. You can also ask ECLIPSE to produce reports showing how

    both linear and non-linear iterations are proceeding and the methods by which

    time steps are selected. We will look at these reports.

    Most of the advice and suggestions apply equally to all the simulators. When

    there are differences in the detailed treatment between ECLIPSE Black Oil and

    ECLIPSE Compositional we will highlight these differences and explain how the

    data for each simulator can be tuned to improve performance.

    A case study

    We received an ECLIPSE model from a client. The model was chopping timesteps and the model was taking many hours to run, which was unexpected given the size

    of the model. We were asked if we could speed up the runs.

    We looked at the evidence. The main suspect was one of the production wells, so

    we looked at the data for that well in detail:

    -- WELL SPECIFICATION DATA

    --

    WELSPECS

    --

  • -- WELL GROUP LOCATION BHP PI

    -- NAME NAME I J DEPTH DEFN

    --

    PRODUCER G 10 10 8400 'OIL' /

    /

    -- COMPLETION SPECIFICATION DATA

    --

    COMPDAT

    --

    -- WELL LOCATION OPEN/ SAT CONN

    -- NAME I J K1 K2 SHUT TAB FACT

    --

    PRODUCER 10 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 9 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 8 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 7 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 6 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 5 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 4 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 3 10 3 3 OPEN 0 -1 0.5 /

    PRODUCER 2 10 3 3 OPEN 0 -1 0.5 /

    /

    Both the well specification data and the completion data looked OK. The well

    production controls also looked OK. We looked at the photographic evidence. From the COMPDAT information we can see that the well is a horizontal well

    completed in layer 3. From the geometry information we knew that layer 3 was a

    dipping layer, so we expected to see a picture similar to

    What we saw was very different:

  • Investigations showed that the run was a Restart run. The run had been part of

    in investigation as to whether the proposed well should be completed in layer 2

    or layer 3. There had been some confusion over the names of the runs, and the

    base run had the well completed in layer 2 but the restart had the well

    completed in layer 3. ECLIPSE read the new COMPDAT data and concluded that it

    represented a workover, so the well now had completions in both layers. As

    there was poor communication between layer 2 and layer 3 and different pressures

    history in each, this created severe cross-flow. The cross-flow was the cause

    of the convergence issues and the poor performance.

    This short case study demonstrates that before we can solve a problem we need to

    know where the problem is. So what made us suspect this well? If a run is

    misbehaving, how do we find clues that will point us towards the source of the

    problem? More generally, how do we speed up an ECLIPSE run? What runs can be

    speeded-up?

    In fact all runs can be speeded up. There are three general solutions:

    1. Hardware solutions - Get a faster machine. A new computer may be twice as fast as the

    equivalent computer from two years ago.

    - Make sure no other jobs are running on your computer. If you are

    running on a cluster, check that there is no contention for memory or

    other resources on the nodes on which your job is running.

    - Run in parallel. This will not speed up your run if there are

    convergence issues in serial mode. If your model is running smoothly but

    slowly on one processor, try running in parallel on two. If it speeds up,

    try running on four processors.

    2. Reduce the size of the model

    - Can you reduce the number of grid blocks without affecting the quality

    of the solution? For instance can you replace a large number of water-

    filled blocks with an analytic aquifer?

    - If you are running in compositional mode, can you model your fluid with

    fewer pseudo-components?

    3. Identify data issues

    - Can you gain any speed by changing the time-stepping?

    - Can you identify the cause of any convergence problems?

  • In the following chapter we will explain:

    How to get more information

    What the details of the output mean

    What to look for in the data

    How to fix some of the problems

  • 2. Background to timesteps and iterations

    An ECLIPSE simulation is made up of one or more report steps.

    A report step is made up of one or more time steps.

    A time step is made up of one or more non-linear iterations.

    A non-linear iteration is made up of one or more linear iterations.

    When you set up the data model to run ECLIPSE, you are asked to specify the

    report steps that you want. You therefore have direct control of the number of

    report steps and the time gap between them. Reducing the number of report steps

    can sometimes reduce the cpu time.

    ECLIPSE has default values that control how many timesteps will be used to reach

    the next report that you have asked for. These default values will work well in

    most cases, but there are times when you may need to adjust some of the defaults

    so that the simulation takes fewer timesteps. In many (but not all) cases, fewer

    time steps will lead to less cpu time. In some difficult cases, reducing the

    maximum timestep may speed up the run.

    Different default values also control how many non-linear iterations will be

    used to solve each timestep. These values should normally be left unchanged.

    In a few cases, adjustments to the convergence criteria can improve the

    performance of the simulator. In most cases however the greatest improvements

    in performance are obtained by identifying the cause of the non-linear problem

    and changing the data model to reduce the non-linearity. The major part of this

    document will explain how to avoid problems of this type, and how to find and

    fix the problems if they do occur.

    By the time problems occur in the linear iterations, it is usually too late to

    fix them by adjusting the linear convergence control. Some controls can be

    changed in extreme circumstances, but the best advice is to avoid such problems

    by controlling the timestepping and the non-linear iterations.

  • 2.1 Reports of timesteps and iterations

    The number of report steps, time steps and non-linear iterations can be found in

    both the PRT file and the LOG file - the shorter form of output which appears on

    the screen (for interactive runs) or is sent to a log file (for batch or

    background runs). On Linux (or Unix) systems, you can use the grep command to

    find all the necessary information; on PCs you may need to use your favourite

    editor and find the information one line at a time. Details are reported in a

    different way in ECLIPSE 100 and ECLIPSE 300.

    ECLIPSE 100

    For a Linux system and an ECLIPSE 100 log file called BASE.LOG, the command

    grep TSTEP BASE.LOG >BASE.STEPS100

    will create a file BASE.STEPS100 that will contain one line for each timestep.

    Each line will be of the form:

    STEP 15 TIME= 400.00 DAYS ( +30.0 DAYS REPT 3 ITS) (4-FEB-2003)

    "STEP 15" means this is the 15th timestep.

    "TIME= 400.00 DAYS" means there have been 400 simulated days since the beginning

    of the simulation.

    "+30.0 DAYS" shows that the latest timestep was of 30 days.

    "REPT" is a mnemonic explaining why 30 days were chosen. "REPT" means that a

    report step has been reached.

    "3 ITS" mean 3 non-linear iterations were needed to solve the 30 day timestep.

    "(4-FEB-2003)" is the current simulation date.

    For a number of timesteps, the BASE.STEPS100 file will look like this:

    STEP 1 TIME= 2.40 HOURS ( +2.40 HOURS INIT 4 ITS) (19-OCT-1982)

    STEP 2 TIME= 9.60 HOURS ( +7.20 HOURS MAXF 2 ITS) (19-OCT-1982)

    STEP 3 TIME= 1.30 DAYS (+21.60 HOURS MAXF 2 ITS) (20-OCT-1982)

    STEP 4 TIME= 4.00 DAYS ( +2.7 DAYS MAXF 3 ITS) (23-OCT-1982)

    STEP 5 TIME= 12.10 DAYS ( +8.1 DAYS MAXF 3 ITS) (31-OCT-1982)

    STEP 6 TIME= 29.22 DAYS ( +17.1 DAYS TRNC 4 ITS) (17-NOV-1982)

    STEP 7 TIME= 49.63 DAYS ( +20.4 DAYS TRNC 4 ITS) (7-DEC-1982)

    STEP 8 TIME= 81.72 DAYS ( +32.1 DAYS TRNC 4 ITS) (8-JAN-1983)

    STEP 9 TIME= 130.36 DAYS ( +48.6 DAYS TRNC 5 ITS) (26-FEB-1983)

    STEP 10 TIME= 205.31 DAYS ( +75.0 DAYS TRNC 3 ITS) (12-MAY-1983)

    STEP 11 TIME= 285.16 DAYS ( +79.8 DAYS HALF 3 ITS) (31-JLY-1983)

    STEP 12 TIME= 365.00 DAYS ( +79.8 DAYS REPT 3 ITS) (19-OCT-1983)

    ECLIPSE 300

    For a Linux system and an ECLIPSE 300 log file called BASE.LOG, the command

    grep ";" BASE.LOG >BASE.STEPS300

    will create a file BASE.STEPS300 that will contain one line for each timestep of

    the form:

    Rep ; 400.0 30.0 8.7838 .19498 1.4E05 32884. 1.2E06 4843.6 .00000 1.3E06 3

    "Rep" is the mnemonic that shows that a report step has been reached,

    "30.0" shows that the latest timestep was of 30 days,

    the next 8 numbers show the GOR, water cut, oil/gas/water production rates,

    average field pressure, and gas and water injection rates,

    "3" at the end of the line means that 3 non-linear iterations were needed to

    solve the 30-day timestep.

  • If the AIM option is used then the line will have and extra number at the end,

    Rep ; 400.0 30.0 8.7838 .19498 1.4E05 32884. 1.2E06 4843.6 .00000 1.3E06 3 2%

    2% shows the percentage of the cells that was solved fully implicitly.

    For a number of timesteps, the BASE.STEPS300 file will look like this:

    Init ; 1.0 1.0 484.94 .01293 2.2E06 29221. 1.1E09 224.40 0.0 0.0 3 3%

    MIF ; 3.0 2.0 484.94 .01459 1.9E06 28463. 9.3E08 224.36 0.0 0.0 3 3%

    MIF ; 7.0 4.0 484.94 .01857 1.5E06 28320. 7.3E08 224.29 0.0 0.0 2 3%

    MIF ; 15.0 8.0 484.94 .02635 1.0E06 28039. 5.0E08 224.20 0.0 0.0 3 3%

    Rep ; 31.0 16.0 484.94 .04014 6.6E05 27512. 3.2E08 224.08 0.0 0.0 3 3%

    Rep ; 59.0 28.0 484.94 .05838 4.3E05 26824. 2.1E08 223.94 0.0 0.0 3 3%

    Rep ; 90.0 31.0 484.94 .07354 3.3E05 26277. 1.6E08 223.81 0.0 0.0 4 3%

    Rep ; 120.0 30.0 484.94 .08489 2.8E05 25872. 1.4E08 223.70 0.0 0.0 3 3%

    Rep ; 151.0 31.0 484.94 .09449 2.4E05 25539. 1.2E08 223.59 0.0 0.0 3 3%

    Rep ; 181.0 30.0 484.94 .10268 2.2E05 25271. 1.1E08 223.50 0.0 0.0 3 3%

    Rep ; 212.0 31.0 484.94 .11039 2.0E05 25037. 9.8E07 223.40 0.0 0.0 3 3%

    Rep ; 243.0 31.0 484.94 .11760 1.9E05 24834. 9.0E07 223.32 0.0 0.0 3 3%

    Rep ; 273.0 30.0 484.94 .12423 1.7E05 24658. 8.4E07 223.23 0.0 0.0 3 3%

    Rep ; 304.0 31.0 484.94 .13075 1.6E05 24494. 7.9E07 223.15 0.0 0.0 3 3%

    Rep ; 334.0 30.0 484.94 .13683 1.5E05 24350. 7.4E07 223.08 0.0 0.0 3 3%

    Rep ; 365.0 31.0 484.94 .14290 1.5E05 24213. 7.0E07 223.00 0.0 0.0 3 3%

    Timestep Reason

    Some of the more common reasons for timestep selection are:

    Mnemonic Explanation

    E100 E300

    INIT Init first timestep

    MAXF MIF maximum increase factor

    REPT Rep report step

    HREP Hrep half step to report

    CHOP Redu timestep chopped

    DIFF follows CHOP

    TRNC TTE TTE limit

    SCT Solution Change

    TPT Throughput Limit

    A more complete list is available in the ECLIPSE Technical Description manual,

    in the section on Convergence.

    3. Report Steps

    The number of report steps and the time between report steps will depend on the

    type of model that you are simulating:

    For a prediction or forecasting run lasting for instance 30 years you may for instance ask for monthly reports for the first year, quarterly reports for

    the next 5 years, and yearly reports for the rest of the simulation.

    For history matching you may ask for weekly reports for the first year and for monthly reports for remainder of the history match, to test the validity

    of your model on a finer time scale.

    For slim-tube experiments, reporting intervals are likely to be minutes and hours

  • Computing time may be reduced by changing the requested reports if the following

    three conditions apply:

    1. You are asking for more reports than you actually need 2. Each report step is being reached in just a single timestep 3. Each time step is being solved in a small number of non-linear iterations.

    By small we ideally mean one, but savings could also be made if the timestep

    is taking 2 or 3 iterations.

    If you have created a file BASE.STEPS100 and find that it mainly contains lines

    of the form:

    STEP 40 TIME= 400.00 DAYS ( +10.0 DAYS REPT 1 ITS) (4-FEB-2003)

    STEP 41 TIME= 410.00 DAYS ( +10.0 DAYS REPT 1 ITS) (14-FEB-2003)

    STEP 42 TIME= 420.00 DAYS ( +10.0 DAYS REPT 1 ITS) (24-FEB-2003)

    STEP 43 TIME= 430.00 DAYS ( +10.0 DAYS REPT 1 ITS) (6-MAR-2003)

    so that each timestep is a report step, and each timestep is solved in one

    iteration, then the run may go 2 or 3 times faster if you allow the simulator to

    produce report steps once a month instead of once every 10 days.

    The example above was for an ECLIPSE 100 run. The same applies for an ECLIPSE

    300 or 500 run with:

    Rep ; 400.0 10.0 8.7838 .19498 1.4E05 32884. 1.2E06 4843.6 .00000 1.3E06 1

    Rep ; 410.0 10.0 8.7838 .19498 1.4E05 32884. 1.2E06 4843.5 .00000 1.3E06 1

    Rep ; 420.0 10.0 8.7838 .19498 1.4E05 32884. 1.2E06 4843.4 .00000 1.3E06 1

    Rep ; 430.0 10.0 8.7838 .19498 1.4E05 32884. 1.2E06 4843.3 .00000 1.3E06 1

    4. Timesteps

    Having reached one report step, ECLIPSE will decide what timestep to take next

    according to:

    how easy or difficult the previous timestep was

    how the convergence of the previous time step compared with the convergence targets

    how much simulation time is left until the next report step

    whether either you or the default limits forced it to take a particular time step

    You can set the timestep limits by using the TUNING keyword in any of the

    ECLIPSE simulators, or by using the TSCRIT keyword in ECLIPSE 300 or 500.

    4.1 Maximum Timestep

    The first example of how a run can be speeded-up is similar to the report step

    example already given. If you have created a file BASE.STEPS100 and find that it

    mainly contains lines of the form:

    STEP 40 TIME= 400.00 DAYS ( +10.0 DAYS MAXS 1 ITS) (4-FEB-2003)

    STEP 41 TIME= 410.00 DAYS ( +10.0 DAYS MAXS 1 ITS) (14-FEB-2003)

    STEP 42 TIME= 420.00 DAYS ( +10.0 DAYS MAXS 1 ITS) (24-FEB-2003)

    STEP 43 TIME= 430.00 DAYS ( +10.0 DAYS MAXS 1 ITS) (6-MAR-2003)

    The mnemonic MAXS means that this timestep is the maximum allowed according to

    the TUNING keyword. Again we see that each timestep is a report step, and each

    timestep is solved in one iteration, and the run may go 2 or 3 times faster if

    you allow the simulator to produce report steps once a month instead of once

  • every 10 days. For ECLIPSE 300 the mnemonic is "Max", and you can set the

    maximum timestep either using the TUNING or the TSCRIT keyword.

    The syntax to set the maximum timestep to 30 days using the TUNING keyword is:

    TUNING

    1* 30 /

    /

    /

    The TUNING keyword is available in both ECLIPSE 100 and in ECLIPSE 300. ECLIPSE

    300 also has the TSCRIT and CVCRIT keywords; TSCRIT is timestep control and

    CVCRIT is convergence control. Approximately, TSCRIT + CVCRIT = TUNING

    To set the maximum timestep to 30 days using TSCRIT:

    TSCRIT

    2* 30 /

    Note that the default maximum timestep in ECLIPSE 100 is 365 days and in ECLIPSE

    300 is 50 days. The limit will only be 10 days if it has been set to 10 in a

    TUNING or TSCRIT keyword.

    The maximum timestep should be compatible with the report step interval. If you

    are asking for a report at the beginning of each month and have a timestep limit

    of 30 days, then those months with 31 days will need at least two timesteps.

    Increasing the timestep limit to 31 days would allow every month to be covered

    in one timestep if there were no other limitations. If you are asking for

    reports every 3 months, the maximum timestep should be at least 92 days.

    You may sometimes help the non-linear solver by setting a lower value for the

    maximum timestep size. If the simulator is frequently chopping timesteps and

    you cannot find the cause as described in section 5 below, then reducing the

    maximum timestep can speed up the run. For instance if the simulator converges

    all steps less than 20 days but chops steps over 20 days, then a 20 day limit

    will reduce computing time. You can always allow the timesteps to increase

    later in the simulation, after a difficult modelling problem has been overcome.

    You should however always first try to fix the cause of the problem before

    fixing the symptom.

    4.2 Maximum Timestep after a well change

    A similar inefficiency can arise with the maximum step after a well change.

    There is a default limit of how big a timestep can be taken immediately after

    any well keyword has been used. The default value for ECLIPSE 300 is 20 days,

    and the default for ECLIPSE 100 is unlimited. If you are history matching and setting new well rates at the beginning of each month, then ECLIPSE 300 will be

    unable to take any timestep greater than 20 days. Rather than simulate January

    for example with a 20-day timestep followed by an 11-day timestep, ECLIPSE will

    even-out the timesteps by having two 15.5-day timesteps. The mnemonic for this

    choice of timestep is 'HALF' in ECLIPSE 100 and 'HRep' in ECLIPSE 300. The

    timestep summary will then be:

    STEP 1 TIME= 15.50 DAYS ( +15.5 DAYS HALF 1 ITS) (15-JAN-2002)

    STEP 2 TIME= 15.50 DAYS ( +15.5 DAYS REPT 1 ITS) ( 1-FEB-2002)

    STEP 3 TIME= 14.00 DAYS ( +14.0 DAYS HALF 1 ITS) (14-FEB-2002)

    STEP 4 TIME= 14.00 DAYS ( +14.0 DAYS REPT 1 ITS) ( 1-MAR-2002)

    STEP 5 TIME= 15.50 DAYS ( +15.5 DAYS HALF 1 ITS) (15-MAR-2002)

    STEP 6 TIME= 15.50 DAYS ( +15.5 DAYS REPT 1 ITS) ( 1-APR-2002)

    STEP 7 TIME= 15.00 DAYS ( +15.0 DAYS HALF 1 ITS) (15-APR-2002)

    Increasing the maximum step after a well change to be more than 31 days could

    improve the timestepping to be:

  • STEP 1 TIME= 31.00 DAYS ( +31.0 DAYS REPT 1 ITS) ( 1-FEB-2002)

    STEP 2 TIME= 28.00 DAYS ( +28.0 DAYS REPT 1 ITS) ( 1-MAR-2002)

    STEP 3 TIME= 31.00 DAYS ( +31.0 DAYS REPT 1 ITS) ( 1-APR-2002)

    You may want to reduce the maximum timestep after a well change. If for

    instance you expect a major change in reservoir behaviour every time you change

    the well controls, then you can save cpu time by setting this value to for

    instance 1 day, using

    TUNING

    9* 1 /

    /

    /

    or

    TSCRIT

    10* 1 /

    Summary: Using TUNING

    Rule 1

    Dont use TUNING (or TSCRIT or CVCRIT) Rule 1a:

    Remove these keywords if they are already there.

    Rule 2

    OK, if you have to:

    You can change the initial, minimum, or maximum timestep

    If you change the minimum, remember to also change the minimum choppable step

    If you change the maximum, make it consistent with report steps (for instance

    have a maximum of 31 days not a maximum of 30 days)

    Rule 3

    Convergence controls: remember rule 1

    Look for most common reason for the selection of the timestep size

    Look for most common reason for a chopped timestep

    If you have poor convergence, it is sometimes better to tighten convergence

    controls than to weaken them. This is discussed below.

  • 5. Non-Linear Convergence Criteria

    The equations that the simulators are trying to solve are non-linear. By non-

    linear we mean that for instance doubling the tubing-head pressure of a water

    injector will not usually double the amount of water injected, and doubling the

    oil saturation in a grid block will not usually double the oil mobility in that

    grid block.

    The simulators use an iterative process based on Newton's method to solve these

    non-linear equations:

    1. We linearise the equations

    2. We solve the linear equations

    3. We check if this linear solution gives us a good enough non-linear solution.

    4. If it does then we move to the next timestep. If not we calculate the change needed to improve the solution, then go back to step 1.

    Non-linear iteration

    Linearize the Equations

    Iterate to solve the linear equations

    Plug the linear solution into the

    non-linear equation

    Is the solution good?

    Advance Timestep

    No

    Yes

  • 5.1 A simple 1-variable example

    We can demonstrate the method for the simple case of a function of one variable

    only. Suppose F is a continuous monotonic function of x, and that F(x)=0 for

    some value of x. We want to find this value of x. We start by guessing a value

    for x. Lets call this first guess x0. We calculate F(x0) to see if F(x0)=0.

    In this case F(x0) is not zero so x0 is not the answer. Our next step is to

    linearise the problem by calculating the gradient of f(x) at x=x0.

  • We cannot easily solve F(x)=0 so we solve an approximation to F(x), and the

    approximation here is a straight line. We solve to give us the value of x at

    which the straight line of the gradient cuts the x axis. This value is x1, and

    is an improvement on our initial guess of x0.

    We now calculate F(x1) to see if F(x1)=0.

  • F(x1) is not zero, so x1 is not the answer we are looking for. Our next step is

    to linearise the problem again by calculating the gradient of f(x) at x=x1.

    We calculate the gradient of F at x1, solve the linear equation (the gradient

    equation) and obtain a new solution x2. We then check F(x2)to see if it is

    zero. As F(x2) is not zero, we continue our iterations and calculate the

    gradient of F at x2. This leads us to our third estimate of the solution, x3.

    Although F(x3) is not exactly zero, we decide that it is close enough for

    engineering accuracy, and accept x3 as our solution.

  • 5.2 Definition of convergence

    The convergence criteria are different in ECLIPSE 100 and ECLIPSE 300.

    In ECLIPSE 100, the convergence criterion is as defined above. The absolute

    value of F has to be less than a defined limit.

  • In ECLIPSE 300, the calculation of F is expensive as it involves flash

    calculations. For this reason, the criterion for convergence is that the change

    in x since the last iteration should be small.

    In the case of Dual Porosity ECLIPSE 100 runs, the TUNINGDP keyword will accept

    iterations as converged if either the residual or the solution change is small

    enough. The TUNINGDP keyword is sometimes helpful for high throughput cases.

    5.3 Definition of non-linear iterations

    Each time the simulator goes through steps 1 to 3, it performs one non-linear

    iteration. The total number of times the simulator goes through these steps for

    each timestep is the number of non-linear iterations for that timestep. In the

    example given, there are 4 iterations, a first guess plus 3 improved values.

    There is a limit to the number of non-linear iterations that the simulators will

    try before giving up and trying with a smaller timestep. This limit depends on

    the simulator and on the solution method, and is set using either the TUNING or

    the CVCRIT keyword.

    You can check on how well the model is converging to a solution by looking at

    the number of non-linear iterations for each timestep, as described in section

    2.1:

    - 1 non-linear per timestep means the step was very easy to converge

    - 2 to 3 non-linears per timestep means the step was easy to converge

    - 4 to 9 non-linears per timestep shows an increasingly difficult problem

    - > 10 non-linears per timestep can mean a problem with the model

    5.4 Two-variable example

    We can generalise the one-variable example above to two variables, and

    demonstrate how the iteration procedure works in ECLIPSE for two variables.

    Consider a hill-climbing problem. Mathematically we have a function F of two

  • variables x and y, and we want to find the value of x and the value of y for

    which F is a maximum. We can think of this as trying to climb to the top of a

    smooth rounded hill when it is so foggy that we can only see our feet. Suppose

    the hill is described by the contour lines below:

    We start at an initial position x0.

    As with the 1-D case, we first check whether x0 is the solution. Mathematically

    we want to check if two orthogonal derivatives are zero, and if not then we want

    to calculate a planar approximation to the surface at x0. On our hill we do

    this by taking one small step in any direction, returning to our starting point,

    then taking another small step at right angles to the first. If the slopes in

    both directions are zero then we are at the top. In this case we are not at the

    top, but our two small steps will give us enough information to work out the

    steepest slope at x0. This gives us a direction for our first large step, which

    takes us to x1.

    x0

  • At x1 we perform the same iterations. First we check if we are close enough to

    the solution. If we are not, we linearise the local surface by taking two small

    steps at right angles to each other, then we take a large step in the steepest

    vertical direction. We continue doing this until we are close enough to the

    solution.

    In a real case in ECLIPSE, we are dealing with 100,000s or millions of

    variables, the non-linear surface is much more complex, and the solution is more

    difficult to find. Solving the linear equations is also time-consuming when

    there are millions of variables and millions of simultaneous equations. These

    linear equations now require their own linear iterations, and this is where most

    of the computing time is likely to be spent in a reservoir simulation. A

    detailed description of the solution of the linear equations is beyond the scope

    of this manual.

    The interaction between the linear and non-linear equations is shown in the

    following picture:

    x0

    x0

    x1

    x1 x3

    x2

    1

  • The horizontal axis represents time; the vertical axis represents the solution

    variables, which in the case of ECLIPSE 300 are the pressures and saturations in

    every grid blocks. We start with the known solution at time=n and we want to

    find the solution at time=n+1. Our first estimate of the solution at n+1 is

    that it is the same as the solution at n.

    As before, our first step is to check whether our current estimate of the

    solution is a good enough approximation to the solution. We find out it isnt. Our non-linear iteration counter l=1. We linearize the non-linear equations and

    create a linear equation of the form Ax=b, where A I known as the Jacobian. We

    solve the linear problem by iteration. Schematically we have shown this as a

    red line with 5 linear iterations. We now have a second estimate of the

    solution to the non-linear equations, indicated by the position l=2. We check

    to see if this is a solution, then linearise the equations again, solve the

    linear equations (indicated by 4 blue linear iterations) and reach our third

    estimate at l=3. We continue in this way until we converge the non-linear

    problem. The values at the end of the last non-linear iteration are the values

    we use to start the next timestep, starting at time=n+1.

  • 5.5 Definition of convergence

    Formally, we need a test to decide when we can stop the iterations and carry on

    to the next timestep, i.e. to decide when the solution that we have is 'good

    enough'. A test of convergence can be based on either a small residual or a

    small change in solution (or both). The residual can be thought of as a measure

    of how close we are to solving the non-linear problem and is used in ECLIPSE 100

    for the primary test. ECLIPSE 300 uses the change of solution as its basic

    convergence test.

    5.5.1 Solution Change Check

    The variables used by ECLIPSE 300 are pressure and molar densities. ECLIPSE 300

    calculates the maximum change over all cells for these variables and compares

    these maximum changes to two limits, one for pressure (SCONVP) and one for

    saturation (SCONVS).

    SCONVP Set by 1st data item in CVCRIT default 0.1 atm

    SCONVS Set by 7th data item in CVCRIT default 0.01

    The pressure change is compared directly with SCONVP, while an approximation

    using field-wide properties converts molar density changes to effective

    saturation changes. These effective saturation changes are compared with

    SCONVS.

    The maximum solutions change over all cells and all solution variables is

    converted to an "actual-over-target" (aot) which is a ratio of the current

    maximum divided by the appropriate limit. When the value of aot falls below 1,

    then the timestep is converged.

    For example, suppose that the largest absolute pressure change in any grid block

    during the last non-linear iteration was 0.35 atm, with a limit on pressure

    change SCONVP=0.1 atm. The ratio of the two number is 3.5, meaning that the

    pressure change was 2.5 time bigger than we would accept. Suppose the limit on

    effective saturation change was 0.01 and the actual largest absolute value in

    any cell was 0.02, which means the actual change was twice what we would accept.

    The value aot is the maximum of 2.5 and 2, so aot=2.5.

    If the 8th data item in the DEBUG3 keyword is set greater than 0, then ECLIPSE

    300 will output a line of debug that shows the convergence behaviour. The UNIX

    grep command can be used to produce summaries of the output.

    e.g. grep ";|aot" ROOT.DBG will produce something like:

    NLStep= 0 lin= 23 aot= 97.21 Rmax= .7162E-01 Rsum= .9919E-05 egain=-.1000E+01

    NLStep= 1 lin= 19 aot= 17.55 Rmax= .1762E+00 Rsum= .1329E-06 egain=-.1000E+01

    NLStep= 2 lin= 21 aot= 2.94 Rmax= .1421E-01 Rsum= .6285E-06 egain=-.1000E+01

    NLStep= 3 lin= 12 aot= .77 Rmax= .7252E-02 Rsum= .7476E-08 egain=-.1000E+01

    Rep ; 8901.0 1.00 8.7838 .19498 1.4E05 32884. 1.2E06 4843.6 .00000 1.3E06 4 2%

    NLStep= 0 lin= 27 aot= 137.50 Rmax= .7587E-01 Rsum= .2011E-04 egain= .1805E+00

    NLStep= 1 lin= 26 aot= 79.23 Rmax= .7589E-01 Rsum= .1743E-04 egain= .1676E+00

    NLStep= 2 lin= 26 aot= 76.18 Rmax= .7279E-01 Rsum= .1676E-04 egain= .2621E+00

    NLStep= 3 lin= 24 aot= 9.30 Rmax= .9062E-01 Rsum= .8301E-06 egain=-.1000E+01

    NLStep= 4 lin= 24 aot= 9.00 Rmax= .8764E-01 Rsum= .8028E-06 egain=-.1000E+01

    NLStep= 5 lin= 13 aot= .08 Rmax= .9509E-01 Rsum= .9853E-09 egain=-.1000E+01

    MIF ; 8903.0 2.00 8.7860 .19501 1.4E05 32880. 1.2E06 4844.2 .00000 1.3E06 6 2%

    This shows two time steps:

    The first 4 lines above show iterations 0 to 3. Non-linear iterations

    start with iteration 0, which is a first guess at the new solution. The

    aot for iteration 0 is 97.21 so the non-linears are not converged.

  • Iteration 3 has an aot of 0.77, which is less than 1. The largest

    absolute change is now less than the target, so the iterations have

    converged. The simulator provides a timestep report which starts Rep meaning a report has been reached, and a 4 near the end of that line means that 4 non-linears were needed to converge.

    The second timestep needs a total of 6 iterations. In this step we see

    that the aot at the last non-linear iteration drops from 9.00 to 0.08.

    This is a sign of quadratic convergence which will occur when the simulator is very close to the solution and reduces the aot by orders by

    magnitude at each non-linear iteration.

    Details

    If you wish to tighten (reduce) the convergence criteria, there are minimum values below which SCONVP and SCONVS cannot be set. The pressure

    minimum is 0.01 and the effective saturation minimum 0.005. The pressure

    minimum can be ignored by setting the data item (1st in CVCRIT) negative.

    This behaviour is not documented, and may be changed in future releases.

    The convergence tolerances are relaxed slightly at each non-linear iteration, to make convergence easier as the number of iterations

    increases. The hope is that this will allow a difficult timestep to be

    completed without significantly effecting the results. The factor used is:

    Factor = 1.0 + iteration number/maximum iterations

    An additional check is made that the sum of the residuals, which is a measure of total material balance error, is not excessive. This is a

    safety measure that can prevent convergence but rarely gets invoked in

    production cases.

    Even if the solution change is too great and aot>1, the maximum residual may be small enough for the timestep to be converged. The criterion used

    is the variable SNLRMX set using the 11th data item in CVCRIT. The

    residual considered is the residual calculated using the previous

    iteration and is not the new residual resulting from the solution change.

    Because of this the test tends not to be effective very often.

    5.5.2 Gain Option in ECLIPSE 300

    Gain is an option, not used by default, which can significantly improve performance. The idea is to speed the code up by not taking an extra non-linear

    iteration if that iteration is likely to generate a very small solution change.

    We predict the behaviour of the next iteration based on the history of previous

    timesteps. We calculate a gain factor from previous timesteps and rather than

    using the aot we use:

    EAOT=MIN(2.0*AOT*EGAIN,AOT)

    Where EAOT - Effective aot

    AOT - Is the aot as calculated above

    EGAIN - A measure of the expected improvement at the next step

    The gain value is printed out with the non-linear debug (see the example above).

    The gain option can be switched on using the 68th switch of the OPTIONS3

    keyword. The gain option can be controlled using the 19th switch of the OPTIONS3

    keyword. If set to 1, the gain will not be used if any cell has changed state

    during the iteration. In this case you might expect the previous history to be

    less valid.

    The option should be used with care. We have seen examples where this option can

    lead to dramatic changes in iteration sequence.

  • 5.6 Tracking the source of the problem

    A single cell can cause non-convergence. As we increase the number of cells in a

    simulation, we increase the odds that a cell will cause non-convergence.

    If the are only one or two cells in the reservoir model that are causing

    problems, we can identify these cells and check if there is any engineering or

    data reason which could explain why they are causing problems. For example the

    cells may be at or near well completions, in which case well control could be

    modified, or could be cells with very small pore volumes in which case the MINPV

    keyword could be used.

    5.6.1 ECLIPSE 100

    In ECLIPSE 100, you will get non-linear debug if you set NEWTON=2 in RPTSCHED. This will produce output of the form:

    Looking in detail at an example of the residuals,

    IT= 0 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL 1.00424( 28, 45, 3) 5.3D-03 0.00 0.00000 0.00000

    WAT-0.00288( 9, 3, 3) -1.3D-07 0.00 0.00000 0.00000

    GAS********( 5, 45, 1) -1.3D-02 0.00 0.00000 0.00000

    LINIT= 5 NSCHP= 6 NCHOP= 0 NSTAT1,2,3= 50 5400 0 NTRAN= 321

    IT= 1 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL-1.99144( 5, 45, 1) 4.3D-02 -24.89 0.00026 -0.20000

    WAT-0.16316( 2, 4, 4) -3.7D-06 -14.02 0.00490 0.00000

    GAS********( 5, 45, 1) -3.1D-02 -24.89 0.00026 -0.20000

    LINIT= 3 NSCHP= 195 NCHOP= 0 NSTAT1,2,3= 50 5370 30 NTRAN= 30

    IT= 2 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL-0.62319( 5, 45, 1) 1.7D-02 -21.15 0.00081 -0.01843

    WAT-0.04162( 28, 5, 3) -1.3D-04 -30.47 0.00139 0.04000

    GAS********( 5, 45, 1) -2.2D-02 -21.15 0.00081 -0.01843

    LINIT= 3 NSCHP= 44 NCHOP= 3 NSTAT1,2,3= 50 5367 33 NTRAN= 25

    IT= 3 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL-0.30993( 5, 45, 1) -8.9D-05 -26.44 0.00088 -0.21134

    WAT-0.04591( 28, 4, 3) -4.0D-05 -19.80 0.00666 0.11687

    GAS********( 5, 45, 1) -1.4D-02 -26.44 0.00088 -0.21134

  • This shows the first 4 non-linear iterations (IT=0, IT=1, IT=2, IT=3) in a case

    that has convergence problems for the gas phase.

    The first line shows IT=0, the first iteration, and CNV etc are column headers

    for the next 3 lines. The columns are:

    CNV The worst residual for the OIL, WATer and GAS phases

    CELL The cell that has the worst residual

    MAT BAL The material balance for that cell, a measure of mass accuracy

    DPRESS The change in pressure in that cell since the last iteration

    DSWAT The change in water saturation since the last iteration

    DSGAS The change in gas saturation since the last iteration

    The residual for gas in all 4 iterations is shown as ******* which means that it

    is greater than the maximum printable value. It has a very high residual at

    each iteration for cell (5,45,1), so that is the cell that is causing problems.

    After each iteration report above, the line starting LINIT= provides more

    information on what is happening within the model.

    LINIT number of iterations required to solve the linearized equations.

    NSCHP number of saturation changes that were altered to suppress possible

    oscillations.

    NCHOP number of times the changes in P, Rs, or Rv were reduced to increase

    stability.

    NSTAT1,2,3 is the number of cells in solution state 1,2,3

    Solution state 1 means no oil is present in the cell

    Solution state 2 means both oil and gas are present in the cell

    Solution state 3 means no gas is present in the cell

    NTRAN is the number of state transitions since the last non-linear

    iteration.

    Any non-zero value of NSCHP or NCHOP increases material balance errors for the

    subsequent non-linear iteration and therefore reduces the chances of

    convergence. Some saturation chops can be avoided by adjusting relative

    permeability curves in such a way that the critical saturation is not the same

    as the lowest saturation value in the table. For instance, instead of

    SWFN

    0.2 0 7

    0.3 0.07 4

    0.4 0.15 3

    0.5 0.24 2.5

    0.6 0.33 2

    0.8 0.65 1

    0.9 0.83 0.5

    1 1 0 /

    try using

    SWFN

    0.2 0 7

    0.21 0 1*

    0.3 0.07 4

    0.4 0.15 3

    0.5 0.24 2.5

    0.6 0.33 2

    0.8 0.65 1

    0.9 0.83 0.5

    1 1 0 /

    The new saturation value at 0.21 may help convergence. It will not affect the

    initial fluids-in-place but will unfortunately slightly reduce the water

    mobility for water saturations between 0.2 and 0.3. This may not be important

    to engineering accuracy.

  • Look for oscillations in the CNV for a phase. If one iteration has a positive

    value, the next iteration has a negative value, then the next is positive, then

    negative, etc. then there is perhaps a non-linearity in the system. These are

    sometimes associated with sudden changes in the slope of the relative

    permeability curves. If you have access to the SCAL program, you can plot these

    slopes and look for discontinuities. If you have access to a spreadsheet

    program then you can numerically calculate and plot the slopes. Remember that

    ECLIPSE will use all the values of saturation and relative permeability that you

    give in the table without any smoothing. You should therefore try to avoid

    tables such as

    SWFN

    0.2 0 7

    0.21 0 1*

    0.3 0.07 4

    0.301 0.07 4

    0.398 0.14 3

    0.4 0.15 3

    0.401 0.17 3

    0.402 0.19 3

    0.5 0.24 2.5

    0.6 0.33 2

    0.8 0.65 1

    0.9 0.83 0.5

    1 1 0 /

    The table above has saturation values that are too close to each other and the

    slopes of the relative permeabilities shows severe changes. You should also try

    to avoid tables such as

    SWFN

    0.2 0 7

    0.3 0. 4

    0.5 0.01 2.5

    0.51 0.60 2

    0.8 0.68 1

    0.9 0.83 0.5

    1 1 0 /

    The table above has a very sudden krw change from krw=0.01 at Sw=0.5 to krw=0.60

    at Sw=0.51 and will certainly cause convergence problems.

    TUNINGDP output

    The NEWTON switch in RPTSCHED will produce extra information in the case of

    TUNINGDP:

    PTRG is the target pressure change; the default is 1 psi in Field units.

    STRG is the target saturation change; the default is 0 if TUNINGDP is not used

    and 0.01 if it is used.

    MDDP is the maximum Pressure change for convergence.

    MDDS is the maximum Saturation change for convergence.

    If you use TUNINGDP,

    (i) ECLIPSE will solve the linear equations to a tighter tolerance (ii) the convergence is reached if either the residual or the solution

    change criteria is small enough. If you dont use TUNINGDP, only the residual is used to test for convergence.

  • Output of reason for non-linear failure

    If you set DEBUG item 1 in ECLIPSE 100 to be > 1, ECLIPSE will output a number

    that shows the reason that a non-linear iteration has failed to converge. The 5

    possible values are:

    1 - Exceeds maximum tolerable pressure change DDPLIM

    2 - Exceeds maximum tolerable saturation change DDSLIM

    3 - Exceeds maximum tolerable material balance RSUM

    4 - Exceeds tolerable for maximum norm RNMAX

    5 Uses but fails the TRGDDP/TRGDDS test

    DDPLIM and DDSLIM are described in record 3 of the TUNING keyword.

    A value of 3 means that the normalised residual is greater than the maximum

    allowed. That allowed maximum is a linear combination of items 3 and 7 of record

    2 of the tuning parameter. The maximum residual also depends on which newton

    iteration we are on.

    A value of 4 means that the normalised residual is greater than the maximum

    allowed. That allowed maximum is a linear combination of items 2 and 6 of record

    2 of the tuning parameter. The maximum residual also depends on which newton

    iteration we are on.

    A value of 5 means that the change in the solution is less than TRGDDP and

    TRGDDS. These are the minimum values of DDPLIM and DDSLIM until that point in

    the simulation. This is used in cases where there is high throughput.

  • 5.6.2 ECLIPSE 300

    In ECLIPSE 300, you can have either a visual display of the grid blocks causing

    convergence problems or you can look at numerical output in the same way as for

    ECLIPSE 100. Starting with the 2009.1 version, ECLIPSE 100 may also have the

    visual display option.

    Adding CONV to the RPTRST keyword will send two new outputs to the restart

    files. Each cell will have two new variables that will be used to count the

    number of times that cell has been one of the most difficult cells to converge.

    At the beginning of the simulation each cell will have its counter set to zero.

    At every timestep, the 10 most difficult cells will have their counter increased

    by 1. At the end of the run you can display the cells with the most problems.

    Visual option in RPTRST ask for CONV

    Output of cells which are causing convergence problems.

    By default, CONV=10 is set so that the worst 10 cells will be output

    Output

    CONV_VBR: Worst cells based on volume balanced residual

    CONV_PRU: Worst cells based on pressure updates

    Alternatively, you will get non-linear debug if the 8th data item in the DEBUG3

    keyword is set greater than 0. Some of the debug information has already been

    described in section 5.2 above. Typical output is of the form:

    Iteration 0 linears req 7

    DX Pressure 0 -40.075969 25 32 4 F 1.469590

    DX Comp 1 -0.000375 25 32 1 T 0.010000

    DX Comp 2 -0.000980 25 32 1 T 0.010000

    DX Comp 3 -0.025419 25 32 1 F 0.010000

    DX Comp 4 -0.002318 25 32 1 T 0.010000

    DX Comp 5 -0.000318 25 32 3 T 0.010000

    DX Comp 6 0.009711 25 32 1 T 0.010000

    DX Comp 7 0.008562 25 32 1 T 0.010000

    DX Comp 8 0.004396 25 32 1 T 0.010000

    DX Comp 9 0.001465 25 32 1 T 0.010000

    DX Comp 10 0.000907 25 32 4 T 0.010000

    NLStep= 0 lin= 7 aot= 27.27 Rmax=0.8514E+00 Rsum=0.2739E-03 egain=0.2624E-01

    Iteration 1 linears req 5

    DX Pressure 0 -0.563835 25 32 1 T 1.592056

    DX Comp 1 0.000035 25 32 1 T 0.010833

    DX Comp 2 0.000063 25 32 1 T 0.010833

    DX Comp 3 0.001887 25 32 1 T 0.010833

    DX Comp 4 0.000242 25 32 1 T 0.010833

    DX Comp 5 0.000111 25 32 1 T 0.010833

    DX Comp 6 0.000270 26 32 1 T 0.010833

    DX Comp 7 0.000238 26 32 1 T 0.010833

    DX Comp 8 0.000127 26 32 1 T 0.010833

    DX Comp 9 0.000044 26 32 1 T 0.010833

    DX Comp 10 -0.000317 25 32 2 T 0.010833

    NLStep= 1 lin= 5 aot= 0.38 Rmax=0.1921E-01 Rsum=0.1448E-04 egain=0.3165E-01

    Max changes:pres 40.6 25 32 4 temp 0.00 0 0 0

    oil satn 0.516E-01 17 7 1 gas satn -0.178E-01 17 8 1

    wat satn -0.939E-03 25 32 4 eng dens 0.00 0 0 0

    Throughput ratio:avrg 0.404E-01 max 0.192 26 32 2

    MIF ; 103.0 9.00 6.9094 .01725 8973.3 157.46 62000. 3531.4 0.0 60500. 2 2%

  • This output shows two non-linear iterations leading to a timestep report.

    The first line:

    Iteration 0 linears req 7

    tells us that the iteration 0 (the initial estimate) needed 7 linear iterations

    to solve the linear problem.

    The next 11 lines consist of one line for each of the solution variables showing

    the largest change in that variable in any cell during this iteration. The

    solution variables for each grid block are the pressure in the grid block and

    the molar density of each hydrocarbon component, and a water term. This model

    has 9 hydrocarbon components. Water is written as component 10.

    DX Pressure 0 -40.075969 25 32 4 F 1.469590

    DX Comp 1 -0.000375 25 32 1 T 0.010000

    DX Comp 2 -0.000980 25 32 1 T 0.010000

    DX Comp 3 -0.025419 25 32 1 F 0.010000

    DX Comp 4 -0.002318 25 32 1 T 0.010000

    DX Comp 5 -0.000318 25 32 3 T 0.010000

    DX Comp 6 0.009711 25 32 1 T 0.010000

    DX Comp 7 0.008562 25 32 1 T 0.010000

    DX Comp 8 0.004396 25 32 1 T 0.010000

    DX Comp 9 0.001465 25 32 1 T 0.010000

    DX Comp 10 0.000907 25 32 4 T 0.010000

    In each of these lines, DX means the solution change. The first line is the

    Pressure change. The largest pressure change was an increase of 40.075969 psi

    in cell (25,32,4), which happen to contain an injecting completion. The F on that line means False, in that the pressure variable has not converged, as the pressure change is greater than 1.469590, which is the maximum pressure change,

    allowed for convergence for this iteration.

    The second DX line shows the largest change in the molar density, expressed as a

    saturation equivalent, for component 1. This increase of 0.000375 was in cell

    (25,32,1) and is less than the convergence maximum of 0.01, so that the

    component 1 variable is considered to be converged. In fact all the components

    have converged except for component 3.

    The non-linear iteration however has not converged since two of the variables

    (pressure and component 3) are not yet converged.

    The next line is a summary of the first iteration (iteration 0) and has already

    been discussed in section 5.5 above.

    NLStep= 0 lin= 7 aot= 27.27 Rmax=0.8514E+00 Rsum=0.2739E-03 egain=0.2624E-01

    Nltep=0 states that this in non-linear step 0

    Lin=7 says that 7 linear iterations were needed to solve it

    Rmax= 0.8514E+00 is the worst (maximum) residual at the beginning of this

    iteration

    Rsum= 0.2739E-03 is the sum of all the residuals at the beginning of this

    iteration

    egain=0.2624E-01 is the gain discussed in section 5.5.2

    The next line

    Iteration 1 linears req 5

    is the start of the report on the second non-linear iteration, Iteration 1,

    which needed 5 linear iterations.

    The next 11 lines are the solution changes. They are similar to the reported

    changes for the first non-linear iteration except that now both the pressure and

    component 3 have changed by less than the new convergence criteria. The non-

    linear iterations have now converged.

    NLStep= 1 lin= 5 aot= 0.38 Rmax=0.1921E-01 Rsum=0.1448E-04 egain=0.3165E-01

    is the report of the converged iteration showing that the maximum residual at

    the beginning of that iteration was down to 0.1921E-01 and the sum of residuals

    was down to Rsum=0.1448E-04.

  • There then follows a report on the changes during that timestep.

    Max changes:pres 40.6 25 32 4 temp 0.00 0 0 0

    oil satn 0.516E-01 17 7 1 gas satn -0.178E-01 17 8 1

    wat satn -0.939E-03 25 32 4 eng dens 0.00 0 0 0

    The maximum pressure and saturation changes are reported, as well as the cells

    in which this change occurred. In the case of thermal runs, the maximum

    temperature and energy density changes are also reported.

    The maximum throughput is reported next. Throughput is defined as the volume

    flowing through a cell divided by the pore volume of the cell. If the

    throughput is too high (say higher than 0.5) it could cause convergence

    problems, and the pore volume of the cell that has the high throughput should be

    examined.

    Throughput ratio:avrg 0.404E-01 max 0.192 26 32 2

    The last of these lines is the report of production, etc. for the timestep.

    These report steps have been described in section 3.

    MIF ; 103.0 9.00 6.9094 .01725 8973.3 157.46 62000. 3531.4 0.0 60500. 2 2%

    Moving goalposts

    ECLIPSE 300 non-linear convergence criteria have 'moving goalposts'. The

    convergence tolerances are relaxed slightly at each non-linear iteration.

    Effectively, convergence becomes easier as the number of iterations increases.

    The idea is that if you have reached the maximum number of iterations (call that

    Nmax) and you are close (within a factor of two) to the convergence criteria,

    then you don't want to chop the timestep and waste all the work you have done so

    far. So the criteria relaxes by 1/Nmax every Newton iteration.

    An example is shown below. The maximum number of non-linear iterations is 12,

    the units are metric, and the first Newton iteration uses the default

    convergence criteria (0.1 atm pressure and 0.01 for component specific volume).

    For later Newton iterations, these criteria were relaxed by 8.33% (=1/12) with

    each Newton iteration. After 12 Newton iterations, the criteria are doubled to

    0.2 atm pressure and 0.02 for component specific volume.

    Iteration 0 linears req 4 NTOTNL 4076

    DX Pressure 0 2.803147 38 16 10 Ind:GLOB F 1.469590

    DX Comp 1 0.000262 34 31 6 Ind:GLOB T 0.010000

    DX Comp 2 0.000042 34 31 6 Ind:GLOB T 0.010000

    ..

    NLStep= 0 lin= 4 aot= 1.91 Rmax=0.1149E-02 Rsum=0.8487E-05 egain=0.9926E+00

    DCHOP2: 1 cells chopped, Try= 1

    Iteration 1 linears req 7 NTOTNL 4077

    DX Pressure 0 -2.799664 38 16 10 Ind:GLOB F 1.592056

    DX Comp 1 -0.003126 38 16 10 Ind:GLOB T 0.010833

    DX Comp 2 -0.000239 38 16 10 Ind:GLOB T 0.010833

    ..

    NLStep= 1 lin= 7 aot= 1.91 Rmax=0.3573E-01 Rsum=0.1269E-05 egain=0.3326E+01

    DCHOP2: 1 cells chopped, Try= 1

    Iteration 2 linears req 4 NTOTNL 4078

    DX Pressure 0 2.694699 38 16 10 Ind:GLOB F 1.714522

    DX Comp 1 -0.048358 38 16 10 Ind:GLOB F 0.011667

    DX Comp 2 -0.002969 38 16 10 Ind:GLOB T 0.011667

  • 5.6.3 Discussion on Non-Linearity

    A few general problems are:

    1. In explicit cells, the algorithm can try to extract more fluid from a grid block than is present in the grid block. This happens because flows are

    calculated from the solution of the previous timestep, and not from the

    current timestep. The only thing that can be done is to reduce the timestep.

    This will only be an issue if you using the IMPES or AIM solution methods.

    The default in ECLIPSE 100 is FULLIMP, but the default in ECLIPSE 300 is AIM

    unless you are using some options such as Radial, Dual Porosity or Thermal.

    2. Flow reversals are a major non-linearity.

    3. The group control algorithm sometimes wants to change well rates at every non-linear iteration to reflect the latest calculated conditions in the

    reservoir. Changing well rates every non-linear iteration can however lead

    to poor convergence. The simulators therefore by default only recalculate

    group control parameters for the first 4 non-linear iterations, then keep the

    group controls unchanged for the remaining non-linears. This value of 4 can

    be changed using NUPCOL, but we recommend leaving the value unchanged.

    4. Non-monotonic VFP tables can cause convergence problems. VFP tables are always checked for monotonicity in ECLIPSE 300, and the check can be switched

    on in ECLIPSE 100 by using the EXTRAPMS keyword.

    5.6.4 Non-Linear Divergence

    Earlier we showed a simple example of how the non-linear iteration converged for

    a simple function F(x).

    That function F(x) is smooth in the sense that there are no sudden changes in the values of the derivatives.

    What if the curve is not smooth?

  • Consider the following function:

    We want to find the solution (marked by the word Root) but the function Y has a large slope change on either side of the solution. As usual, we start with a

    guess x=X0 and calculate the value of Y at x=X0. We find that X0 is not the

    solution, so we linearise Y by taking the slope and solving the linear equation

    of the slope to calculate a new value X1.

    We check X1 and find that X1 is not a solution either, so we have to continue

    the non-linear iterations. Note that X1 is further away from the correct

    solution at Root than X0, so that the non-linear iteration is moving us away

    from the solution.

  • This next iteration takes us to a value X2, which is even further away from the

    correct solution.

    X3 is even further away, and the divergence continues ...

  • If the data causes curves of this shape, then after a lot of computing time

    ECLIPSE will reach the limit on the number of non-linear iterations, chop the

    time step, and start iterating again. Unfortunately a smaller timestep may not

    solve the problem: a smaller timestep may mean that the initial guess is nearer

    the solution, but the slope change is still there and can still cause

    divergence.

    In some cases, the non-linear iterations can oscillate between two solutions:

  • This oscillation or flip-flop can be seen in the debug output:

    LINIT=10 NSCHP= 6 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 3

    IT= 6 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.03205( 10, 11, 3) 1.1D-06 -84.80 0.00002 -0.01805

    WAT-0.00004( 10, 11, 3) -2.6D-08 -84.80 0.00002 -0.01805

    GAS-0.07982( 13, 10, 3) -3.5D-06 -82.33 0.00006 -0.12626

    LINIT= 6 NSCHP= 0 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 0

    IT= 7 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.00004( 10, 18, 3) 5.0D-09 -84.65 0.00006 -0.00989

    WAT 0.00000( 8, 17, 3) -1.0D-13 -86.77 0.00006 -0.04626

    GAS 0.00354( 13, 10, 3) 2.0D-09 -81.34 0.00006 -0.11912

    LINIT=10 NSCHP= 6 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 3

    IT= 8 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.03205( 10, 11, 3) 1.1D-06 -84.80 0.00002 -0.01805

    WAT-0.00004( 10, 11, 3) -2.6D-08 -84.80 0.00002 -0.01805

    GAS-0.07982( 13, 10, 3) -3.5D-06 -82.33 0.00006 -0.12626

    LINIT= 6 NSCHP= 0 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 0

    IT= 9 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.00004( 10, 18, 3) 5.0D-09 -84.65 0.00006 -0.00989

    WAT 0.00000( 8, 17, 3) -1.0D-13 -86.77 0.00006 -0.04626

    GAS 0.00354( 13, 10, 3) 2.0D-09 -81.34 0.00006 -0.11912

    The solution for non-linear iteration 6 is the same as that for non-linear

    iteration 8, and the solution for non-linear iteration 7 is the same as that for

    non-linear iteration 9.

    LINIT=10 NSCHP= 6 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 3

    IT= 6 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.03205( 10, 11, 3) 1.1D-06 -84.80 0.00002 -0.01805

    WAT-0.00004( 10, 11, 3) -2.6D-08 -84.80 0.00002 -0.01805

    GAS-0.07982( 13, 10, 3) -3.5D-06 -82.33 0.00006 -0.12626

    LINIT= 6 NSCHP= 0 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 0

    IT= 7 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.00004( 10, 18, 3) 5.0D-09 -84.65 0.00006 -0.00989

    WAT 0.00000( 8, 17, 3) -1.0D-13 -86.77 0.00006 -0.04626

    GAS 0.00354( 13, 10, 3) 2.0D-09 -81.34 0.00006 -0.11912

    LINIT=10 NSCHP= 6 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 3

    IT= 8 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.03205( 10, 11, 3) 1.1D-06 -84.80 0.00002 -0.01805

    WAT-0.00004( 10, 11, 3) -2.6D-08 -84.80 0.00002 -0.01805

    GAS-0.07982( 13, 10, 3) -3.5D-06 -82.33 0.00006 -0.12626

    LINIT= 6 NSCHP= 0 NCHOP= 0 NSTAT1,2,3= 0 1793 1213 NTRAN= 0

    IT= 9 CNV CELL MAT BAL DPRESS DSWAT DSGAS

    OIL -0.00004( 10, 18, 3) 5.0D-09 -84.65 0.00006 -0.00989

    WAT 0.00000( 8, 17, 3) -1.0D-13 -86.77 0.00006 -0.04626

    GAS 0.00354( 13, 10, 3) 2.0D-09 -81.34 0.00006 -0.11912

  • 5.6.5 Summary: How to identify problem cells

    1. Add CONV to RPTRST

    2. To get more information for ECLIPSE 100, add NEWTON=nn to RPTSCHED

    3. To get more information for ECLIPSE 300, DEBUG3

    7* 1 /

  • 6. Improving the data

    Make sure that the MESSAGES keyword has not been used to limit the number of

    messages (and comments, warnings, etc.) output by the program

    6.1 Messages, Comments, Warnings

    First check all messages, comments and warnings.

    All of these start with an @, so you can find all these messages by looking for @, either in the PRT file or in the LOG file if you are running in batch mode. Alternatively ECLIPSE Office or PETREL RE will list all of these for you.

    Messages give information.

    You do not have to take any action about messages, but have a look at each

    message to make sure that the information is not unexpected.

    Two example are:

    @--MESSAGE AT TIME 0.0 DAYS (19-OCT-1982):

    @ CHECKING FOR LICENSES

    @--MESSAGE AT TIME 0.0 DAYS (19-OCT-1982):

    @ THE MEMORY REQUIRED TO PROCESS THE GRID SECTION IS

    @ 1526 KBYTES

    Comments also give information.

    You should read all comments to confirm that the model is what you want it to

    be.

    An example is:

    @--COMMENT AT TIME 0.0 DAYS (19-OCT-1982):

    @ NO NON-NEIGHBOUR CONNECTIONS FOUND

    If you did not expect any non-neighbor connections, then you do not have to do

    anything. If however you know that your reservoir has a lot of fault throws,

    then you may need to check your model.

    Warnings are things you should check.

    There may be data issues that need correcting.

    Common Warning (1)

    @--WARNING AT TIME 0.0 DAYS (19-OCT-1982):

    @ INCONSISTENT END POINTS IN SATURATION TABLE 1

    @ THE MAXIMUM GAS SATURATION (1.0000)

    @ PLUS THE CONNATE WATER SATURATION (0.1200)

    @ MUST NOT EXCEED 1.0

    Probably safe, but your gas and water SCAL tables are inconsistent. Did you know

    that with your data the gas saturation will never be > 0.88? Is this what you

    wanted?

    Common Warning (2)

    @--WARNING AT TIME 0.0 DAYS (19-OCT-1982):

    @ THE BOTTOM HOLE PRESSURE LIMIT FOR WELL INJECTR1

    @ HAS BEEN DEFAULTED. THE DEFAULT VALUE IS 100000. PSIA

    Probably safe as long as the injector never goes to BHP control, but setting a

    more reasonable limit would be safer.

  • 6.2 Problems, Errors, Bugs and NaNs

    All of these also start with an @. Check and correct any problems and errors. If after you have fixed all problems and errors you still have either a bug or a

    NaN then contact your local support.

    Problems mean there is definitely an issue.

    Check and fix before continuing.

    @--PROBLEM AT TIME 0.0 DAYS (19-OCT-1982):

    @ OIL PRESSURE IN EQUILIBRATION CALCULATION BETWEEN DEPTHS

    @ 8400.0 FEET AND 8397.7 FEET HAS NOT CONVERGED.

    @ CONVERGENCE ERROR = 0.86508E+33 PSI .

    @ THE CURRENT NUMBER ( 100 ) OF DEPTH NODES IN THE

    @ EQUILIBRATION CALCULATION IS TOO SMALL.

    In this case, pointing to oil PVT table.

    Errors mean you cannot continue without fixing your data.

    @-- ERROR AT TIME 0.0 DAYS (19-OCT-1982):

    @ ERROR IN PVTO TABLE NUMBER 1

    @ NOT ENOUGH PRESSURE VALUES (ONLY 1) SPECIFIED

    @ FOR HIGHEST RS (= 1.270 MSCF/STB)

    This was the reason for the previous message, so always fix the first error

    message first.

    NaN means Not a Number, and is usually caused by dividing by zero or something

    similar.

    NaNs sometimes happens after an Error, so if you see NaN anywhere in any output, then:

    1. Fix any Error or Problem first. 2. If the NaN is still there, contact your local support.

    @--WARNING AT TIME 0.0 DAYS (19-OCT-1982):

    @ GAS IS DENSER THAN OIL WITHIN THE RESERVOIR

    @ IN EQUILIBRATION REGION 1. CHECK SURFACE

    @ DENSITIES, FORMATION VOLUME FACTORS, RS, RV.

    @ THE PROBLEM OCCURS AT DEPTH 8725.0000

    @ GAS PRESSURE = 0.4201E-01

    @ OIL PRESSURE = NaN

    @ (RS MAY BE SPECIFIED IN THE WRONG UNITS)

    In this case, the NaN follows an error message.

  • 6.3 What to look for in different Sections

    6.3.1 GRID data MINPV

    Use MINPV to remove cells with small pore volumes. If a full-field model has

    convergence problems and does NOT have a minimum pore volume, adding MINPV is

    the most likely change that will improve performance.

    Take care to choose a suitable value of MINPV that does not significantly change

    the total pore volumes in each region, and that does not remove high-

    permeability streaks or thin shale layers within the reservoirs. If MINPV is

    being used to remove pinch-outs, also use PINCH to connect across those thin

    cells that represent pinch-outs. Within these limitations, using MINPV should

    both improve performance and give unchanged production results.

    LIMITS

    Look for the table headed LIMITS in the ECLIPSE 300 PRT file. This is a table of minimum and maximum values for each GRID array. Check the

    ratio of Maximum/Minimum values at the left of output, and investigate if any of

    these ratios is very large.

    Grid Array Maximum value Minimum value Non-zero minimum Ratio max/min ---------- ---------------------------- ---------------------------- ---------------------------- -------------- TOPS 7571.0 ( 1 5 9) 7021.0 ( 1 1 1) 7021.0 ( 1 1 1) 1.078336 MIDS 7926.0 ( 1 5 9) 7146.0 ( 1 1 1) 7146.0 ( 1 1 1) 1.109152 DEPTH 7926.0 ( 1 5 9) 7146.0 ( 1 1 1) 7146.0 ( 1 1 1) 1.109152 DX 220.0 ( 1 1 1) 55.0 ( 1 6 2) 55.0 ( 1 6 2) 4.0 DY 220.0 ( 1 3 1) 55.0 ( 1 1 1) 55.0 ( 1 1 1) 4.0 DZ 710.0 ( 1 1 3) 250.0 ( 1 1 1) 250.0 ( 1 1 1) 2.84 DZNET 710.0 ( 1 1 3) 250.0 ( 1 1 1) 250.0 ( 1 1 1) 2.84 NTG 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 PORO 0.10 ( 1 1 1) 0.15E-01 ( 1 3 4) 0.15E-01( 1 3 4) 6.666667 PORV 459036.7 ( 1 1 3) 323.26 ( 1 1 4) 323.26 ( 1 1 4) 1420.0 PERMX 300.0 ( 1 1 4) 0.0 ( 1 1 1) 1.5 ( 1 1 6) 200.0 PERMY 300.0 ( 1 1 4) 0.0 ( 1 1 1) 1.5 ( 1 1 6) 200.0 PERMZ 7.5 ( 1 1 4) 0.0 ( 1 1 1) 0.75 ( 1 1 6) 10.00 TRANX 8.45 ( 1 1 4) 0.0 ( 1 1 1) 1.20383 ( 1 1 6) 7.042254 TRANY 8.45 ( 1 1 4) 0.0 ( 1 1 1) 1.20383 ( 1 1 6) 7.042254 TRANZ 1.49 ( 1 1 4) 0.0 ( 1 1 1) 0.1105796( 1 1 5) 13.45455 MULTX 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 MULTY 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 MULTZ 1.0 ( 1 1 1) 0.0 ( 1 1 9) 1.0 ( 1 1 1) 1.0 ROCKV 6028682. ( 1 1 6) 1939592. ( 1 4 4) 1939592. ( 1 4 4) 3.108222 MULTPV 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 ( 1 1 1) 1.0 MINPVV 0.1E-05 ( 1 1 1) 0.1E-05 ( 1 1 1) 0.1E-05 ( 2 1 1) 1.0 ------------------------------------------------------------------------------------------------------------------------------

    ECLIPSE 300 Black-Oil

    Did you know that an ECLIPSE Black-oil license allows you to run ECLIPSE 300 in

    black-oil mode? ECLIPSE 300 sometimes gives you more information and insight

    into a problem than ECLIPSE 100.

  • In-Place LGRs

    By default, ECLIPSE 100 will solve LGRs using local time stepping.

    With local time stepping, the global grid can take a large time step that is not

    limited by the size of the time step needed by the LGR. The algorithm used is

    shown below:

    The local time stepping method is semi-explicit and therefore is potentially

    unstable. The alternative is to use the LGRLOCK to lock the timesteps together and turn off the local time stepping, so that the global timesteps are

    the same as the local timesteps. With LGRLOCK, the method is fully implicit and

    unconditionally stable.

    The keyword LGRFREE will allow local timestepping to start again, if the

    convergence issue only occurs for a few timesteps.

  • 6.3.2 SCAL data Another Story

    Again, poor convergence was causing a model to run very slowly. Using the

    techniques described above, the problem was raced to one of the relative

    permeability curves. A plot of the original curve is shown below:

    The curve is smooth and looks reasonable. At first, the data in the relative

    permeability table also looked reasonable.

    The keyword was SOF3, and the data we were suspicious about was the krow as a

    function of Soil.

    -- SOIL KROW KROG

    SOF3

    0.181 0 0

    0.283 0.0001 0.0001

    0.385 0.0015 0.0015

    0.436 0.0124 0.0124

    0.483 0.0217 0.0217

    0.588 0.0939 0.0939

    0.686 0.3499 0.3499

    0.689 0.3501 0.3501

    0.761 0.7323 0.7323

    0.837 0.9887 0.9887

    0.863 0.9978 0.9978

    0.879 1 1

    0.880 1 1 /

    The Soil and krow column see to be correct. The Soil column is monotonically

    increasing, and has values between 0 and 1. The krow column is also

    monotonically increasing, and has values between 0 and 1.

    We used the SCAL program to plot the derivative d(krow)/d(Soil). We expected

    that the derivatives would be smoothly varying, as krow was smoothly varying.

    We got an unexpected result:

  • There are sharp changes in slope around Sw = 24% and around Sw = 31%. These

    value correspond to Soil = about 68% and 76%, so we checked the SOF3 table at

    these values. We found that at around 68% oil there are two oil saturations

    with very close values, 0.686 and 0.689, that have very similar krow values of

    0.3499 and 0.3501.

    -- SOIL KROW KROG

    SOF3

    0 0 0

    0.283 0.0001 0.0001

    0.385 0.0015 0.0015

    0.436 0.0124 0.0124

    0.483 0.0217 0.0217

    0.588 0.0939 0.0939

    0.686 0.3499 0.3499

    0.689 0.3501 0.3501

    0.761 0.7323 0.7323

    0.837 0.9887 0.9887

    0.863 0.9978 0.9978

    0.879 1 1

    0.880 1 1 /

    The SOF3 table does not need saturation values that close together, and in fact

    very closely spaced values in any table may cause ECLIPSE to do extra computing

    work as it has to find exactly which two point to interpolate between. In this

    case we can fix the problem by removing either one of the two entries:

    -- SOIL KROW KROG

    SOF3

    0.181 0 0

    0.283 0.0001 0.0001

    0.385 0.0015 0.0015

    0.436 0.0124 0.0124

    0.483 0.0217 0.0217

    0.588 0.0939 0.0939

    0.689 0.3501 0.3501

    0.761 0.7323 0.7323

    0.837 0.9887 0.9887

    0.863 0.9978 0.9978

  • 0.879 1 1

    0.880 1 1 /

    This single change was enough to produce smooth derivatives and to resolve the

    convergence problem.

    Removing very small kr values

    We can however also make an engineering improvement to the table. Consider the

    entry at Soil=0.283:

    -- SOIL KROW KROG

    SOF3

    0.181 0 0

    0.283 0.0001 0.0001

    0.385 0.0015 0.0015

    0.436 0.0124 0.0124

    0.483 0.0217 0.0217

    0.588 0.0939 0.0939

    0.686 0.3499 0.3499

    0.689 0.3501 0.3501

    0.761 0.7323 0.7323

    0.837 0.9887 0.9887

    0.863 0.9978 0.9978

    0.879 1 1

    0.880 1 1 /

    That line in the table says that at 28.3% oil saturation the relative

    permeability of oil to water and to gas are both 1E-4. It is possible but

    unlikely that this 1E-4 is a value that has been measured experimentally. From

    a simulation point of view it makes more sense to set that value to 0. ECLIPSE

    has special code (known as the Appleyard Chop) that speeds up convergence at the

    point when a phase first becomes mobile. That code is wasted if the change in

    relative permeability is from 0 to 1E-4, but is very effective if the change is

    from 0 to a higher value.

  • Critical saturations

    Consider a grid block with pore

    volume of 100 m3. Assume it contains

    80 m3 of gas and 20 m3 of water.

    The water saturation is 20%

    Suppose

    1. The pore volume decreases by 1% due to reservoir pressure

    changes

    2. There is no flow in or out of that grid block.

    The gas will compress but water is

    relatively incompressible, so we will

    have approximately 79 m3 of gas and

    20 m3 of water.

    The water saturation will increase

    from 20/100 = 20% to 20/99 = 20.2%

    As you produce/inject, the pressure in every block will change.

    Therefore the pore volume of each grid block will change.

    If the initial water saturation (SWL) in each grid block was 20%, Sw will now be >20% in many blocks.

    If SWCR=SWL=20% then all those blocks have mobile water even if Sw is only 20.0001%. This water WILL flow.

    Setting SWCR=SWL+0.01% will stabilize the model without changing the OOIP.

    The same applies to the critical saturation of any phase. The original SOF3

    table is

    -- SOIL KROW KROG

    SOF3

    0.181 0 0

    0.283 0.0001 0.0001

    0.385 0.0015 0.0015

    0.436 0.0124 0.0124

    0.483 0.0217 0.0217

    0.588 0.0939 0.0939

    0.689 0.3501 0.3501

    0.761 0.7323 0.7323

    0.837 0.9887 0.9887

    0.863 0.9978 0.9978

    0.879 1 1

    0.880 1 1 /

  • As discussed above, we could stabilize the oil by changing the 1E-4 values to

    zero. If for some reason we do not wish to do that, we could instead add a

    relative permeability of 0 at an oil saturation of 18.2%

    -- SOIL KROW KROG

    SOF3

    0.181 0 0

    0.182 0 0

    0.283 0.0001 0.0001

    0.385 0.0015 0.0015

    0.436 0.0124 0.0124

    0.483 0.0217 0.0217

    0.588 0.0939 0.0939

    0.689 0.3501 0.3501

    0.761 0.7323 0.7323

    0.837 0.9887 0.9887

    0.863 0.9978 0.9978

    0.879 1 1

    0.880 1 1 /

    SCAL DATA: other issues

    Hysteresis

    Does the model run better without hysteresis?

    Are the drainage and imbibition end-points consistent? End-point scaling

    Are the end-point values extrem