Commit Graph

73 Commits

Author SHA1 Message Date
Pål Grønås Drange
172725aef8 Added JFUNC in TableManager and getJFuncColumn()
* Fully internalized JFUNC
* Added JFunc.cpp, throw on wrong FLAG/DIR in JFUNC kw
* added tests for JFUNC in TableManagerTests
* added protected member m_jfunc to SimpleTable
* Added getJFuncColumn to accompany getPcowColumn
* Throws if pressure or jfunc is accessed inappropriately
 * ... meaning if getPcowColumn is called when JFUNC is in deck, or
 * getJFuncColumn is called when JFUNC is not in deck
* added tests for throwing and for getJFuncColumn
* SimpleTable.getColumn("PCOW/PCOG") throws if JFUNC
* In the event that one tries to get "PCOW" or "PCOG" via getColumn
* ... this will throw if JFUNC is present in the deck.
* Added tests.
2016-12-28 19:20:31 +01:00
Jørgen Kvalsvik
9a336f62fb Understand the ROCK keyword 2016-12-20 12:52:43 +01:00
Jørgen Kvalsvik
5413b841ef Generalise 'flat table'; implement DENSITY, PVTW
Several tables are identical both in structure *and* parsing, i.e. the
code required to parse them only differ in output type and possibly
number of items to read.

FlatTable is a simple vector-based template that expands into this exact
parsing routine, based on a simple specification of the record.
2016-12-20 12:52:43 +01:00
Jørgen Kvalsvik
1d535124ec TableManager.getPvtwTable
Provide a richer interface to the PVTW table.
2016-12-06 15:18:19 +01:00
Joakim Hove
5ebddba40e Changes in Tabdims construction:
1. Removed Tabdims(int,int,int, ....) constructor and added
    Tabdims(Deck) constructor.

 2. Added Tabdims member to Runspec( ) object.

 3. Changed std_shared_ptr<Tabdims> to Tabdims member in TableManager.
2016-11-18 10:48:02 +01:00
Pål Grønås Drange
d8400f05bd Minor fixes unrelated to PR:
* Implemented missing method "name" in TableColumn.cpp
* add inline to method in RestartConfig to remove warning
* Whitespace changes
2016-11-09 12:29:08 +01:00
Jørgen Kvalsvik
21aaceaed9 Runspec object; move phases from TableManager
There has never really been a natural home for initial properties that
aren't InitConfig, meaning information such as phases in the deck and
other runspec information hasn't had a natural home.

This patch introduces the Runspec object on EclipseState for phase
information and other similar properties that are interesting and static
for when setting up parameters etc. for simulation, that aren't all that
interesting once simulation starts.

An additional benefit is a leaner implementation for the phase enum and
some stricter semantics via enum classes.
2016-11-01 16:41:19 +01:00
Liu Ming
8d59f6d3d8 remove unused method. 2016-06-06 13:48:47 +02:00
Liu Ming
9a23157b6a Write the VFR testing information into Debug file. 2016-06-06 12:26:26 +02:00
Liu Ming
17918ac5b3 use proper function to log filename, line number, msg. 2016-04-19 15:06:03 +08:00
Liu Ming
63e54c0157 use message container instead of OpmLog. 2016-04-14 11:03:53 +08:00
Liu Ming
f28dd65142 add MessageContainer object. 2016-04-14 09:39:28 +08:00
Atgeirr Flø Rasmussen
c74a441a3b Remove const with no effect on value return. 2016-04-13 12:56:05 +02:00
Pål Grønås Drange
3680dfcb97 Substantial edits to Eclipse3DProperties and ptr's
* moved region-property from EclipseState to Eclipse3DProperties
* moved initGridopts from EclipseState to Eclipse3DProperties
* made several Eclipse3DProperties methods private
* removed obsolete tests
* replaced log with throw internally in private method---is domain_error
* removed typedef in SatFuncPropertyInitializers
* postprocessors take raw pointers, not shared_ptr---these will be phased out
* fixed return reference instead of copy several places
** gridProperties<T> in Eclipse3DProperties are now references, not shared_ptr
** Eclipse3DProperties takes const Deck&, not shared_ptr
** EclipseGrid and Section are references
2016-04-12 14:42:34 +02:00
Pål Grønås Drange
e48b64c41d Substantial edits to Eclipse3DProperties
* Removed all references to state, need to fix initPORV
* Made TransMult return raw pointer const GridProperty over shared pointer.
* Moved getDirectionProperty and hasDirectionProperty out of API
** Removed tests as these methods are no longer public
* Moved grid properties stuff to new class
* Removed use of deck in SatfuncInitializers, moved to TableManager
* Removed shared_ptr for several members of EclipseState and 3DProperties
* Moved region-property from EclipseState to Eclipse3DProperties
* Moved initGridopts from EclipseState to Eclipse3DProperties
* Made several Eclipse3DProperties methods private
* Postprocessors take raw pointers, not shared_ptr---these will be phased out
* Fixed return reference instead of copy several places
** GridProperties<T> in Eclipse3DProperties are now references, not shared_ptr
** Eclipse3DProperties takes const Deck&, not shared_ptr
* Removed obsolete tests
2016-04-12 14:42:18 +02:00
Jørgen Kvalsvik
135f405e93 InitUnitSystem private; constness managed by .get
The const_cast in Deck::get*UnitSystem are potentially undefined
behaviour under a series of (plausible) conditions, and are deprecated
in favour of mutable members. Removes initUnitSystem from the public
interface, as the initialisation is handled on the first getUnitSystem
anyway, cleaning up the Deck interface slightly.

Adds proper constness to the use of unit systems that don't actually
modify the internal state in any way.
2016-04-06 15:09:32 +02:00
chflo
f2ed1ba7ea Moved OpmLog from opm-parser to opm-common 2016-03-21 22:07:49 +01:00
Tor Harald Sandve
3991bf6e51 Add new keyword TLPMIXPA
The TLPMIXPA keyword can be used for giving pressure depended Todd-
Longstaff parameters. The implementation follows the description of
PMISC.
2016-03-08 15:14:21 +01:00
Jørgen Kvalsvik
f0ae5db131 opm-parser adoption of Deck automatic ownership
Since the Deck* family of classes have changed their interfaces to no
longer use shared_ptr, a lot of code broke. This patch fixes all
problems in tests, other signatures and accesses to now use the new Deck
interfaces.
2016-02-18 13:27:24 +01:00
Jørgen Kvalsvik
04900a4bb6 ParserKeywords.hpp -> ParserKeywordsX.hpp
To reduce compiler stress and be more explicit w.r.t. dependencies, all
files now includes only the keywords they need, instead of the
collection of all files.
2016-01-21 09:25:58 +01:00
Jørgen Kvalsvik
c85a032240 Splits tables' implementations into .cpp file
Most tables are trivial extensions of SimpleTable, but had their
implementation in headers. This required them to include more headers
than we want to expose and makes them harder to maintain and verify.
Instead, all these SimpleTable derivatives are now implemented in
Tables.cpp, only declaring their interfaces in their respective .hpp
files. Clients won't notice the difference.

rebase into tables
2016-01-21 09:23:07 +01:00
Jørgen Kvalsvik
f404828d63 Cleans up headers to improve build preformance
This is an effort to improve build performance.  Several includes
scattered across the project are either unused or partially used (i.e.
just used to import a type name, not depending on the actual contents of
the header file).

Replaces a lot of these includes with forward declarations.
2016-01-21 09:22:06 +01:00
Joakim Hove
6cff4d5aae Changed PVTO / PVTG implementation 2016-01-08 14:04:29 +01:00
Tor Harald Sandve
3ba7382146 Add missing methods in TableManager.cpp
Add missing methods for MSFN, PMISC, MISC, SGCWMIS and SORWMIS
2015-12-03 15:18:56 +01:00
Tor Harald Sandve
ddcba13dfe Add support for MSFN 2015-12-01 12:19:43 +01:00
Tor Harald Sandve
9badf045a9 Add support for PMISC 2015-12-01 12:19:43 +01:00
Tor Harald Sandve
e97c6461e1 Add support for MISC 2015-12-01 12:19:43 +01:00
Tor Harald Sandve
5c35b8edeb Add support for SGCWMIS 2015-12-01 12:19:43 +01:00
Tor Harald Sandve
d151bfc83a Add support for SORWMIS 2015-12-01 12:19:42 +01:00
Liu Ming
68a9366d8d Add keyword SGWFN. 2015-10-12 10:56:21 +08:00
Atgeirr Flø Rasmussen
6cf9d01cc3 Avoid shadowing the 'record' variable. 2015-10-07 09:43:51 +02:00
Joakim Hove
b3972de557 Immplemented PLYSHLOG table with TableContainer.
The PLYSHLOG table specification is based on alternating header and data
records, this is not supported by th parser - and the thing will throw
if more than table is specified.
2015-10-04 20:03:54 +02:00
Joakim Hove
ea86b51b8d TableContainer for PLYMAX and PLYROCK. 2015-10-04 20:03:53 +02:00
Joakim Hove
40fa456603 TableContainer for PLYADS,PLYDHFL and PLYVISC. 2015-10-04 20:03:51 +02:00
Joakim Hove
821bc9bc9e Implemented ROCKTAB with TableContainer. 2015-10-04 20:03:48 +02:00
Joakim Hove
4857f2299f Using TableContainer for RTEMPVD. 2015-10-03 17:32:12 +02:00
Joakim Hove
d1451bc4e3 Using TableContainer for gas viscosity. 2015-10-03 17:32:12 +02:00
Joakim Hove
1542957e49 Using TableContainer for oil and water viscosity. 2015-10-03 17:32:11 +02:00
Joakim Hove
eb69d85ee4 TableContainer: PVDO, PVDS and PVDG. 2015-10-03 17:32:11 +02:00
Joakim Hove
d9c5811e90 TableContainer: ENKRVD, ENPTVD, IMKRVD and IMPTVD. 2015-10-03 17:32:10 +02:00
Joakim Hove
295385cab7 TableContainer for RSVD and RVVD tables. 2015-10-03 17:32:10 +02:00
Joakim Hove
9c9e9f48fd TableContainer for SGFN, SWFN and SSFN tables. 2015-10-03 17:32:09 +02:00
Joakim Hove
836ea66a49 TableContainer for SWOF,SGOF,SLGOF,SOF2 ans SOF3. 2015-10-03 17:32:08 +02:00
Joakim Hove
f77e1af9f0 Added TableContainers for the simplest tables. 2015-10-03 17:32:08 +02:00
Joakim Hove
d1bb9bd2f0 Added Eqldims and Regdims wrapper classes 2015-10-03 17:32:07 +02:00
Joakim Hove
d377345f95 Added map of tablecontainers to TableManager. 2015-10-03 17:32:07 +02:00
Joakim Hove
2e1533c945 Added new default based Tabdims constructor. 2015-10-03 17:32:06 +02:00
Joakim Hove
dfb2ff6744 All simple table inits called from common method. 2015-10-03 17:32:06 +02:00
Joakim Hove
5cc263fe2a Fixed bug in PLYMAX table. 2015-09-17 22:28:12 +02:00
Joakim Hove
a44733405d Fixed special initialisation of PLYROCK tables. 2015-09-17 18:47:21 +02:00