Skip to content

Commit 702105e

Browse files
committed
Submodels around wells
1 parent cb78d93 commit 702105e

31 files changed

+445
-97
lines changed

docs/_images/pyopmnearwell.gif

-10.3 MB
Binary file not shown.

docs/_images/pyopmnearwell.png

326 KB
Loading

docs/_images/submodelwell.png

721 KB
Loading

docs/_images/vicinity.png

367 KB
Loading

docs/_sources/examples.rst.txt

Lines changed: 30 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ Via OPM Flow decks
2828
==================
2929

3030
The current development of **pycopm** focuses on creating tailored models (grid refinement, grid coarsening, submodels, and transformations) by using input decks.
31-
While in the Hello world example these four different options are demonstrated, for the latter examples the focus is on the grid coarsening functionality.
31+
While in the Hello world example these four different options are demonstrated, for the latter examples the focus is on the grid coarsening functionality, and the
32+
SPE10 also shows the submodel functionality.
3233

3334
Hello world
3435
-----------
@@ -70,22 +71,6 @@ we apply a grid refinement on the cells in the middle x and y location, and fina
7071
The text in the legends highlight that the pore volume is conserved (35.58) and the number of active cells is reduced from 351 to 25 in the
7172
submodel and after increased to 41 due to the grid refinement.
7273

73-
74-
SPE10
75-
-----
76-
77-
By downloading the `SPE10_MODEL2 model <https://github.com/OPM/opm-data/tree/master/spe10model2>`_, then:
78-
79-
.. code-block:: bash
80-
81-
pycopm -i SPE10_MODEL2.DATA -o coarser -c 4,8,2
82-
83-
generates a coarsened model from ca. 1 million cells to ca. 20 thousands cells.
84-
85-
.. figure:: figs/spe10_model2_coarser.png
86-
87-
Porosity values for the (left) original and (right) coarsed SPE10 model.
88-
8974
Smeaheia
9075
--------
9176

@@ -94,7 +79,7 @@ then:
9479

9580
.. code-block:: bash
9681
97-
pycopm -i Statoil_Feasibility_sim_model_with_depletion_KROSS_INJ_SECTOR_20.DATA -o . -c 5,4,3 -a min -m all
82+
pycopm -c 5,4,3 -a min -m all -i Statoil_Feasibility_sim_model_with_depletion_KROSS_INJ_SECTOR_20.DATA -o .
9883
9984
will generate a coarser model 5 times in the x direction, 4 in the y direction, and 3 in the z direction, where the coarse cell is
10085
made inactive if at least one cell is inactive (**-a min**).
@@ -103,7 +88,7 @@ We use our `plopm <https://github.com/cssr-tools/plopm>`_ friend to generate PNG
10388

10489
.. code-block:: bash
10590
106-
plopm -i ' STATOIL_FEASIBILITY_SIM_MODEL_WITH_DEPLETION_KROSS_INJ_SECTOR_20_PREP_PYCOPM_DRYRUN STATOIL_FEASIBILITY_SIM_MODEL_WITH_DEPLETION_KROSS_INJ_SECTOR_20_PYCOPM' -s ,,0 -v poro -subfigs 1,2 -save smeaheia -t 'Smeaheia Coarsed smeaheia' -xunits km -xformat .0f -yunits km -yformat .0f -d 5,5.2 -suptitle 0 -c cet_rainbow_bgyrm_35_85_c69 -cbsfax 0.30,0.01,0.4,0.02 -cformat .2f
91+
plopm -i 'STATOIL_FEASIBILITY_SIM_MODEL_WITH_DEPLETION_KROSS_INJ_SECTOR_20_PREP_PYCOPM_DRYRUN STATOIL_FEASIBILITY_SIM_MODEL_WITH_DEPLETION_KROSS_INJ_SECTOR_20_PYCOPM' -s ,,0 -v poro -subfigs 1,2 -save smeaheia -t 'Smeaheia Coarsed smeaheia' -xunits km -xformat .0f -yunits km -yformat .0f -d 5,5.2 -suptitle 0 -c cet_rainbow_bgyrm_35_85_c69 -cbsfax 0.30,0.01,0.4,0.02 -cformat .2f
10792
10893
.. figure:: figs/smeia.png
10994

@@ -200,8 +185,33 @@ example), then here we create a coarsened model by removing certain pilars in or
200185

201186
.. code-block:: bash
202187
203-
pycopm -i NORNE_ATW2013.DATA -x 0,2,0,2,2,0,2,0,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,0,2,0,2,2,0,2,2,0,2,2,2,2,0 -y 0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,2,2,2,2,2,2,2,2,0 -z 0,0,2,0,0,2,2,2,2,2,0,2,2,2,2,2,0,0,2,0,2,2,0 -a min -p 1 -q 1 -m all
188+
pycopm -i NORNE_ATW2013.DATA -s pvmean -x 0,2,0,2,2,0,2,0,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,0,2,0,2,2,0,2,2,0,2,2,2,2,0 -y 0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,0,2,2,2,2,2,2,2,2,2,0 -z 0,0,2,0,0,2,2,2,2,2,0,2,2,2,2,2,0,0,2,0,2,2,0 -a min -p 1 -q 1 -m all
204189
205190
this would generate the following coarsened model:
206191

207192
.. figure:: figs/norne_vec.png
193+
194+
SPE10
195+
-----
196+
197+
By downloading the `SPE10_MODEL2 model <https://github.com/OPM/opm-data/tree/master/spe10model2>`_, then:
198+
199+
.. code-block:: bash
200+
201+
pycopm -i SPE10_MODEL2.DATA -s pvmean -c 4,8,2
202+
203+
generates a coarsened model from ca. 1 million cells to ca. 20 thousands cells.
204+
205+
.. figure:: figs/spe10_model2_coarser.png
206+
207+
Porosity values for the (left) original and (right) coarsed SPE10 model.
208+
209+
To generate a submodel from the coarsened model around the injector 'INJ', this can be achieved by executing:
210+
211+
.. code-block:: bash
212+
213+
pycopm -i SPE10_MODEL2_PYCOPM.DATA -p 1 -v 'INJ diamondxy 5' -m all -w vicinity -l sub
214+
215+
.. figure:: figs/vicinity.png
216+
217+
Pore volume values for the (left) coarsened and (right) vicinity around the well INJ in the SPE10 model.

docs/_sources/introduction.rst.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ where
3737
-o The base name of the :doc:`output folder <./output_folder>` ('.' by default, i.e., the folder where pycopm is executed).
3838
-f OPM Flow full path to executable or just 'flow' ('flow' by default).
3939
-m Execute a dry run of the input deck to generate the static properties ('prep'), generate only the modified files ('deck'), only exectute a dry run on the generated model ('dry'), 'prep_deck', 'deck_dry', or do all ('all') ('prep_deck' by default).
40-
-v The location to extract the sub model which can be assigned by a region assignation, e.g., 'fipnum 2,4' extracts the cells with fipnums equal to 2 or 4, or can be assigned by a polygon given the xy locations in meters, e.g., 'xypolygon [0,0] [30,0] [30,30] [0,0]' ('' by default).
40+
-v The location to extract the sub model which can be assigned by region values, e.g., 'fipnum 2,4' extracts the cells with fipnums equal to 2 or 4, by a polygon given the xy locations in meters, e.g., 'xypolygon [0,0] [30,0] [30,30] [0,0]', or by the name of the well and three different options for the neighbourhood: box, diamond, and diamondxy, where for box the i, j, and k interval around the connections are given, e.g., 'welln box [-1,1] [-2,2] [0,3]' results in a vicinity with 1 pm cell in the x direction, 2 pm cells in the y direction and only 3 cells in the k positive direction, while the diamond considers only the given number of cells around the well connections (e.g., 'welln diamond 2') and diamondxy it is restricted to the xy plane ('' by default).
4141
-c Level of coarsening in the x, y, and z dir ('2,2,2' by default; either use this flag or the -x, -y, and -z ones).
4242
-x Array of x-coarsening, e.g., if the grid has 6 cells in the x direction, then '0,2,0,2,0,2,0' would generate a coarsened model with 3 cells, while '0,2,2,2,2,2,0' would generate a coarser model with 1 cell, i.e., 0 keeps the pilars while 2 removes them. As an alternative, the range of the cells to coarse can be given separate them by commas, e.g., '1:3,5:6' generates a coarsened model with 3 cells where the cells with the first three and two last i indices are coarsened to one ('' by default),
4343
-y Array of y-coarsening, see the description for -x ('' by default).

docs/_sources/related.rst.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ pyopmspe11
1717
pyopmnearwell
1818
*************
1919

20-
.. image:: ./figs/pyopmnearwell.gif
21-
:scale: 50%
20+
.. image:: ./figs/pyopmnearwell.png
21+
:scale: 60%
2222

23-
`A framework to simulate near well dynamics using OPM Flow <https://github.com/cssr-tools/pyopmnearwell>`_.
23+
`A Python framework to simulate near well dynamics using OPM Flow <https://github.com/cssr-tools/pyopmnearwell>`_.
2424

2525
*****
2626
plopm

docs/_sources/theory.rst.txt

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,13 @@ Regarding the boundary conditions in the extracted model with respect to the por
131131
Figure 3: The shape to extract the sudmodel corresponds to "-v 'xypolygon [50,90] [60,60] [90,60] [65,40] [75,10] [50,30] [25,10] [35,40] [10,60] [40,60] [50,90]'".
132132
The j indices for the cells have been accordingly shifted in the extracted model, and the right figure shows the projected pore volume on the boundary.
133133

134+
In addition, it is possible to extract submodels around wells, with three different options for the neighbourhood: box, diamond, and diamondxy. The box option allows to define
135+
the intervals to extract the cells, while the diamond and diamondxy results in fewer cells since the cells in the corners are trimmed.
136+
137+
.. figure:: figs/submodelwell.png
138+
139+
Figure 4: The submodel in `norne <https://github.com/OPM/opm-tests/tree/master/norne>`_ by executing "-v 'E-3H diamondxy 0' -p 1", "-v 'E-3H diamond 1' -p 1", and "-v 'E-3H box [-1,2] [-2,3] [-1,1]' -p 1" respectively.
140+
134141
===============
135142
Transformations
136143
===============
@@ -143,4 +150,4 @@ groups which missmatch in the thickness of layers), and rotations (e.g., to alig
143150

144151
.. figure:: figs/transformation.png
145152

146-
Figure 4: Extracted shape in Figure 3 after a rotation "-d 'rotatexy 45'" (left) and scaling "-d 'scale [1,0.25,1]'" (right).
153+
Figure 5: Extracted shape in Figure 3 after a rotation "-d 'rotatexy 45'" (left) and scaling "-d 'scale [1,0.25,1]'" (right).

0 commit comments

Comments
 (0)