Commit Graph

207 Commits

Author SHA1 Message Date
Andreas Lauser
95334957e0 EclWellManager: replace the manual well event detection by the one of opm-parser
to my defense I can say that the Schedule::events() API was not
present in opm-parser when the EclWellManager needed this. (I think it
wasn't available back then, maybe I just was not aware of it.)
2016-02-26 14:56:53 +01:00
Andreas Lauser
1b3df8cb35 ebos: fix GCC sign comparison warnings in threshold pressure code 2016-02-25 17:30:05 +01:00
Andreas Lauser
34d0184f7d fix the threshold pressure implementation
before the variable for threshold pressure is used, it should be
initialized!
2016-02-25 15:56:30 +01:00
Andreas Lauser
0012aac5bd ebos: avoid potential division by zero in transmissibility calculation
in practice this could happen if the NTG value for a cell is set to zero.
2016-02-25 12:50:59 +01:00
Andreas Lauser
704389d14f ebos: use the Opm::TransMult class to determine the transmissibility multipliers
this takes care of atrocities like the MULTFLT keyword...
2016-02-25 11:55:27 +01:00
Andreas Lauser
b3359206b5 ebos: fix a active vs cartesian cell index in the transmissibility code
ouch, that was a major fauxpas!
2016-02-24 16:11:14 +01:00
Andreas Lauser
81e285e306 ebos: fix the headercheck
most of this stuff broke because of OPM/opm-parser#677
2016-02-22 18:43:13 +01:00
Andreas Lauser
cc0a560d97 ebos: implement threshold pressures
the implementation also supports to calculate the threshold pressures
based on the initial condition (and it should work even for
MPI-parallel runs).
2016-02-22 18:43:04 +01:00
Andreas Lauser
a68337967f fix a bunch of deprecation warnings caused by OPM/opm-parser#687 2016-02-19 23:30:57 +01:00
Andreas Lauser
9bbd4550cb ebos: re-enable handling the PORV keyword
after OPM/opm-parser#687 has been merged, it is no longer "drive-by
created" by the ECL grid manager.
2016-02-19 23:27:53 +01:00
Andreas Lauser
7f878bcadf ebos: fix build
once again it was broken by a change in opm-parser for which the
original authors not care to fix the mess they caused in ewoms. this
time the culprit was OPM/opm-parser#677.
2016-02-19 21:59:59 +01:00
Andreas Lauser
4a54e93554 EclEquilInitializer: hack to pass through the effects of SWATINIT
the emphasis of this is on *hack*: in the long run, the opm-core
equilibration code should be replaced by something cleaner and more
versatile...
2016-02-17 18:51:43 +01:00
Andreas Lauser
dd3bf51262 ignore the PORV grid property
this is required because that property is "drive-by created" when
initializing the grid and the code in opm-autodiff ignores it. (and is
slightly inconsistent with what opm-parser does...)
2016-02-14 23:47:49 +01:00
Andreas Lauser
a235321076 ebos: mark the intensive quantity cache after a time step as invalid
only if hysteresis is enabled. This is necessary because after the
hysteresis update the same primary variables will result in a (usually
only slightly) different thermodynamic state than before the update.
2016-02-11 16:34:51 +01:00
Andreas Lauser
f992372341 EclPeacemanWell: use AD to calculate the rate equivalent BHP 2016-02-02 14:53:23 +01:00
Andreas Lauser
a0d6e9ab91 improve the stencil API, clean up the output writing code and increase openMP usage
the stencil can now be updated only for the primary degrees of freedom
and output modules can specify that they do not need extensive
quantities (which allows to speed up the writing code if none require
them.)

Also, all loops over the grid are now threaded (or rather, are
supposed to be), so openMP should be better utilized during the
linearization stage.
2016-02-01 17:25:23 +01:00
Andreas Lauser
ffe6c4ac7c Merge pull request #47 from andlaus/blackoil_improvements
adapt to the recent API changes in opm-material
2016-02-01 13:39:09 +01:00
Andreas Lauser
016768febc once more fix the build after opm-parser changes
this time, opm-parser#661 was the guilty guy...
2016-01-29 19:24:44 +01:00
Andreas Lauser
d1488f5252 adapt to the recent API changes in opm-material
the change for the inverse formation volume factors (instead of the
FVFs) is needed to keep the build happy, using the new
getRv_()/getRs_() infrastructure might slightly improve
performance. (the emphasis is *slightly* because it only changes
something if BlackOilFluidState is used for initialization and
initialization is not time critical in the first place.)
2016-01-29 11:57:41 +01:00
Andreas Lauser
c29780856f ebos: abort the program correctly in the parallel case
all processes must be aborted, whilst the error message should only be
printed once. Also, calling std::exit(1) results in "nicer" output (at
least on openMPI) because mpirun does not try to print a stack trace
for every process.
2016-01-24 18:17:22 +01:00
Andreas Lauser
003983cc87 ebos: notify the user about parallelism and Dune::CpGrid in a better way
now, we abort at run time if the user tries to use with Dune::CpGrid
in parallel simulations. The advantages are that during build there
will be no warning anymore (before the warning was printed at compile
time regardless of which grid was actually chosen), and that such
simulations cannot be started with more than a single process (before
they started just fine, but they did not work properly).

This code should be removed as soon as "Dune::CpGrid" gets its act
together and fixes the bug in the loadBalance() method.
2016-01-23 13:08:20 +01:00
Andreas Lauser
4d5d3491c0 fix the headercheck 2016-01-21 13:24:24 +01:00
Andreas Lauser
84192769a6 ebos: fix build breakage due to opm-parser#656 2016-01-21 12:51:12 +01:00
Andreas Lauser
2b43f5bb12 fix the headercheck 2016-01-17 21:15:27 +01:00
Andreas Lauser
195e6058f1 EclCpGridManager: disable parallelism (for now)
this is because the loadBalance() method of Dune::CpGrid is seriously
broken at the moment: it throws away elements even in sequential mode
for some more relevant grids. ("more relevant" == "Norne". Norne is is
buggy itself because it features two completely disjoint parts.)

but it is even worse than that: if the bug mentioned above bites,
Dune::CpGrid cannot even agree for itself how many elements it has
which causes the CartesianIndexMapper to segfault.
2016-01-17 21:15:23 +01:00
Andreas Lauser
879e8a613d make all tests and ebos compile when selecting float or quad as Scalar
at least, they compile as far as eWoms is concerned. Some external
libraries (in particular everything which uses SuperLU) still have
issues.

Also, there seem to be issues with the precision that is achievable
by the Newton method when using float.
2016-01-17 21:15:21 +01:00
Andreas Lauser
99a59c021f ebos: introduce a mapper from compressed to cartesian cell indices of the EQUIL grid
this is because the nice opm-core code which does the equil
initialization cannot cope with parallel grids and thus needs to get
a special treatment.
2016-01-17 21:15:18 +01:00
Andreas Lauser
8fc838cff3 VTK output modules: make the processElement() method a dummy if the VTK output is disabled
an interesting side effect is that the Newton convergence output is
only defined if the VTK output is enabled.

Also, this patch could be implemented more efficiently by retrieving
the EnableVtkOutput only once per output module (instead of once per
element).
2016-01-17 21:15:12 +01:00
Robert Kloefkorn
073f14ef3d merged from master. 2016-01-06 16:22:09 -07:00
Robert Kloefkorn
f97b6cb9b3 Merge remote-tracking branch 'upstream/master' into PR/ewoms-can-use-dune-fem 2016-01-06 16:21:17 -07:00
Andreas Lauser
bbe277b82e remove polyhedralgridconverter.hh
this became unused after the previous patch an I don't think it still
is needed for something. (right?)
2016-01-05 19:32:41 +01:00
Andreas Lauser
242a500f52 ebos: replace the macro mess to select the grid type by specialized grid manager classes
i.e., there is now a base class for the EclGridManagers and one class
for each type of grid (Dune::ALUGrid, Dune::PolyhedralGrid and
Dune::CpGrid). Selecting the concrete grid type is now done by
deriving the EclProblem's type tag from the type tag of the respective
grid manager.
2016-01-05 19:32:36 +01:00
Andreas Lauser
d49e2d7000 move collecttoiorank.hh to applications/ebos
that's because its applicability to non-ECL problems is quite limited.
2016-01-05 19:32:34 +01:00
Andreas Lauser
cf90450b94 move the CartesianIndexMapper to 'applications/ebos'
that's because its applicability for non-cornerpoint grids is _very_
limited. Also the class is renamed to 'AluCartesianIndexMapper'
(because its purpose is to be used in conjunction with dune-alugrid)
and the namespace is changed from 'Dune' to 'Ewoms'.
2016-01-05 19:32:32 +01:00
Andreas Lauser
0fc485e7ff ECL peaceman well: improve handling of multiple PVT regions
this class may still be not fully aware of PVT regions.
2016-01-05 11:54:27 +01:00
Andreas Lauser
2f741214d4 ECL restart file output: rename 'regionIdx' to 'pvtRegionIdx' 2016-01-05 11:54:26 +01:00
Andreas Lauser
2c8e1da7f3 ECL peaceman well: throw an exception if the BHP cannot determined
this used to be an assert(), but it is not a programmer error but
something which can happen during valid simulation runs.
2016-01-05 11:54:26 +01:00
Andreas Lauser
c44ad1ca3c ECL problem: some stylistic improvement
and a tiny bit of better performance since the rate vector of the
source term is only reset once.
2016-01-05 11:54:26 +01:00
Andreas Lauser
898940730e remove partial relinarization
the reasons are the same as for removing linearization recycling but
more so.
2016-01-05 11:54:26 +01:00
Andreas Lauser
f9b97334e4 remove the linearization recycling
linearization recycling lead to more complex code and -- more
importantly -- frequently caused problems for simulators.
2016-01-05 11:54:26 +01:00
Andreas Lauser
0cbc6839f2 adapt to the recent blackoil API changes of opm-material 2016-01-04 15:32:55 +01:00
Andreas Lauser
8272ec5528 ebos: enable the new cache for the storage term by default
on my machine, this accelerates the linearization by about 30% for
SPE9 (6.4 instead of 8.7 seconds).
2015-11-27 16:56:38 +01:00
Andreas Lauser
aaecf3ee33 remove an unneded Toolbox::value()
operator>=() is available for Opm::Evaluation, and its efficiency is
the same as explicitly comparing the value. Let's thus remove this to
reduce optical noise.
2015-11-26 16:01:35 +01:00
Andreas Lauser
a63a4f2bdc make most indices unsigned
(instead of using 'int'.) This triggered quite a few compiler warnings
which are also dealt-with by this patch.
2015-11-18 18:09:56 +01:00
Andreas Lauser
bac1a6990d use the same value as opm-{core,autodiff} for the gravity constant
also, make setting this vector more bullet-proof.
2015-11-18 11:49:00 +01:00
Andreas Lauser
4f4e25c25f ebos: do the gravity correction the same way as opm-autodiff
i.e., calculate the pressure which the exterior cell of a face would
exhibit at the depth of the interior one (instead of bringing both to
the depth of the face).

because the average fluid density is used, there should not be a
difference because of this.
2015-11-18 11:49:00 +01:00
Andreas Lauser
1c02969608 do not iterate over all wells on DOFs which are not penetrated by any wells
for large problems with many wells the performance impact of this is
probably even measureable.

Also, this patch makes it possible to access the well manager outside
of the problem. In the normal case, this should be rarely needed, but
it can come in handy for debugging purposes.
2015-11-18 11:33:51 +01:00
Andreas Lauser
55c4bdf417 ebos: use the average phase density for the gravity correction
this does *not* make more sense than using the cell densities, but it
looks like E100 does it that way. (so we do it the same in ebos.)
2015-11-04 13:41:57 +01:00
Andreas Lauser
ce517e5e3d ebos: fix a GCC sign comparison warning 2015-10-29 00:22:09 +01:00
Robert Kloefkorn
2f8aa62db2 EclWellManager: only insert well that are located on the process. Not perfect yet. 2015-10-27 13:04:29 +01:00