Commit Graph

245 Commits

Author SHA1 Message Date
Joakim Hove
fedc3387fd Default: Added dataset from opm-core with test 2014-09-03 10:37:02 +02:00
Joakim Hove
cec42ff8d9 Default: Using setInDeck() instead of relying on size == 1 2014-09-03 10:37:01 +02:00
Joakim Hove
61cdf7d402 Default: defaultApplied -> setInDeck()
The data values in a deck item can be in three different states, given
by the DeckValue enum in DeckItem.hpp. The three values are:

  SET_IN_DECK : The value has been set explictly in the deck.
  DEFAULT     : The value was not present in the input deck, but a default
                value has been supplied in the configuration and that value
                has been set.
  NOT_SET     : No value has been set for this item; it was not explicitly
                set in the deck and also not included in the configuration.

If you ask for DeckItem->value which is in state NOT_SET you will get an
exception. The method setInDeck() can be used to check if a value has
been set explicitly in the deck; the method defaultApplied() will check
if a default value has been applied.

Observe that the system for handling defaults is not really well suited
for multi valued data items, as it is only a scalar state variable. In
the case of multi valued data items both defaultApplied() and
setInDeck() might return true.
2014-09-03 10:37:01 +02:00
Joakim Hove
bf35919c6f Default: Changed default handling in ParserItem
This is the first of several large commits changing several aspects of
the handling of defaults. The overall main purpose of these changes is
to protect against using non sensible values in the case the values have
not been sensibly specified in the deck. The changes in this commit
include:

 1. The "default default" values to be used when an item without an
    explicit default are defaulted are removed completely.

 2. If a ParserItem is queried for a default value when no default has
    been assigned it will raise an exception.
2014-09-03 10:37:00 +02:00
Joakim Hove
de73c688e3 Removed debug output clutter 2014-09-03 10:37:00 +02:00
Joakim Hove
8f54c4e555 GroupTree::prinTree() takes std::ostream argument 2014-09-03 10:37:00 +02:00
Bård Skaflestad
422d37b138 Capture and provide completion direction
This is needed for clients to act intelligently in the presence of
horizontal completions (in the context of deviated wells).
2014-08-31 21:23:18 +02:00
Atgeirr Flø Rasmussen
52c7a4bc3f Remove section-using EclipseGrid constructors.
Also:
 - Simplify implementation (no templates).
 - Update tests.
2014-08-22 12:12:37 +02:00
Atgeirr Flø Rasmussen
6dfeadc229 Adapt tests to use new Well constructor, add test for defaulted ref depth. 2014-08-07 12:35:21 +02:00
Bård Skaflestad
1d34629cc2 Disable WCONHIST/GRAT non-existence test
Keyword WCONHIST always supports GRAT control mode, even when
defaulted.  The default value (zero) might not be very useful in a
simulation case but it's supported nonetheless.
2014-07-08 13:22:45 +02:00
Andreas Lauser
f754bd9c45 fix some screw-up with internal vs deck names
Parser::hasKeyword() was called with deckNames but looked up the map
for internal names. This patch renames the method to hasDeckName(),
renames Parser::getKeyword() to Parser::getKeywordFromDeckName() and
adapts/extends the tests.
2014-07-01 17:07:43 +02:00
Andreas Lauser
fe638c2fc8 separate the internal keyword names and the deck names more clearly
so far, these two concepts were partially mingled in Opm::Parser...
2014-06-29 14:32:06 +02:00
Joakim Hove
e732564fb4 Merge pull request #242 from andlaus/deck_keyword_lists
Implement deck keyword lists
2014-06-20 13:54:30 +02:00
Andreas Lauser
7a015fcb76 use deck keyword name list for the well output specifier keywords 2014-06-13 13:54:24 +02:00
Joakim Hove
a2d9d45da6 Added Parser test of deck with TOPS keyword. 2014-06-11 16:42:37 +02:00
Andreas Lauser
d820a4d435 change construction of ParserKeyword objects to the factory paradigm
this makes it more explicit what the object is supposed to represent.
2014-06-11 15:08:58 +02:00
Andreas Lauser
52c5d3fbcb make GCC 4.4 happy
there was a "typename" outside of a template, but because the
syntactic sugar is created by the Boost unit testing framework, it was
not clear wheter it was a template or not.

Also, some harmless warnings have been fixed. These only appeared
because a few variables have recently been converted from int to
size_t...
2014-06-03 22:51:03 +02:00
Andreas Lauser
7c53febf57 fix the ADD and EQUALS grid property modifiers 2014-06-03 22:42:23 +02:00
Joakim Hove
052fb7afad Fix stupid typo 2014-06-03 22:42:23 +02:00
Joakim Hove
3da0c228b9 Using size_t instead of int for EclipseGrid::getN? 2014-06-03 22:42:23 +02:00
Joakim Hove
73d88280a5 Renamed getXXXProperty -> getXXXGridProperty 2014-06-03 22:42:23 +02:00
Joakim Hove
5e56f16369 Added double properties for e.g. PERM and PORO to the EclipseState 2014-06-03 22:42:23 +02:00
Joakim Hove
6b29eb5176 Supporting the ADD and EQUALS keywords. 2014-06-03 22:42:23 +02:00
Joakim Hove
eb9e11849e Added support for MULTIPLY keyword. 2014-06-03 22:42:23 +02:00
Joakim Hove
6301fd1ad7 EclipseState now handles COPY keyword. 2014-06-03 22:42:23 +02:00
Joakim Hove
5c04cd4540 Basic BOX support when reading integer properties. 2014-06-03 22:42:23 +02:00
Andreas Lauser
d71cb1aa51 parser integration test: use std::istream as a template argument for std::shared_ptr
gcc 4.4 has problems with such implicit conversions...
2014-05-20 13:27:37 +02:00
Andreas Lauser
0d92cd43b0 export possibility to parse an arbitrary std::istream
this has the potential to reduce the memory requirements of the parser
for opm-benchmarks considerably and is quite easy to add since
internally all parsing happend on istreams anyway...

The parser integration test has been extended to test the new method
as well as `parseString()` which was omitted previously. (I wonder who
introduced this without changing the test. ;)
2014-05-20 12:12:12 +02:00
Kristian Flikka
82a38c1cc8 Merge pull request #208 from AtleH/wellnamewithwildcard
Added wildcard support in WCONINJE and WCONPROD
2014-05-16 12:28:39 +02:00
Atle Haugan
77ed32662c Enabled integration tests in ParseWellWithWildcards 2014-05-16 11:07:01 +02:00
Arne Morten Kvarving
a8f216175a fixed: remove misplaced semi-colons 2014-05-15 14:46:16 +02:00
Arne Morten Kvarving
3827ddca64 fixed: mark static symbols as such to quell warnings 2014-05-15 14:46:16 +02:00
Atle Haugan
344d02ad1c Add support for wildcard in WCONPROD and WCONINJE keywords. 2014-05-06 09:54:37 +02:00
Joakim Hove
af6f18b5aa Added methods to export the ZCORN, COORD and ACTNUM keywords from the EclipseGrid. 2014-04-22 00:20:03 +02:00
Joakim Hove
d5bf1726f2 Verified behaviour of defaults (i.e. *) for multivalued items. 2014-04-11 13:42:22 +02:00
Joakim Hove
f59fd25668 Added boolan flag scalar = true to DeckItem.
The purpose of this flag is to keep track of whether a keyword is
supposed to have only one element, i.e. scalar, or several. The
defaultApplied method only makes sense in the case of scalar items, this
method will now throw if it is called on a non-scalar item.
2014-04-11 13:42:22 +02:00
Joakim Hove
5becf79dd1 The ParserKeyword->parse() method will throw if the raw input argument is not finished.
Requires several changes to assure that the rawkeyword instances are
marked as finished before reacing the ParserKeyword->parse method.
2014-04-11 13:42:22 +02:00
Joakim Hove
a14dc265b5 Will temporarily convert double -> float before instantiating an ERT eclipsegrid. 2014-04-07 12:28:07 +02:00
Kristian Flikka
666ba3e607 Temporary revert and test removal - pending float/double cleanups 2014-04-04 15:39:29 +02:00
Joakim Hove
9c29c00c2b Added ability to create EclipseGrid from cornerpoint keywords. 2014-04-01 09:06:43 +02:00
Joakim Hove
5785d088ea Added functionality in Completion class to adjust I and J to wellHead value if they have been defaulted (i.e. have value -1). This is unfortunate because we loose quite a lot of const correctness. 2014-03-28 18:56:21 +01:00
Joakim Hove
f84ec0bb3f Made injection and production control variables into property variables. 2014-03-21 00:07:23 +01:00
Joakim Hove
011eb8a2c6 camelCased property attributes in the production and injection properties structures. 2014-03-20 23:27:18 +01:00
Atle Haugan
3daaf827c9 Renamed getXyzProperties to getXyzPropertiesCopy. Added new getXyzProperties which currently does not work... 2014-03-20 10:36:57 +01:00
Atle Haugan
af784c6734 Enabled the remaining tests. 2014-03-20 10:31:21 +01:00
Atle Haugan
87599c9841 Moved has/drop/addProductionControl to WellProductionProperties. The same for WellInjectionProperties. 2014-03-20 10:11:56 +01:00
Atle Haugan
fb5c83086a Moved (duplicated) m_isInPredictionMode to WellProductionProperties and WellInjectionProperties. 2014-03-19 10:51:13 +01:00
Atle Haugan
9c64af0b6b Moved BHPLimits and THPLimits to WellProductionProperties and WellInjectionProperties (duplicated). Several unit tests are still commented out - will fix. 2014-03-19 10:42:21 +01:00
Atle Haugan
3040697ccc Added WellInjectionProperties.InjectionControls. Adjusted som unit tests. Removed some dead code. 2014-03-19 10:40:48 +01:00
Atle Haugan
8aee879dc5 Added WellInjectionProperties, modified Well class to use it 2014-03-19 10:40:07 +01:00