Commit Graph

194 Commits

Author SHA1 Message Date
Andreas Lauser
d51934ce37 ebos: don't break the downstream build because of the SimulatorParameter mess
this now works with the unmodified master version of flow from
opm-simulators. we take the liberty to emit a deprecation warning,
though. this complicates things quite a bit.
2017-10-10 13:18:09 +02:00
Andreas Lauser
ef2e60e454 ebos: simplify passing of pre-parsed ECL decks
This gets rid of some special-purpose code in generic places (i.e. the
`SimulatorParameter` class) and no special hacks to the property and
parameter system are required anymore.
2017-10-07 21:28:25 +02:00
Arne Morten Kvarving
fde56c93b2 Merge pull request #209 from andlaus/remove_dune_2_3_support
remove support for dune < 2.4
2017-09-22 11:39:59 +02:00
Robert Kloefkorn
f18b1cdf59 [feature][Simulator] allow parameters to be passed from outside to
simulator. The default behavior is unchanged and the parameters are
empty.
2017-08-23 15:51:51 +02:00
Andreas Lauser
79fc6c68cd add a template class for conditionally storing attributes and use it in ebos 2017-07-21 21:38:13 +02:00
Andreas Lauser
96381e3ed7 remove support for dune < 2.4
this allows quite a substantial amount of code decluttering, mainly
because Dune 2.4 renamed mapper.map() to mapper.index().
2017-07-13 14:08:02 +02:00
Robert Kloefkorn
f1da775f41 [bugfix] dimension was renamed in Geometry, so use from Element to be
consistent with earlier DUNE versions.
2017-06-23 22:58:50 +02:00
Robert Kloefkorn
2aada96d8c [bugfix] fix build of ebos for Grid != CpGrid. 2017-06-23 22:58:49 +02:00
Tor Harald Sandve
195209982e Add support for PLMIXNUM
also fix some issues with the MISCNUM
2017-06-21 10:27:25 +02:00
Tor Harald Sandve
ecae9d3a78 Address comments frow the review. 2017-06-21 08:03:44 +02:00
Tor Harald Sandve
3dd7fd0b3a Add polymer model to ebos
Adds a conservation equation for polymer.
Polymer concentration in the water phase is used as primary variable
The polymer influences the viscosity of the water, and leaves gas and oil
uneffected.

A shear multiplier is computed if PLYSHLOG and/or SHRATE is specified
based on either velocity or shrate.
The shear multiplier effects the water and polymer viscosity.

Tested and verified on the test cases in polymer_test_suite
2017-06-21 08:00:31 +02:00
Robert Kloefkorn
c8bf519e5e [bugfix] fix propName for ROCKNUM. 2017-06-20 18:08:12 +02:00
Joakim Hove
05bc61e4ba Using std::time_t from TimeMap 2017-06-19 22:13:25 +02:00
Andreas Lauser
bff4c8ade9 ebos: add the raw array of PVT numbers.
this can be used by flow_ebos to be passed to legacy code.
2017-06-16 15:12:27 +02:00
Andreas Lauser
f334bb32b9 ebos: add support for the ROCKOPTS keyword
this becomes important if th region which is supposed to be used by
ROCK is not the same as the region for the PVT properties.
2017-06-16 15:12:26 +02:00
Andreas Lauser
3b37038043 ebos: do not mistake the pressure for the gas saturation anymore
this is a copy-and-pasto that was introduced with #189.
2017-06-16 09:25:56 +02:00
Andreas Lauser
89b21eb641 ebos: fix the compilation
one must use eclProps.getDoubleGridProperty() while the has() method
is called eclProps.hasDeckDoubleGridProperty() (mind the Deck!).
2017-06-14 13:36:37 +02:00
Andreas Lauser
55a5a3a848 ebos: reduce direct deck usage
this reduces the number of direct deck accesses in `EclProblem` in
favour of `EclipseState`-grid properties. as far as i can see,
directly using the deck object cannot fully be avoided because
`EclipseState` does not seem to provide internalized versions of all
these keywords yet.
2017-06-13 16:54:39 +02:00
Tor Harald Sandve
f14ea0e3af Add support for miscible solvent runs
- initialization only via Ecl Deck
- adds modification of relperms and cap-pressures for miscible runs
- adds TL mixing model for effective viscosity and density calculations

Tested on SPE1CASE2_SOLVENT_MISC_TL, SPE9_CP_CO2_MISC_TL, SPE5CASE1-3
and SPE3CASE1_SOLVENT_MISC
2017-05-24 10:52:04 +02:00
Andreas Lauser
bcdc4e5e38 blackoil: implement the immiscible solvent extension
Conceptually this is IMO pretty questionable, since it adds a second
"gas phase" that does not mix with "ordinary" gas. I suppose the
reason why this extension was conceived by E100 is that if all you
have is hammer, everything looks like a nail...

Functionality-wise, this patch is still not fully complete because
miscibility of the solvent "phase" is not yet implemented. As far as I
can see, the API changes required by miscibility are quite limited,
though.
2017-05-05 10:46:53 +02:00
Andreas Lauser
96869b6a2f make explicit initialization for twophase cases work
if the initial solution is explicitly given by the deck using the
PRESSURE, SWAT, etc. keywords, the specified state can be
thermodynamically impossible. To avoid inconsistencies, we use a flash
calculation to find a state that is in thermodynamic equilibrium and
exhibits the same masses as the explicitly specified solution. Since
the flash solver needs to compute quantities for all fluid phases, but
two-phase blackoil simulations usually do not specify the properties
of one phase, the flash solver crashed. This patch works around that
issue by simply not using the flash solver in the twophase case, i.e.,
the explicit initial condition must be thermodynamically consistent in
order to produce the stable results for a different choice of primary
variables.
2017-04-18 16:11:44 +02:00
Andreas Lauser
346710c5af ebos: hysteresis needs to be updated for all elements
in the parallel case, this avoids the participating processes from
desyncronizing if the solution is consistent on all processes.
2017-04-15 15:12:15 +02:00
Andreas Lauser
b429af41b1 ebos: no longer fail if the EQLDIMS keyword is not explicitly mentioned in the deck
we use the "Eqldims" object which is exposed EclipseState.
2017-02-13 19:20:27 +01:00
Robert Kloefkorn
7f81518b0d When EnableEclOutput is false the EclWriter should not be created.
This fixes a problem with collecttoiorank which needs to be investigated
separately.
2017-02-10 13:45:44 +01:00
Andreas Lauser
a284089d73 adapt to the move of the valgrind client requests into the Opm namespace 2017-02-09 18:25:44 +01:00
Andreas Lauser
7a7d6d868d ebos: fix the interactions between SWATINIT and threshold pressures
hopefully this makes standalone `ebos` arrive at the same initial
condition as `flow_ebos` if both, SWATINIT and threshold pressures are
enabled. we need to calculate the initial condition twice either
threshold pressures and SWATINIT are enabled. (`ebos` and `flow_ebos`
diverged after OPM/opm-core#1129.)

the proposed patch is a kludge IMO, but in the light that in my
opinion, SWATINIT and threshold pressures are both physically not
justified and given the fact that SWATINIT must not be considered for
the threshold pressues should be considered to be a bug of the
reference simulator, I think the patch is okay.
2017-01-18 16:46:53 +01:00
Andreas Lauser
61c501a31d change the order of OPM_UNUSED and variable name
it seems like some compilers (GCC 4.9.2?) are picky about this and
require

```c++
TypeName VariableName __attribute__ ((__unused__))
```
2017-01-17 13:28:56 +01:00
Atgeirr Flø Rasmussen
3d9f1af26b Silence release mode unused argument warnings. 2016-12-30 10:12:08 +01:00
Atgeirr Flø Rasmussen
5724244b4f Silence unused argument warnings with OPM_UNUSED. 2016-12-30 10:03:14 +01:00
Andreas Lauser
8c6e6dc410 ebos: refactor the way SWATINIT is dealt with
we now store the maximum oil-water capillary pressure and apply it to
the material parameters later. this simplifies things within the
EquilInitializer somewhat and also allows external code (i.e.,
flow_ebos) to choose when SWATINIT gets applied.
2016-12-16 18:48:34 +01:00
Andreas Lauser
de9eea31bd EclProblem: provide access to the "raw" transmissibilities object 2016-12-16 18:47:52 +01:00
Andreas Lauser
a6191a2345 the new home of Valgrind.hpp is opm-common! 2016-12-14 12:38:12 +01:00
Andreas Lauser
e1d11da6d6 EclProblem: fix the type returned by the const version of materialLawManager()
it is supposed to a shared pointer to a constant object, not a
constant pointer to a mutable object...
2016-12-10 10:53:28 +01:00
Andreas Lauser
4b2156a071 ebos: update the PffGridVector for transmissibility after geologic events 2016-12-08 12:26:32 +01:00
Andreas Lauser
5067ce2f27 ebos: use the transmissibilities as edge weights for load balancing
this makes creating the grid a bit slower because the
transmissibilities need to be calculated twice: once for the
sequential grid and once for the distributed one. while corresponds to
the way `flow_legacy` does the load balancing and it should allow
better results, this does not seem to be the case for the Norne deck
if ZOLTAN is not available:

After loadbalancing process 3 has 4413 cells.
After loadbalancing process 2 has 12390 cells.
After loadbalancing process 0 has 13629 cells.
After loadbalancing process 1 has 21253 cells.

i.e., process 1 is responsible for almost 5 as many cells as process
3.
2016-12-07 20:24:48 +01:00
Andreas Lauser
36c010c956 ebos: replace the opm-parser related pointers/smart pointers by references
this seems to be the spirit of the season. note that now the deck
object must be copied, but I suppose that copying it is pretty cheap.
2016-12-07 20:24:48 +01:00
Jørgen Kvalsvik
3088068e37 Mini deck is reference, not pointer 2016-12-01 16:17:52 +01:00
Andreas Lauser
4a0832030c EclProblem: add docstrings for the materialLawManager() methods 2016-11-30 14:24:15 +01:00
Andreas Lauser
4ef6d5d1ce EclProblem: add a porosity(elemIdx) method
this is not a generic API but makes emulating legacy stuff which
requires the porosity quite a bit easier in flow_ebos.
2016-11-30 14:21:04 +01:00
Andreas Lauser
a3ddd2066b ebos: make it possible to easily disable SWATINIT
in flow_ebos, this code collides with the flow part.
2016-11-30 14:20:44 +01:00
Andreas Lauser
c4c00bdaaa implement two-phase blackoil simulations 2016-11-22 15:22:41 +01:00
Andreas Lauser
6cf1eab4f4 ebos: export the ECL material law manager
this allows external code (i.e., flow_ebos) to reuse it.
2016-11-22 14:08:07 +01:00
Andreas Lauser
a5e859e4c6 discretizations: no longer depend on the problem to provide the mappers
Dune entity mappers seem to be dirt-cheap to create so there is not
much point in jumping through hoops to avoid this...
2016-11-17 19:44:17 +01:00
Andreas Lauser
759c2dbdaa move all applications into their top-level directory
thanks to [at]akva2 for the suggestion.
2016-11-11 15:04:04 +01:00