Commit Graph

109 Commits

Author SHA1 Message Date
Andreas Lauser
0c4fd68f2a update version number to 2015.10 2015-03-29 15:13:19 +02:00
Andreas Lauser
2c5d51f841 change the version number to the scheme used by eWoms
i.e., there is no distinction between the "API version" and the
"Release version" anymore. IMO, the split scheme is just confusing for
no benefit because we are handling API/ABI changes in a pretty relaxed
manner anyway: i.e., whenever the "release version" gets incremented,
the "API version" needs to follow suite!
2015-03-29 15:07:06 +02:00
Andreas Lauser
898930b3d5 black oil fluid system: implement vaporized oil 2015-02-11 15:31:15 +01:00
Andreas Lauser
dc5fdd7059 change the surface temperature to 15.56 degrees Celsius
this is what Eclipse seems to use, at least according to the STDCOND
keyword...
2015-02-05 16:22:31 +01:00
Andreas Lauser
e036cbea5c Black oil fluid system: use dynamic polymorphism to determine the phase quantities
this allows to freely mix and match ECL keywords like PVT[OG],
PVC[OG], PVDC[OG], and PVTW...
2015-02-05 16:22:31 +01:00
Andreas Lauser
f896d85f4f add a wrapper macro for the c++-2011 "final" keyword 2015-02-05 16:03:47 +01:00
Andreas Lauser
ee05d77f79 black oil fluid system: use extrapolation for all tabulated quantities
this seems to be required for my version of SPE9...
2015-01-26 16:08:25 +01:00
Andreas Lauser
ea3c68694b black oil fluid system: correct a few method descriptions and names 2015-01-26 12:56:53 +01:00
Andreas Lauser
d074070e11 Revert "rename {gil,gas}FormationVolumeFactor to \1FormationFactor"
This reverts commit 1cf745943a. After a
more thorough investigation, the cannonical name of these quantities
turned out to be "* formation volume factor"...
2015-01-26 12:03:42 +01:00
Andreas Lauser
1cf745943a rename {gil,gas}FormationVolumeFactor to \1FormationFactor
the new name is shorter, not less descriptive and it seems like it is
also more common...
2015-01-25 18:20:58 +01:00
Andreas Lauser
b1c35e0e0d Black oil fluid system: make immiscible components less dissolvable
This is only relevant for the approximation which uses large instead
of infinite fugacity coefficients for immiscible components. The
motivation is to bring the solution of the NCP flash solver closer to
what's expected using the blackoil assumptions directly. (Physically
speaking, the result is less realistic in most cases, though...)
2015-01-21 15:33:12 +01:00
Andreas Lauser
f1cb777fb0 Tabulated functions: fix the bisection code
seems like somebody can't properly implement an interval-halving
algorithm. Maybe I should consider to give back my degree...
2015-01-21 15:33:12 +01:00
Andreas Lauser
0b675bfa38 Black oil fluid system: fix Rs <-> XoG conversions
some stupid guy messed them up...
2015-01-21 15:33:09 +01:00
Andreas Lauser
2f343412b7 black oil fluid system: Do things the Eclipse way
i.e., interpolate between inverse volume factors and the inverse of
the product of the volume factors. I have my doubts if these
"optimizations" make the results physically better, but it seems like
they at least make things different...
2015-01-21 15:32:13 +01:00
Andreas Lauser
a44bb9b887 add methods to access the sample points to the tabulated function classes
also, the getSamplePoint() has been renamed to valueAt()
2015-01-21 15:32:13 +01:00
Andreas Lauser
3f82e67847 Black oil fluid system: Use piecewise linear interpolation for all parameters
seems like this is what causes the discrepancies to eclipse in SPE1.
2015-01-21 15:32:05 +01:00
Andreas Lauser
e01cf39448 add a class for piecewise linear 1D functions
this class exhibits almost the same interface as Opm::Spline in order
to faciliate replacing one by the other.
2015-01-16 17:50:39 +01:00
Andreas Lauser
df0dc97c53 fluid-matrixinteractions: remove the derivative functions
these were unused, quite likely broken and could only calculate the
derivatives with regard to some quantities.

if the general derivatives of the relperms and capillary pressures are
ever required, finite differences can be used to save the
day... (these *might* be sightly slower, but they are automatically
consistent with the function.)
2015-01-08 17:57:40 +01:00
Andreas Lauser
0c8a5503d7 fix the headercheck
i.e. make all headers includable without preconditions.
2015-01-06 14:38:00 +01:00
Andreas Lauser
e97c16eeb5 PiecewiseLinearTwoPhaseMaterial: use constant extrapolation.
this makes the result identical to the saturation functions used by
opm-core, although I have my doubts if this is the physically correct
thing to do.
2014-12-16 17:18:54 +01:00
Andreas Lauser
33671258eb EclDefaultMaterial: fix typo
it is Sw instead of Sg. with this, the results for SPE9 seem
reasonable again.
2014-12-16 17:17:37 +01:00
Andreas Lauser
578980e16a PiecewiseLinearTwoPhaseMaterialParams: use the same API as SplineTwoPhaseMaterialParams
this allows to use the two by changing the class name but without
requiring any further code changes...
2014-12-08 17:50:36 +01:00
Andreas Lauser
c267cacbd6 water viscosity: calculate it the same way as documented by the Eclipse RM 2014-12-08 14:58:02 +01:00
Andreas Lauser
8109900567 ECL default material: make the oil relperm match that of autodiff
at least it seems to be very similar for SPE1. the difference in the
BHP of the wells for SPE1 is significantly reduced (but still too
large) by this...
2014-11-27 19:26:47 +01:00
Andreas Lauser
e57b4410f1 ECL default material parameters: add connate water 2014-11-27 19:22:06 +01:00
Andreas Lauser
447268e79d remove unused variable to fix compiler warnings 2014-10-29 16:07:58 +01:00
Andreas Lauser
1f91c1fd93 rename PengRobinsonparamsMixture.hpp to PengRobinsonParamsMixture.hpp 2014-10-29 16:07:21 +01:00
Andreas Lauser
6b5973d6a1 black oil fluid system: use Rs instead of XoG and interpolate the inverse B factor
this is much closer to how things are done in Eclipse. For the
external API, nothing changes provided that only the "official" fluid
system API is used...
2014-10-01 13:46:12 +02:00
Andreas Lauser
f4eaf1769b UniformXTabulated2DFunction: fix interval halving code
now the values for X and Y can be added in ascending or descending
order. The descending code path is pretty slow though, and it is still
possible to screw up the object by specifying the inputs in a totally
unsorted manner. (At this place, I don't really care about these two
things, though.)
2014-10-01 13:41:44 +02:00
Joakim Hove
59bd096d40 Merge pull request #18 from andlaus/table_improvements
adapt the the table related API changes of opm-parser
2014-09-19 15:27:53 +02:00
Andreas Lauser
b865227cfc adapt the the table related API changes of opm-parser 2014-09-18 16:49:02 +02:00
Andreas Lauser
0f17c64f39 Black oil fluid system: copy the undersaturated oil info from a master table
... instead of just assuming some arbitrary behavior. this fixes SPE9
for eWoms as far as the fluid system is concerned. (the ecl_blackoil
still seems to have some problems with anisotropic permeability. this
will hopefulls be fixed soon.)
2014-08-19 15:53:28 +02:00
Andreas Lauser
feeedb7428 properly deal with water compressibility and water "viscosibility" 2014-08-15 16:26:50 +02:00
Andreas Lauser
39cfb4e38a Make it work if HAVE_OPM_PARSER is false
currently, this can't happen because opm-material depends mandatorily
on opm-core which in turn requires opm-parser. In the future, this
might change, though...
2014-08-15 14:01:44 +02:00
Andreas Lauser
197fe4b1e3 black oil fluid system: fix stupid bug when setting the gas viscosity
gas viscosity != gas formation volume factor (even if the values are
somewhat similar)
2014-08-12 16:45:19 +02:00
Andreas Lauser
1051a964e0 black oil fluid system: rename surfaceDensity() to referenceDensity()
because it seems like what eclipse uses in the DENSITY keyword is not
really for surface pressure but at the pressure where the phase's
formation volume factor is one. (this pressure does not seem to be
specified and can potentially be different for every fluid phase.)
Thus rename surfaceDensity() to referenceDensity() and remove the
logic to allow volume formation factors which are not equal to one at
the reference pressure. (i.e., formerly the surface pressure.)
2014-08-12 15:49:01 +02:00
Andreas Lauser
d4a58aefd3 fluid systems: return human readable strings for the phaseName() method
this avoids a bit of guess-work...
2014-08-07 19:19:03 +02:00
Andreas Lauser
883f032aa0 {Spline,PiecewiseLinear}TwoPhaseMaterial: limit the relperms to [0, 1]
it used to be the range of the sampling points. If for some reason the
sampling points describe a subset of the full range, the material laws
use extrapolation outside of the table and properly limit the values
of that operation.

In the real world, the effect of this change is rather limited because
all tested tables used the range...

TODO: adapt the evalDerivative() methods. This is not very urgent, though
because they are usually not used...
2014-08-06 14:53:42 +02:00
Andreas Lauser
34f50e6613 fluid-matrix interactions: add a tabulated two-phase pc/kr law which uses splines
compared to the variant which uses linear interpolation, this makes
the resulting curves smoother and thus hopefully improves the
convergence rates of the simulations.
2014-08-06 13:52:23 +02:00
Andreas Lauser
1108f24c33 black oil fluid system: fix build on GCC 4.4
this compiler is for some reason not able to determine the number of
phases for externally defined attributes the way it was done. this is
most likely a compiler bug (or it is a left-over ideosyncrasy from
c++-2003 which was not yet removed for GCC 4.4...)
2014-08-06 11:26:25 +02:00
Andreas Lauser
20b63fdb6e Black oil fluid system: implement support for multi-region PVT tables
it is slightly hacky that the ParameterCache is used to specify the
PVT region. Having said that, the multiple PVT regions stuff in no way
based on physical assumptions, but is just a way to fit the black-oil
model to the measured values of real reservoirs...
2014-08-05 16:27:08 +02:00
Andreas Lauser
fbf81ef8ec Black oil fluid system: add support for decks which only specify gas-saturated oil in PVTO
SPE-9, I'm looking at you!!! (this is probably still different from
what Eclipse does, but it should be more or less okay from the
thermodynamic POV.)
2014-07-29 16:01:11 +02:00
Andreas Lauser
9534d56f13 black oil fluid system: don't use the numerical value for the surface pressure directly
this is just a minor clean up which does not change anything...
2014-07-25 15:06:15 +02:00
Andreas Lauser
291928955a black oil fluid system: remove commented out density calculation code
I thought about this a bit and came to the conclusion that since the
composition of oil is already fixed in that context, only the pressure
dependance needs to be included in addition.
2014-07-25 15:06:15 +02:00
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