mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
handle the ROCK keywords using the new opm-parser utility class
This commit is contained in:
parent
e177b657f9
commit
5b77bcd4a0
@ -26,6 +26,7 @@
|
|||||||
#include <opm/core/utility/linearInterpolation.hpp>
|
#include <opm/core/utility/linearInterpolation.hpp>
|
||||||
|
|
||||||
#include <opm/parser/eclipse/Utility/RocktabTable.hpp>
|
#include <opm/parser/eclipse/Utility/RocktabTable.hpp>
|
||||||
|
#include <opm/parser/eclipse/Utility/RockTable.hpp>
|
||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
@ -94,13 +95,12 @@ namespace Opm
|
|||||||
poromult_ = rocktabTable.getPoreVolumeMultiplierColumn();
|
poromult_ = rocktabTable.getPoreVolumeMultiplierColumn();
|
||||||
transmult_ = rocktabTable.getTransmisibilityMultiplierColumn();
|
transmult_ = rocktabTable.getTransmisibilityMultiplierColumn();
|
||||||
} else if (newParserDeck->hasKeyword("ROCK")) {
|
} else if (newParserDeck->hasKeyword("ROCK")) {
|
||||||
Opm::DeckKeywordConstPtr rockKeyword = newParserDeck->getKeyword("ROCK");
|
Opm::RockTable rockTable(newParserDeck->getKeyword("ROCK"));
|
||||||
if (rockKeyword->size() != 1)
|
if (rockTable.numRows() != 1)
|
||||||
OPM_THROW(std::runtime_error, "Can only handle a single region in ROCK.");
|
OPM_THROW(std::runtime_error, "Can only handle a single region in ROCK.");
|
||||||
|
|
||||||
Opm::DeckRecordConstPtr rockRecord = rockKeyword->getRecord(0);
|
pref_ = rockTable.getPressureColumn()[0];
|
||||||
pref_ = rockRecord->getItem(0)->getSIDouble(0);
|
rock_comp_ = rockTable.getCompressibilityColumn()[0];
|
||||||
rock_comp_ = rockRecord->getItem(1)->getSIDouble(0);
|
|
||||||
} else {
|
} else {
|
||||||
std::cout << "**** warning: no rock compressibility data found in deck (ROCK or ROCKTAB)." << std::endl;
|
std::cout << "**** warning: no rock compressibility data found in deck (ROCK or ROCKTAB)." << std::endl;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user