Commit Graph

748 Commits

Author SHA1 Message Date
Bård Skaflestad
26cd7ab993 Move opm/core/props to opm/simulators/utils
The opm/core directory is no longer meaningful, and it contains only
components which might collectively be described as simulator
utilities.
2024-06-25 12:22:09 +02:00
Bård Skaflestad
a3a2b7a978 Make SummaryState Objects Aware of Undefined UDQ Value
This PR switches to calling the SummaryState constructor which is
aware of the value of undefined UDQs (OPM/opm-common#4052) directly.

While here, also sort headers, split some long lines, and prefer
initialisation lists to constructor body assignments.
2024-05-29 09:16:56 +02:00
Arne Morten Kvarving
d5d16eaee4 VFPHelpers: move some functions into a class with static members
and template Scalar type
2024-05-21 17:01:30 +02:00
Arne Morten Kvarving
3747981347 VFPProperties: template Scalar type 2024-05-21 17:01:30 +02:00
Arne Morten Kvarving
be57843296 WellState: template Scalar type 2024-04-17 11:12:40 +02:00
Arne Morten Kvarving
96a3a6d45a changed: move hdf5serializer to opm/simulators/utils/HDF5Serializer.hpp
does not interact with typetag system
2024-01-29 09:42:49 +01:00
Arne Morten Kvarving
e5c7d67372 fixed: these fields are ROOT_ONLY 2023-04-24 09:57:40 +02:00
Arne Morten Kvarving
adeb67ddbe fixed: initialize MPI before creating communicator 2023-04-24 09:57:26 +02:00
Bård Skaflestad
e861d72f78 Use Uniform Initialization
Avoids "most vexing parse" for non-MPI builds.
2023-02-16 17:32:04 +01:00
Arne Morten Kvarving
8c3400f562 added: parallel support to HDF5File / HDF5Serializer 2023-02-16 14:49:38 +01:00
Arne Morten Kvarving
6c9e887669 add simple inspection tool for .OPMRST files 2023-02-16 13:47:54 +01:00
Tor Harald Sandve
9364d4c54b Add option for wvfpexp item 2 plus minor fixes 2022-08-19 10:33:19 +02:00
Tor Harald Sandve
e875849497 Adapt test cases and vfpprint 2022-08-19 10:33:19 +02:00
Joakim Hove
6b92443cb4 Downstream filesystem reorganisation in opm-common 2022-01-02 14:33:34 +01:00
Arne Morten Kvarving
c76803b913 changed: make bhp template hidden and use explicit instantations
this to avoid includes in headers.
2021-05-31 11:42:29 +02:00
Arne Morten Kvarving
a4c5429341 fixed: include required headers where needed 2021-04-26 22:39:32 +02:00
Joakim Hove
74ca0d12e0 Use std::chrono::system_clock with 1/1000 second resolution 2021-02-25 23:50:25 +01:00
Joakim Hove
e4789d4eb7 Use std::reference_wrapper for VFP tables 2021-01-26 07:56:59 +01:00
Joakim Hove
17fcdfc87a Use ScheduleState to handle VFP propertes + simplifications 2021-01-14 19:22:34 +01:00
Atgeirr Flø Rasmussen
52c695937b Implement extended network model. 2020-10-15 10:54:03 +02:00
Atgeirr Flø Rasmussen
cb3165e681 Add a small utility to print a slice of a VFP table. 2020-05-20 11:27:28 +02:00
Arne Morten Kvarving
f027262ec4 remove files 2018-11-16 14:53:37 +01:00
Tor Harald Sandve
08c4a4857b Adapt to changes in schedule interface 2018-10-29 10:39:14 +01:00
Andreas Lauser
d7efb362a2 make the build of flow fully parallelizable
so far, the actual specializations of the simulator were compiled into
the `libopmsimulators` library and the build of the glue code
(`flow.cpp`) thus needed to be deferred until the library was fully
built. Since the compilation of the glue code requires a full property
hierarchy for handling command line parameters, this arrangement
significantly increases the build time for systems with a sufficient
number of parallel build processes. ("sufficient" here means 8 or more
threads, i.e., a quadcore system with hyperthreading is sufficient
provided that it has enough main memory.)

the new approach is not to include these objects in
`libopmsimulators`, but to directly deal with them in the `flow`
binary. this allows all of them and the glue code to be compiled in
parallel.

compilation time on my machine before this change:

```
> touch ../opm/autodiff/BlackoilModelEbos.hpp; time make -j32 flow 2> /dev/null
Scanning dependencies of target opmsimulators
[  2%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_gasoil.cpp.o
[  2%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_oilwater.cpp.o
[  2%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_blackoil.cpp.o
[  2%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_solvent.cpp.o
[  4%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_polymer.cpp.o
[  6%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_energy.cpp.o
[  6%] Building CXX object CMakeFiles/opmsimulators.dir/opm/simulators/flow_ebos_oilwater_polymer.cpp.o
[  6%] Linking CXX static library lib/libopmsimulators.a
[ 97%] Built target opmsimulators
Scanning dependencies of target flow
[100%] Building CXX object CMakeFiles/flow.dir/examples/flow.cpp.o
[100%] Linking CXX executable bin/flow
[100%] Built target flow

real    1m45.692s
user    8m47.195s
sys     0m11.533s
```

after:

```
> touch ../opm/autodiff/BlackoilModelEbos.hpp; time make -j32 flow 2> /dev/null
[ 91%] Built target opmsimulators
Scanning dependencies of target flow
[ 93%] Building CXX object CMakeFiles/flow.dir/flow/flow.cpp.o
[ 95%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_gasoil.cpp.o
[ 97%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_oilwater_polymer.cpp.o
[100%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_polymer.cpp.o
[100%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_oilwater.cpp.o
[100%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_solvent.cpp.o
[100%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_blackoil.cpp.o
[100%] Building CXX object CMakeFiles/flow.dir/flow/flow_ebos_energy.cpp.o
[100%] Linking CXX executable bin/flow
[100%] Built target flow

real    1m21.597s
user    8m49.476s
sys     0m10.973s
```

(this corresponds to a ~20% reduction of the time spend on waiting for
the compiler.)
2018-09-26 11:49:12 +02:00
Andreas Lauser
8e9b43fdce print usage message if the input case cannot be found 2018-08-17 11:36:21 +02:00
Andreas Lauser
f2b0630040 flow: minor parameter related fixes
- Change the brief description slightly
- Do not print anything anymore if there are no unused parameters
- Change the boiler plate text for printing the parameters to the
  PRT/DBG files

in part, this has been requested by [at]atgeirr.
2018-08-15 23:36:56 +02:00
Andreas Lauser
43ac2e36c6 remove the Flow prefixes of parameters only used by flow
this has been requested by [at]atgeirr.

Note: The FlowLinearSolverVerbosity, FlowNewtonMaxIterations and
FlowNewtonMinIterations parameters are still prefixed because they
clashes with parameters registered deeply within eWoms.
2018-08-15 23:34:32 +02:00
Andreas Lauser
9203b614e8 flow: customize the brief description printed in the usage message
The text can certainly be improved uppon.
2018-08-15 23:34:32 +02:00
Andreas Lauser
d94be85a9d flow: do not mention unused parameters in the help message
while they do no longer appear in the help message, in the code they
are still there and can be specified and used as normal.

also, this patch makes --print-parameters=1 and --print-properties=1
work.
2018-08-15 23:34:32 +02:00
Andreas Lauser
394790475f make it possible to disable the terminal output
the well model and (probably) the ECL output writing code look like
they cannot be gagged.
2018-08-15 23:34:32 +02:00
Andreas Lauser
b5cddef928 flow: switch it to use the eWoms parameter system
this has several advanges:

- a consistent and complete help message is now printed by passing the
  -h or --help command line parameters. most notably this allows to
  generically implement tab completion of parameters for bash
- the full list of runtime parameters can now be printed before the simulator
  has been run.
- all runtime parameters understood by ebos can be specified
- no hacks to marry the two parameter systems anymore
- command parameters now follow the standard unix convention, i.e.,
  `--param-name=value` instead of `param_name=value`

on the negative side, some parameters have been renamed and the syntax
has changed so calls to `flow` that specify parameters must adapted.
2018-08-15 23:34:32 +02:00
Atgeirr Flø Rasmussen
63e6e88f50
Merge pull request #1541 from akva2/avoid_deck_assignment
changed: avoid use of the assignment operator for the Deck class
2018-08-03 12:22:54 +02:00
Arne Morten Kvarving
3082281bc8 changed: avoid use of the assignment operator for the Deck class 2018-08-01 13:02:40 +02:00
Andreas Lauser
ac2bc410f3 adapt to the fluid system naming convention change in opm-material
note that almost the only thing which is affected is legacy code.
2018-07-27 12:54:02 +02:00
Tor Harald Sandve
ee88790dea Add a flow specialization for blackoil with energy conservation
The energy conservation is enabled by specifying either TEMP or
THERMAL in the deck. The deck also needs to contatin relevant fluid and rock
heat properties.

The blackoil + energy equations are solved fully implicit.
2018-04-30 13:45:18 +02:00
Kai Bao
635f6c7db2 trying to add the functionality to handle oil/water polymer 2018-02-28 08:39:38 +01:00
Atgeirr Flø Rasmussen
cf9b7c39b9 Adapt to moved opm-grid headers. 2018-02-10 08:33:33 +01:00
Andreas Lauser
58a1b7df1f adapt to the move of infrastructure from opm-common to opm-material 2018-02-07 13:32:52 +01:00
Arne Morten Kvarving
141186ad1d changed: opm/[core -> common]/utility/parameters 2018-01-30 16:33:45 +01:00
Arne Morten Kvarving
e9404486bb changed: opm/common/[->utility]/ResetLocale.hpp 2018-01-30 12:34:04 +01:00
Arne Morten Kvarving
c03a980199 Import the remaining code from opm-core 2018-01-17 15:18:56 +01:00
Atgeirr Flø Rasmussen
ea074831a9 Remove unneeded includes from compute_tof_from_files.cpp 2018-01-11 12:27:24 +01:00
Atgeirr Flø Rasmussen
8ad9c979f8 Remove old 2p simulator. 2018-01-08 17:22:50 +01:00
Atgeirr Flø Rasmussen
6481e32caa Make the differences between the incomp sims smaller.
For easier comparison and subsequent removal.
2018-01-08 17:19:17 +01:00
Atgeirr Flø Rasmussen
378a60699d Add setupSimpleDefaultLogging() to old two-phase sims.
Without this, the log output from some subsystems (such as
the parameters) will be lost as there is no log picking it up.
2018-01-08 15:10:06 +01:00
Andreas Lauser
5bf53148c0 replace #if HAVE_CONFIG_H by #ifdef HAVE_CONFIG_H
it seems like most build systems pass a -DHAVE_CONFIG_H flag to the
compiler which still causes `#if HAVE_CONFIG_H` to be false while it
clearly is supposed to be triggered.

That said, I do not really see a good reason why the inclusion of the
`config.h` file should be guarded in the first place: the file is
guaranteed to always available by proper build systems, and if it was
not included the build either breaks at the linking stage or -- at the
very least -- the runtime behavior of the resulting libraries will be
very awkward.
2017-12-11 11:33:52 +01:00
Atgeirr Flø Rasmussen
32c7d822ec Remove legacy fully implicit polymer simulator.
It has been replaced with the faster local-ad-based code, that is now
part of the integrated flow.cpp application.

We do not remove the old sequential implicit polymer simulators.
2017-11-24 11:41:34 +01:00
Tor Harald Sandve
d6ea5cc402 Cleaning the initialization code
-remove whitespaces
-fix documentation
2017-11-21 12:52:07 +01:00
Tor Harald Sandve
0ef82665f5 Use &ref not shared_pointer to MaterialLawManager 2017-11-21 12:08:10 +01:00
Tor Harald Sandve
51f48fcd13 Remove blackoilPhases and phaseUsage from the initialization code
Note 1: The initialization code now always consider 3 phases.
For 2-phase cases a trivial (0) state is returned.
Note 2: The initialization code does not compute a BlackoilStats,
but instead pass the initialization object with the initial state.
2017-11-21 12:08:10 +01:00