NSTACK
Recognised by the OPM Flow parserRUNSPECSCHEDULE
The NSTACK keyword defines the maximum number of previous search directions stored by the linear solver. Increasing the value of NSTACK may improve the efficiency of the solver on difficult problems, but will increase the memory requirements of the simulator. The default value of 10 should be sufficient for most problems; however, if OPM Flow is having issues with the convergence of the linear questions then increasing NSTACK and the value of LITMAX on the TUNING keyword may improve performance.
OPM Flow uses a different numerical scheme which makes this keyword redundant; see section 2.2Running OPM Flow 2023-04 From The Command Lineon how to invoke various numerical schemes via the OPM Flow command line interface.
This keyword is not supported by OPM Flow but has no effect on the results so it will be ignored.
Notes:
The value of NSTACK and the value of LITMAX on the TUNING keyword are related such that NSTACK should always be less than or equal to LITMAX.
The keyword is terminated by a “/”.
- Records
- Fixed number of records
- Record count
- 1
- Items per record
- 1
Parameters
| No. | Name | Description | Type | Default |
|---|---|---|---|---|
| 1 | LINEAR_manual: NSTACK | A positive integer that defines the maximum number of previous search directions stored by the linear solver. | INT | 10 |
Example
--
-- SET STACK SIZE FOR LINEAR SOLVER
--
NSTACK
30 /
The above example sets maximum number of previous search directions stored by the linear solver to 30, this has no effect in OPM Flow input decks.
Note
If the run is suffering from linear convergence problems, then check the data first for any data issues before manipulating the numerical control parameters. For example, if OPM Flow has written some WARNING messages with respect to end-point scaling, etc., then resolve these messages first before adjusting the numerical controls.
| Note If the run is suffering from linear convergence problems, then check the data first for any data issues before manipulating the numerical control parameters. For example, if OPM Flow has written some WARNING messages with respect to end-point scaling, etc., then resolve these messages first before adjusting the numerical controls. |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|Manual source: parts/chapters/subsections/5.3/NSTACK.fodt