Skip to content

Commit

Permalink
Merge pull request #37 from daavid00/dataReport
Browse files Browse the repository at this point in the history
spe11b results in a 1 m Cartesian grid
  • Loading branch information
daavid00 authored Feb 19, 2024
2 parents e851a4c + fb2b223 commit 4255ab1
Show file tree
Hide file tree
Showing 14 changed files with 119 additions and 15 deletions.
Binary file modified docs/_images/animation.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_images/spe11b_performance_1m.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_images/spe11b_sparse_data_1m.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 17 additions & 1 deletion docs/_sources/examples.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,20 @@ the following are some of the generated figures:
the tolerances are not tight and no tunning was performed. In consequence, the total mass in the simulation (ca. 7.75e7 kg) is less
than what is specified in the benchmark (ca. 8.27e7 kg). By executing flow --help you get an overview of the available flags in the
flow simulator to improve/fix convergence and mass issues (i.e., by setting the flag --linear-solver=cprw to change the linear solver,
by tightening the mb tolerances (--tolerance-mb), etc.).
by tightening the mb tolerances (--tolerance-mb), etc.).

The following are simulation results in a 1 m Cartesian grid `(spe11b1m.txt) <https://github.com/OPM/pyopmspe11/blob/main/examples/finner_grids/spe11b1m.txt>`_,
and the animation in the `main page <https://github.com/OPM/pyopmspe11/blob/main>`_ was generated using these results (the inizialization time of 1000 years was
skipped and the results were printed ever 25 years instead of 5 years):

.. code-block:: bash
pyopmspe11 -i spe11b1m.txt -o spe11b1m -m all -g all -r 840,1,120 -t 25 -w 0.1
.. figure:: figs/spe11b_sparse_data_1m.png

Sparse data in the 1 m Cartesian grid.

.. figure:: figs/spe11b_performance_1m.png

Performance data in the 1 m Cartesian grid.
8 changes: 4 additions & 4 deletions docs/_sources/related.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Related
=======

Below are some packages following the same configuration-file-to-postprocessing-folder approach;
check them out :).
check them out 🙂.

*************
pyopmnearwell
Expand All @@ -12,7 +12,7 @@ pyopmnearwell
.. image:: ./figs/pyopmnearwell.gif
:scale: 50%

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

********
expreccs
Expand All @@ -21,7 +21,7 @@ expreccs
.. image:: ./figs/expreccs.gif
:scale: 50%

`Expansion of ResourCes for CO2 Storage on the Horda Platform <https://github.com/daavid00/expreccs>`_.
`Expansion of ResourCes for CO2 Storage on the Horda Platform <https://github.com/cssr-tools/expreccs>`_.

*******
ad-micp
Expand All @@ -39,4 +39,4 @@ pymm
.. image:: ./figs/pymm.gif
:scale: 15%

`An open-source image-based framework for CFD in microsystems <https://github.com/daavid00/pymm>`_.
`An open-source image-based framework for CFD in microsystems <https://github.com/cssr-tools/pymm>`_.
18 changes: 18 additions & 0 deletions docs/examples.html
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,24 @@ <h2>Presentation<a class="headerlink" href="#presentation" title="Link to this h
flow simulator to improve/fix convergence and mass issues (i.e., by setting the flag –linear-solver=cprw to change the linear solver,
by tightening the mb tolerances (–tolerance-mb), etc.).</p>
</div>
<p>The following are simulation results in a 1 m Cartesian grid <a class="reference external" href="https://github.com/OPM/pyopmspe11/blob/main/examples/finner_grids/spe11b1m.txt">(spe11b1m.txt)</a>,
and the animation in the <a class="reference external" href="https://github.com/OPM/pyopmspe11/blob/main">main page</a> was generated using these results (the inizialization time of 1000 years was
skipped and the results were printed ever 25 years instead of 5 years):</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pyopmspe11<span class="w"> </span>-i<span class="w"> </span>spe11b1m.txt<span class="w"> </span>-o<span class="w"> </span>spe11b1m<span class="w"> </span>-m<span class="w"> </span>all<span class="w"> </span>-g<span class="w"> </span>all<span class="w"> </span>-r<span class="w"> </span><span class="m">840</span>,1,120<span class="w"> </span>-t<span class="w"> </span><span class="m">25</span><span class="w"> </span>-w<span class="w"> </span><span class="m">0</span>.1
</pre></div>
</div>
<figure class="align-default" id="id5">
<img alt="_images/spe11b_sparse_data_1m.png" src="_images/spe11b_sparse_data_1m.png" />
<figcaption>
<p><span class="caption-text">Sparse data in the 1 m Cartesian grid.</span><a class="headerlink" href="#id5" title="Link to this image"></a></p>
</figcaption>
</figure>
<figure class="align-default" id="id6">
<img alt="_images/spe11b_performance_1m.png" src="_images/spe11b_performance_1m.png" />
<figcaption>
<p><span class="caption-text">Performance data in the 1 m Cartesian grid.</span><a class="headerlink" href="#id6" title="Link to this image"></a></p>
</figcaption>
</figure>
</section>
</section>

Expand Down
8 changes: 4 additions & 4 deletions docs/related.html
Original file line number Diff line number Diff line change
Expand Up @@ -89,16 +89,16 @@
<section id="related">
<h1>Related<a class="headerlink" href="#related" title="Link to this heading"></a></h1>
<p>Below are some packages following the same configuration-file-to-postprocessing-folder approach;
check them out :).</p>
check them out 🙂.</p>
<section id="pyopmnearwell">
<h2>pyopmnearwell<a class="headerlink" href="#pyopmnearwell" title="Link to this heading"></a></h2>
<a class="reference internal image-reference" href="_images/pyopmnearwell.gif"><img alt="_images/pyopmnearwell.gif" src="_images/pyopmnearwell.gif" style="width: 806.0px; height: 410.0px;" /></a>
<p><a class="reference external" href="https://github.com/daavid00/pyopmnearwell">A framework to simulate near well dynamics using OPM Flow</a>.</p>
<p><a class="reference external" href="https://github.com/cssr-tools/pyopmnearwell">A framework to simulate near well dynamics using OPM Flow</a>.</p>
</section>
<section id="expreccs">
<h2>expreccs<a class="headerlink" href="#expreccs" title="Link to this heading"></a></h2>
<a class="reference internal image-reference" href="_images/expreccs.gif"><img alt="_images/expreccs.gif" src="_images/expreccs.gif" style="width: 780.0px; height: 403.0px;" /></a>
<p><a class="reference external" href="https://github.com/daavid00/expreccs">Expansion of ResourCes for CO2 Storage on the Horda Platform</a>.</p>
<p><a class="reference external" href="https://github.com/cssr-tools/expreccs">Expansion of ResourCes for CO2 Storage on the Horda Platform</a>.</p>
</section>
<section id="ad-micp">
<h2>ad-micp<a class="headerlink" href="#ad-micp" title="Link to this heading"></a></h2>
Expand All @@ -108,7 +108,7 @@ <h2>ad-micp<a class="headerlink" href="#ad-micp" title="Link to this heading">
<section id="pymm">
<h2>pymm<a class="headerlink" href="#pymm" title="Link to this heading"></a></h2>
<a class="reference internal image-reference" href="_images/pymm.gif"><img alt="_images/pymm.gif" src="_images/pymm.gif" style="width: 675.0px; height: 405.0px;" /></a>
<p><a class="reference external" href="https://github.com/daavid00/pymm">An open-source image-based framework for CFD in microsystems</a>.</p>
<p><a class="reference external" href="https://github.com/cssr-tools/pymm">An open-source image-based framework for CFD in microsystems</a>.</p>
</section>
</section>

Expand Down
2 changes: 1 addition & 1 deletion docs/searchindex.js

Large diffs are not rendered by default.

18 changes: 17 additions & 1 deletion docs/text/examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,20 @@ the following are some of the generated figures:
the tolerances are not tight and no tunning was performed. In consequence, the total mass in the simulation (ca. 7.75e7 kg) is less
than what is specified in the benchmark (ca. 8.27e7 kg). By executing flow --help you get an overview of the available flags in the
flow simulator to improve/fix convergence and mass issues (i.e., by setting the flag --linear-solver=cprw to change the linear solver,
by tightening the mb tolerances (--tolerance-mb), etc.).
by tightening the mb tolerances (--tolerance-mb), etc.).

The following are simulation results in a 1 m Cartesian grid `(spe11b1m.txt) <https://github.com/OPM/pyopmspe11/blob/main/examples/finner_grids/spe11b1m.txt>`_,
and the animation in the `main page <https://github.com/OPM/pyopmspe11/blob/main>`_ was generated using these results (the inizialization time of 1000 years was
skipped and the results were printed ever 25 years instead of 5 years):

.. code-block:: bash
pyopmspe11 -i spe11b1m.txt -o spe11b1m -m all -g all -r 840,1,120 -t 25 -w 0.1
.. figure:: figs/spe11b_sparse_data_1m.png

Sparse data in the 1 m Cartesian grid.

.. figure:: figs/spe11b_performance_1m.png

Performance data in the 1 m Cartesian grid.
Binary file modified docs/text/figs/animation.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/text/figs/spe11b_performance_1m.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/text/figs/spe11b_sparse_data_1m.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 4 additions & 4 deletions docs/text/related.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Related
=======

Below are some packages following the same configuration-file-to-postprocessing-folder approach;
check them out :).
check them out 🙂.

*************
pyopmnearwell
Expand All @@ -12,7 +12,7 @@ pyopmnearwell
.. image:: ./figs/pyopmnearwell.gif
:scale: 50%

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

********
expreccs
Expand All @@ -21,7 +21,7 @@ expreccs
.. image:: ./figs/expreccs.gif
:scale: 50%

`Expansion of ResourCes for CO2 Storage on the Horda Platform <https://github.com/daavid00/expreccs>`_.
`Expansion of ResourCes for CO2 Storage on the Horda Platform <https://github.com/cssr-tools/expreccs>`_.

*******
ad-micp
Expand All @@ -39,4 +39,4 @@ pymm
.. image:: ./figs/pymm.gif
:scale: 15%

`An open-source image-based framework for CFD in microsystems <https://github.com/daavid00/pymm>`_.
`An open-source image-based framework for CFD in microsystems <https://github.com/cssr-tools/pymm>`_.
54 changes: 54 additions & 0 deletions examples/finner_grids/spe11b1m.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
"""Set the full path to the flow executable and flags"""
mpirun -np 68 flow --tolerance-mb=1e-7 --linear-solver=cprw --newton-min-iterations=1 --enable-tuning=true --enable-opm-rst-file=true --output-extra-convergence-info=steps,iterations

"""Set the model parameters"""
spe11b master #Name of the spe case (spe11a, spe11b, or spe11c) and OPM Flow version (master or release)
complete gaswater #Name of the co2 model (immiscible or complete) and co2store implementation (gaswater or gasoil [oil properties are set to water internally in OPM flow])
cartesian #Type of grid (cartesian, tensor, or corner-point)
8400 1 1200 #Length, width, and depth [m]
8400 #If cartesian, number of x cells [-]; otherwise, variable array of x-refinment
1 #If cartesian, number of y cells [-]; otherwise, variable array of y-refinment [-] (for spe11c)
1200 #If cartesian, number of z cells [-]; if tensor, variable array of z-refinment; if corner-point, fix array of z-refinment (18 entries)
70 40 #Temperature bottom and top rig [C]
300 3e7 0.1 #Datum [m], pressure at the datum [Pa], and multiplier for the permeability in the z direction [-]
1e-9 2e-8 #Diffusion (in liquid and gas) [m^2/s]
8.5e-1 2500 #Rock specific heat and density (for spe11b/c)
0 5e4 1 #Added pore volume on top boundary (for spe11a [if 0, free flow bc]), pore volume on lateral boundaries, and width of buffer cell [m] (for spe11b/c)
0 0 #Elevation of the parabola and back boundary [m] (for spe11c)

"""Set the saturation functions"""
(max(0, (s_w - swi) / (1 - swi))) ** 1.5 #Wetting rel perm saturation function [-]
(max(0, (1 - s_w - sni) / (1 - sni))) ** 1.5 #Non-wetting rel perm saturation function [-]
penmax * math.erf(pen * ((s_w-swi) / (1.-swi)) ** (-(1.0 / 1.5)) * math.pi**0.5 / (penmax * 2)) #Capillary pressure saturation function [Pa]
(np.exp(np.flip(np.linspace(0, 5.0, npoints))) - 1) / (np.exp(5.0) - 1) #Points to evaluate the saturation functions (s_w) [-]

"""Properties sat functions"""
"""swi [-], sni [-], pen [Pa], penmax [Pa], npoints [-]"""
SWI1 0.32 SNI1 0.1 PEN1 193531.39 PENMAX1 3e7 NPOINTS1 1000
SWI2 0.14 SNI2 0.1 PEN2 8654.99 PENMAX2 3e7 NPOINTS2 1000
SWI3 0.12 SNI3 0.1 PEN3 6120.00 PENMAX3 3e7 NPOINTS3 1000
SWI4 0.12 SNI4 0.1 PEN4 3870.63 PENMAX4 3e7 NPOINTS4 1000
SWI5 0.12 SNI5 0.1 PEN5 3060.00 PENMAX5 3e7 NPOINTS5 1000
SWI6 0.10 SNI6 0.1 PEN6 2560.18 PENMAX6 3e7 NPOINTS6 1000
SWI7 0 SNI7 0 PEN7 0 PENMAX7 3e7 NPOINTS7 2

"""Properties rock"""
"""K [mD], phi [-], disp [m] (dispersion requires a Flow version newer than 17-11-2023), thconr [W m-1 K-1]"""
PERM1 0.10132 PORO1 0.10 DISP1 10 THCONR1 1.90
PERM2 101.324 PORO2 0.20 DISP2 10 THCONR2 1.25
PERM3 202.650 PORO3 0.20 DISP3 10 THCONR3 1.25
PERM4 506.625 PORO4 0.20 DISP4 10 THCONR4 1.25
PERM5 1013.25 PORO5 0.25 DISP5 10 THCONR5 0.92
PERM6 2026.50 PORO6 0.35 DISP6 10 THCONR6 0.26
PERM7 1e-5 PORO7 1e-6 DISP7 0 THCONR7 2.00

"""Wells radius and position"""
"""radius (0 to use the SOURCE keyword instead of well keywords, this requires a Flow version newer than 23-01-2024), x, y, and z position [m] (final positions as well for spe11c)"""
0 2700. 0.5 300. #Well 1
0 5100. 0.5 700. #Well 2

"""Define the injection values ([hours] for spe11a; [years] for spe11b/c)"""
"""injection time, time step size to write results, maximum solver time step, injected fluid (0 water, 1 co2) (well1), injection rate [kg/s] (well1), temperature [C] (well1), injected fluid (0 water, 1 co2) (well2), ..."""
25 25 0.01 1 0.035 10 1 0 10
25 25 0.01 1 0.035 10 1 0.035 10
950 25 0.01 1 0 10 1 0 10

0 comments on commit 4255ab1

Please sign in to comment.