OPM / opm-common

Common components for OPM, in particular build system (cmake).
http://www.opm-project.org
GNU General Public License v3.0
33 stars 111 forks source link

Feature Request: Unhandled Keywords Message #440

Closed OPMUSER closed 3 years ago

OPMUSER commented 6 years ago

Currently the PARSER ignores keywords that are known to the PARSER but are unknown to FLOW and this creates numerous issues, as it is difficult to see if a particular option is implemented or active in FLOW, as in both cases the simulation proceeds and runs successfully or unsuccessfully, depending on your point of view.

It would be extremely useful if the PARSER issued a warning message after processing the deck stating that the keyword will be ignored by FLOW, similar to what is done for the inactive RPTRST keyword options in FLOW, that is:

Warning: Keyword 'BASIC' is unhandled for output to file.

Warning: Keyword 'PRES' is unhandled for output to file.

Warning: Keyword 'RS' is unhandled for output to file.

Warning: Keyword 'SGAS' is unhandled for output to file.

Warning: Keyword 'WELLS' is unhandled for output to file.

May be something like:

Warning: Keyword 'THERMAL' is ignored by Flow and will have no effect on the simulation.
Warning: Keyword 'THCONR' is ignored by Flow and will have no effect on the simulation.
Warning: Keyword 'SPECHEAT' is ignored by Flow and will have no effect on the simulation.
Warning: Keyword 'SPECROCK' is ignored by Flow and will have no effect on the simulation.

No suitable configuration found, valid are Twophase, polymer, solvent, or blackoil

I can help with identifying the status of the keywords that are active and inactive, if that would help.

joakim-hove commented 6 years ago

It would be extremely useful if the PARSER issued a warning message

The parser can not know what the simulator handles of keywords; however there is already such functionality in place in the simulator here - how well that is maintained I do not know.

atgeirr commented 6 years ago

The parser can not know what the simulator handles of keywords; however there is already such functionality in place in the simulator here - how well that is maintained I do not know.

We try to maintain that list in order to help users, but it is challenging to keep up-to-date. The thermal keywords I think should work now, as that feature was merged in May (i.e. after the 2018.04 release).

OPMUSER commented 6 years ago

Yes, but it is getting very complicated as I currently have 574 keywords in my data base and there are plenty of inconsistencies, which I can only resolve by running some of the test models, and even then it is sometimes difficult to resolve.

Part of the problem is that the keyword lists and test decks are not tied to a release as far as I can see. For example , the aquifer keywords are active for the 2018-10-pre but not for the 2018-04, why the test decks are built for the 2018-10-pre.

I have been creating my own test decks to account for the different releases, but we should really trap this in the PARSER some how.

So @joakim-hove is it possible to put a release flag on the keyword definitions, so that we catch all the keywords not implemented in FLOW? We don't need to be historically correct, we can just use 2018-04 for all existing keywords that work with FLOW. If this is not agreeable would a logical TRUE or FALSE work instead? Alternatively, is there automatic way to create the used keyword list in FLOW?

@atgeirr the THERMAL option is not active in 2018-04 as one gets this message if the thermal test case is run.

No suitable configuration found, valid are Twophase, polymer, solvent, or blackoil

The offending keyword is the THERMAL keyword, commenting this out the case runs but the TEMP array never changes (as expected).

OPMUSER commented 6 years ago

On second thoughts may be it should be FLOW that issues the warning message instead of the parser, is that possible?

OPMUSER commented 3 years ago

Code has been improved so close.