Commit Graph

34 Commits

Author SHA1 Message Date
Joakim Hove
b660cc1b6a Merge pull request #213 from atgeirr/conversion-factors
Conversion factors
2014-05-19 12:18:34 +02:00
Atgeirr Flø Rasmussen
61d1c1a2cf Make conversion factors more readable.
The using directives will put a lot into the Field and Metric
namespaces, but it should not be problematic.
2014-05-19 12:10:11 +02:00
Atgeirr Flø Rasmussen
799a52e8bc Embedded unit system from opm-core to ensure proper conversion factors. 2014-05-19 12:10:11 +02:00
Arne Morten Kvarving
3827ddca64 fixed: mark static symbols as such to quell warnings 2014-05-15 14:46:16 +02:00
Arne Morten Kvarving
670e8b692b changed: don't use parameter names that conflicts with member function names
quells warnings (with gcc 4.8)
2014-05-15 14:46:16 +02:00
Liu Ming
49376a554c Add PolymerDensity to system. 2014-03-18 08:19:15 +08:00
Liu Ming
52bd8cceb9 Add polymer density unit. 2014-03-17 09:12:14 +08:00
Andreas Lauser
849bc7df93 units: introduce a "ContextDependent" dimension
this is meant for those nasty keywords where the dimension of an entry
depends on a user-defined value of some field of a (potentially
different) keyword. One example for this are the surface rates of the
produced fluids for the .CON(INJ|PROD).* keywords which exhibit
different units depending on whether the user choses to control for
the surface gas or the liquid rate.

the approach taken in this patch is to convert all numbers to NaN if
the unit is queried in SI (via item->getSIDouble()). It might be more
desireable to throw an exception in this case, but this approach would
be more elaborate and NaNs should be quickly noticeable by the users
of this code.

I tried to adapt all implemented keywords, but it's quite likely that
I missed some...
2014-02-11 12:45:44 +01:00
Andreas Lauser
50f2288148 units: rename "m" to "Mass" 2014-02-11 12:45:44 +01:00
Andreas Lauser
690f26c223 units: rename "Rho" to "Density" 2014-02-11 12:45:43 +01:00
Andreas Lauser
ae73345763 units: rename "K" to "Permeability" 2014-02-11 12:45:43 +01:00
Andreas Lauser
ac60eed7d6 units: rename "1/Rs to "OilDissolutionFactor" and "Rs to "GasDissolutionFactor" 2014-02-11 12:45:43 +01:00
Andreas Lauser
bc4d467322 units replace: "mu" by "Viscosity" 2014-02-11 12:45:43 +01:00
Andreas Lauser
19d89d44cd units: Replace "P" by "Pressure" 2014-02-11 12:45:43 +01:00
Andreas Lauser
0129a382a8 units: Replace "L" by "Length" 2014-02-11 12:45:43 +01:00
Andreas Lauser
6a97d78cc6 units: replace "t" with "Time"
this makes things more explicit and more readable
2014-02-11 12:45:41 +01:00
Andreas Lauser
44f310bfbf units: substitute "FlowVolume" by "LiquidVolume" and "GasVolume"
because the units for them are different in the "Field" unit system.
2014-02-11 12:45:05 +01:00
Arne Morten Kvarving
4a9c18ac9f run tests through valgrind 2014-01-27 15:16:34 +01:00
Andreas Lauser
7a3755926b Units: add 'Timestep' dimension
the motivation for this is the 'TSTEP' eclipse keyword.

the reason why this dimension is not simply called 'Time' is that in
eclipse, different keywords might use different units, e.g. one
keyword could use seconds, another could use years while a third uses
days. As an added bonus, the used time units may be different for
different scales but identical in others (e.g., for one keyword times
might be specified in 'days' for the metric as well as for the
labscale, but in 'days' and 'hours' for another second keyword.)
2014-01-15 12:52:12 +01:00
Andreas Lauser
a88b47750e fix more (hopefully all) conversion factors
also, correct the dimension of the Rv item of the PVDG keyword which
is 1/Rs. Finally, the conversion factor for stock tank barrels to m^3
was off by a factor of 1000. (I suppose that liters instead of m^3
were assumed to be the SI unit in this case.)
2013-12-22 11:03:26 +01:00
Andreas Lauser
d1f224fd79 Units: fix thinko
milli means division by 1000 not multiplication...

this makes SPE1 converge nicely with opm-parser in autodiff!
2013-12-21 16:56:04 +01:00
Andreas Lauser
472b16b42a units: fix typo
Raito -> Ratio
2013-12-21 16:53:28 +01:00
Andreas Lauser
7096979a4b add a few missing dimensions
This makes getSIDouble*() work on PORO and PVTW.
2013-12-18 16:27:47 +01:00
Joakim Hove
6b29d4d0d2 Added some documentation to the ConversionFactors. 2013-12-18 12:52:29 +01:00
Joakim Hove
c1d7e87b71 Added dimension FlowVolume 2013-12-18 12:30:10 +01:00
Joakim Hove
800c4ff32e Added dimensions to TVDP* keyword family. 2013-12-15 22:38:57 +01:00
Joakim Hove
5f9f37e35e Added dimension to RSVD table; required new "quantity" Rs. 2013-12-15 22:31:54 +01:00
Joakim Hove
04ae0a1798 Final applyUnits commit ... 2013-12-14 10:31:07 +01:00
Joakim Hove
c4fbd24be6 Added getNewDimension for get-or-create semantics. 2013-12-14 10:29:59 +01:00
Joakim Hove
a485efbdd0 Added const to Dimension::equal(). 2013-12-14 10:20:57 +01:00
Joakim Hove
94f9cf55a4 Removed UnitSystemMap. 2013-12-14 10:05:24 +01:00
Joakim Hove
c86b220e40 Added Dimension::equal() method. 2013-12-12 12:12:45 +01:00
Joakim Hove
ff13036a58 Changed unit system to use more std::shared_ptr instead of instance variables. 2013-12-09 17:42:20 +01:00
Joakim Hove
5bc27e91f2 Added basic system for units - not yet hooked into the Parser items. 2013-12-08 19:26:30 +01:00