Commit Graph

215 Commits

Author SHA1 Message Date
Andreas Lauser
c5f55c1cd2 black oil fluid system: keep the saturation pressure spline consistent
It was not updated if the set PvtoTable was used which then lead to
segfaults.
2014-07-25 15:06:14 +02:00
Andreas Lauser
a43fec22cc black-oil fluid system: remove debugging artifact
*grr* which idiot forgot this one?
2014-07-24 18:48:38 +02:00
Andreas Lauser
4d61a9dc3f Black-oil fluid system: do not explicitly include the composition in the tabulated density
It might have to be included, but it made the reservoir test in eWoms
fail...
2014-07-24 14:12:05 +02:00
Andreas Lauser
de558bdd3b black oil system: use the UniformXTabulated2DFunction class for the oil formation factor
this means that undersaturated oil is now properly supported.
2014-07-24 14:12:05 +02:00
Andreas Lauser
8f52b80448 refactor the 2D tabulation classes
- the StaticTabulated2DFunction class and the base class
  (Tabulated2DFunction) are gone
- the DynamicTabulated2DFunction class has been renamed to
  UniformTabulated2DFunction
- a new class called UniformXTabulated2DFunction has been
  introduced. Like UniformTabulated2DFunction, it assumes uniform
  intervalls of the sampling points in X direction, but in contrast to
  UniformTabulated2DFunction, the Y locations of the sampling points
  can be set freely (as long as they are specified in increasing order
  for each x value)
- add a unit test for the two tabulation classes
2014-07-24 14:12:04 +02:00
Andreas Lauser
a7126a7a13 peng-robinson test: fix it, so that it produces correct output 2014-07-23 17:45:12 +02:00
Andreas Lauser
b02cff76b1 black oil density: correct the gas mass fraction in saturated oil 2014-07-22 19:16:55 +02:00
Andreas Lauser
a1de23b4fc peng-robinson test: correct calculation of the Rs factor 2014-07-08 12:43:44 +02:00
Andreas Lauser
506700d579 BlackOilFluidSystem: some improvements
the biggest one was that the Rs factor was used incorrectly: instead
of "surface volume of gas per volume of saturated reservoir oil" it is
defined as "surface volume of gas which a volume unit of surface oil
dissolves at reservoir pressure".

Besides this, there are a few smallish improvements like the oil
density being a function which can be called without having the
boilerplate objects (i.e., the fluid state and parameter cache
objects) instantiated.
2014-07-07 12:09:45 +02:00
Andreas Lauser
d9e24bb5c0 improve a few comments and error messages 2014-07-07 12:07:48 +02:00
Andreas Lauser
ced870fbd2 fix another off-by-one error
quite certainly, this won't be the last...
2014-05-23 14:02:13 +02:00
Andreas Lauser
3d91ac3577 1p/2p fluid systems: rename them to more sensfull class names
they were totally inconsistent with the remaining fluid systems
because their file names stated with a number and "P" was used instead
of "Phase"...
2014-05-08 17:02:28 +02:00
Andreas Lauser
5eaedaddf6 make the EclDefaultMaterial actually work
in the sense that it is now used by an eWoms simulator
2014-04-28 19:11:53 +02:00
Andreas Lauser
90e1375e0b Black-oil fluid system: take advantage of opm-parser
this considerably simplifies reading blackoil PVT parameters from an
ECL deck file.
2014-04-25 17:10:44 +02:00
Andreas Lauser
805750a82d convert to opm-parser
and fix some (likely) bugs...
2014-04-16 12:30:13 +02:00
Andreas Lauser
c0a7947357 fluid systems: rename unexpressive phase and component indices
These index names have been fully fluid system dependent for a while
and are supposed to be just used for convenience. This means that
phase names are now actual camelCase words.
2014-04-03 17:27:22 +02:00
Andreas Lauser
96b3d753e2 EclDefaultMaterial: fix sign error 2014-03-27 19:06:50 +01:00
Andreas Lauser
1c374b8391 fluid-matrix interactions: remove "3p" folder
because fluid-matrix interactions have been independent of the number
of phases for a while. The only law left in this folder (implementing
the Parker-van Genuchten law) has been moved one folder up and been
cleaned up considerably.
2014-03-27 19:06:50 +01:00
Andreas Lauser
df9efcf342 some documentation and stylistic updates 2014-03-05 16:30:54 +01:00
Benjamin Faigle
9674745464 Add functions for the heat capacity to the components air and co2
Enabled access to these methods in the co2-brine-fluidsystem (only
pure-phase heat capacities are used). reviewed by Klaus

Dumux-Svn-Revison: 12462
Ported-By: Andreas Lauser <and@poware.org>
2014-02-23 15:10:04 +01:00
Andreas Lauser
b77ecb46c5 h2o-n2 fluid system: use the total pressure to calculate the component enthalpies
this is analogous to commit r12402 of dumux. The current approach was
doing the "compositional consideration" twice. (and the difference
between using the partial pressure for the enthalpy and using the
total one in conjunction with weighting by mass fraction should be
neglectible for "almost ideal" gases, i.e., for low pressure and
temperature scenarios.)
2014-02-04 22:02:00 +01:00
Andreas Lauser
b333007fc3 FluidSystems::BlackOil: increase the fugacity coefficient of gas in water by a factor of 1000
this makes the PVS model work with SPE-9 and the NCP model to converge
better...
2014-01-24 15:15:22 +01:00
Andreas Lauser
f386599669 remove all vim and emacs modelines
for emacs, add a toplevel .dir-locals.el file instead...
2014-01-16 18:41:00 +01:00
Andreas Lauser
78a30208d8 simplify the valgrind client request helpers
the macros where used to make the influence of the valgrind calls zero
even for debug builds if valgrind client requests were
unavailable. Since this resulted in some inconsistencies, and the
performance hit is not terribly large, we now always use the same
inlined functions. For optimized builds the impact of those is still
zero...
2013-12-14 12:03:44 +01:00
Andreas Lauser
249592a57d fix the screw-ups caused by a0101ee 2013-12-03 12:13:53 +01:00
Andreas Lauser
019d188efb update the in-file copyright holder statements
this patch is quite large as there were various bug fixes to the
script which generates these statements
2013-12-02 17:26:34 +01:00
Andreas Lauser
a0101ee033 replace in-source copyright comments by the standard OPM ones 2013-12-02 16:35:57 +01:00
Andreas Lauser
96f38877f5 remove all print statements in classes intended for use of other modules
because these classes should not have any side effects. case in point:
the warnings intended to be printed once get printed once per process
which can be quite a few times for parallel simulations with thousands
of cores. This could also be avoided by checking the MPI rank, but
IMHO this is way too much boilerplate code for a feature of questionable
value.
2013-11-23 00:47:49 +01:00
Andreas Lauser
79c38f94b7 Parker-Lenhard: work around a debug mode bug of GCC 4.4
The resize() method for std::vector seems to copy an uninitialized
object for the new objects in the array on GCC 4.4. This means that we
should not assume that the copied objects are finalized in the
Parker-Lenhard parameters. Strangely enough this only seems to affect
older GCCs (at least 4.4) and only in debug mode...
2013-11-16 10:10:42 +01:00
Andreas Lauser
72bc625357 EclDefaultMaterial: produce something meaningful for krn()
at least mathematically meaningful. whether it makes sense phyiscally
is still to be determined...
2013-11-15 17:10:48 +01:00
Andreas Lauser
34d1934e60 Capillary pressure laws: enforce that parameter objects are finalized before they are used
this only has an effect if compiled in debug mode, i.e., if the NDEBUG
symbol is not defined.
2013-11-15 16:15:10 +01:00
Andreas Lauser
e1ad7112b0 add a tabulated piecewise linear two-phase material law
this is intended to be used for ECLIPSE saturation curves, but the
code is more generic. (Be aware that using cubic splines for the
interpolation between sampling points is probably a better choice in
most cases.)
2013-11-14 18:46:27 +01:00
Andreas Lauser
555154661e fix headercheck 2013-11-14 11:55:11 +01:00
Andreas Lauser
a7f6049a96 make EclDefaultMaterial three-phase API conformant 2013-11-14 11:55:00 +01:00
Andreas Lauser
5c57117365 guard macros: _HH -> _HPP 2013-11-13 18:45:52 +01:00
Andreas Lauser
62e7aad7f5 test_fluidmatrixinteractions: mark some variables as OPM_UNUSED
this should prevent some warnings on GCC 4.6. Thanks to Arne Morten
Kvarving for investigating this.
2013-11-13 12:27:37 +01:00
Andreas Lauser
696503c51e Brooks-Corey: explicitly include <cmath>
it seems to be implicitly included by newer compilers, but not GCC
4.4. In this case I agree with GCC 4.4...

Thanks to Bård Skaflestad for the hat-tip.
2013-11-13 11:37:37 +01:00
Andreas Lauser
8811400173 rename "pcwn" to "pcnw" and "pcng" to "pcgn"
because it is p_n - p_w and p_g - p_n instead of the other way round.
2013-11-12 18:11:40 +01:00
Andreas Lauser
aabce7f005 fluid-matrix interactions: API extension
- add methods to calculate the derivatives of the capillary pressures
  and relative permeabilities with regard to the phase saturations,
  temperature, absolute pressure and phase composition
- extend the unit test to enforce the above
- make the NullMaterial conform to the API and add it to the unit test
- introduce Opm::NullMaterialTraits for material laws that don't use
  any phase indices
2013-11-12 18:11:40 +01:00
Andreas Lauser
abab1d9a87 add the three-phase capillary pressure law Eclipse uses by default 2013-11-11 13:23:55 +01:00
Andreas Lauser
19db7481fd Cosmetic change: remove the subdirectories for sources of the tests
that was a leftover of eWoms/Dumux...
2013-11-11 13:23:55 +01:00
Andreas Lauser
dd70732ae9 Refactor the twophase laws
They are now all generic capillary pressure laws, but with some
additional methods to make working with them easier. For this reason,
they have been moved up one directory to opm/material/fluidmatrixinteractions

Also, a unit test which ensures that all capillary pressure laws
conform to their respective APIs has been added.
2013-11-11 13:23:47 +01:00
Andreas Lauser
0f7c888100 rename doxygen groups "fluidmatrixinteractions(laws|params)" to "FluidMatrixInteractions"
and improve the van Genuchten law
2013-11-05 13:13:16 +01:00
Andreas Lauser
2b493c0e95 fix end of namespace comments
long live python ;)!
2013-11-04 14:15:53 +01:00
Andreas Lauser
febb8d9d8f blackoil fluid system: rename gasFormationFactor to gasDissolutionFactor
that was a thinko/reado of mine...
2013-11-04 14:07:53 +01:00
Andreas Lauser
ca94fdeb88 capillary pressure laws: move the M-phase laws one directory up
since they are also generic in the sense that they can depend on
arbitrary quanities expressed by the fluid state, not just
saturations...
2013-11-03 17:03:36 +01:00
Andreas Lauser
b51bf6d0b1 H2O: remove too expensive range checks
when they worked, they were only used in debug mode anyway...
2013-11-03 15:38:00 +01:00
Andreas Lauser
9b5e1f27e6 Valgrind: fix a small issue that only appears with multiple compile units
this were forgotten 'inline' statements for some client request functions.
2013-10-29 12:23:13 +01:00
Andreas Lauser
851063c659 change API version to 3.0 2013-10-12 16:17:50 +02:00
Andreas Lauser
37777ac9e9 tabulated component: don't catch NumericalProblem anymore
this lead to a compiler warning on gcc 4.8 that this case was already
covered by catching std::exception. Since we did the same in both
branches anyway, these statements were not required...
2013-09-25 16:14:24 +02:00