Commit Graph

138 Commits

Author SHA1 Message Date
Andreas Lauser
dfbc24b35f flow: avoid wrangling around with dummy state objects
these objects are only used by flow_legacy, so not having to deal with
them anymore lets non-legacy flow avoid to jump through a lot of hoops
for the sake of having a common API.

this required a fork of the NonlinearSolver and AdaptiveTimeStepping
classes. this is not a problem because the original classes would get
pruned to look like the new ones once flow_legacy gets moved out of
the opm-simulators module.
2018-06-06 10:59:41 +02:00
Kai Bao
ed49fd1e88 adapting to the change related to VFP from the parser. 2018-04-11 09:22:52 +02:00
Atgeirr Flø Rasmussen
6e8adbbd7d Remove old "backup-restore" functionality.
Was no longer working and would require some maintenance to work again.
2017-11-20 14:31:13 +01:00
Joakim Hove
566f4fbb02 Use Schedule constructor. 2017-11-06 14:20:41 +01:00
Tor Harald Sandve
dc8f811cbe Remove WellStateFullyImplicitBlackoilDense
After the restructuring of of the well model, keeping an extra class for
the "Dense" model is not needed. The only thing still left in
WellStateFullyImplicitBlackoilDense was some solvent related stuff, this
PR moves this to WellStateFullyImplicitBlackoil and removes
WellStateFullyImplicitBlackoilDense.

In addition to a cleaning code this PR fixes missing solvent well output.
2017-10-11 10:54:59 +02:00
Tor Harald Sandve
ebc2f46967 Use pore volume weighted averaged hydrocarbon state in rateConverted.
- pressure, rs and rv is averaged using hydrocarbon pore volume weights.
- pvtRegions is used as input in the conversion factor calculations.
- the pvt cell of the first well cell is used as the pvt index.
(Completing a well in two different PVT regions sounds like a very bad
idea anyway)
- FIP region support is added to the rate converter also for the ebos
interface.
2017-10-03 10:25:56 +02:00
Markus Blatt
e0a7ced256 Only create step_timing.txt file if it gets written to.
If output=false is requested we created an empty file.
Now that file will only be created if output was requested
and it will only be opened on one rank in a parallel run.
2017-06-19 17:51:26 +02:00
Atgeirr Flø Rasmussen
2d0701c1e8 Include possibility for arbitrary summary data.
This adapts to the upstream API change in opm-data, and adds a
proof-of-concept dummy TCPU field.
2017-06-06 11:42:51 +02:00
Arne Morten Kvarving
3c0cb9e950 adjust for changed ParameterGroup namespacing 2017-04-28 15:36:25 +02:00
Atgeirr Flø Rasmussen
e7285ba230 Fix bug in two-phase case. 2017-04-18 15:23:27 +02:00
Kai Bao
8d96d835b3 removing the well potential from WellsManager constructor. 2017-04-11 16:51:16 +02:00
babrodtk
1fd36e9451 Fixed hysteresis input/output in flow_legacy 2017-04-07 14:36:36 +02:00
Atgeirr Flø Rasmussen
711e9bacb7 Allow restarting without OPMEXTRA field in restart file. 2017-03-16 13:34:24 +01:00
Tor Harald Sandve
19a16ceeca Set timesteps after events
The time step after an event can either be set using
timestep_in_days_after_event or using the TUNING keyword in the deck.
2017-03-09 08:54:44 +01:00
Atgeirr Flø Rasmussen
429baf082c Update to match revised extra data interface from opm-output. 2017-03-01 09:50:32 +01:00
Atgeirr Flø Rasmussen
378addd000 Update legacy sim to also read time step from restart. 2017-03-01 08:45:42 +01:00
Arne Morten Kvarving
a14f5392ee fixed: pass the fipnum data into the adaptive timer stepper
summary substep reports requires FIP data
2017-02-09 09:35:40 +01:00
Andreas Lauser
42ec0ca3c3 do not explicitly pass the permeability to the well model anymore
this information is already part of the EclipseState. The reason why
this should IMO be avoided is that this enforces an implementation
detail (ordering of the permeability matrices) of the simulator on the
well model. If this needs to be done for performance reasons, IMO it
would be smarter to pass an array of matrices instead of passing a raw
array of doubles.  I doubt that this is necessary, though: completing
the full Norne deck takes about 0.25 seconds longer on my machine,
that's substantially less than 0.1% of the total runtime.
2017-01-27 13:06:09 +01:00
Markus Blatt
fb55aedf4b Fix unit conversion of fip totals (pav) again.
This was (accidentally?) introduced in c880efae5b (labelled
"mostly eliminate Eigen in the FIP and VFP code"). As it is neither
present in flow_ebos nor in flow_mpi and was previously removed in
ccec17f8 (labelled "Fixed missing unit conversion for total fluid in place")
I assume that this is a bug.
2017-01-09 15:31:40 +01:00
Andreas Lauser
5fd83985a9 port the RateConverter to use the FluidSystem instead of the old fluid property API
this makes the RateConverter stuff independent of Eigen and it
simplifies some things because the the old PVT API is designed as a
"bulk-with-derivatives" API while the rate converter code used it in
"single shot" mode without derivatives.
2017-01-02 13:19:25 +01:00
Andreas Lauser
ef731672c9 remove the BlackoilPropsAdInterface abstraction layer
instead, directly use BlackoilPropsAdFromDeck.
2017-01-02 13:19:23 +01:00
Andreas Lauser
c880efae5b mostly eliminate Eigen in the FIP and VFP code
this code mostly used the Eigen vectors as arrays anyway, so let's use
`std::vector`.

also, this patch only "mostly eliminates" Eigen from from these parts
of the code because the source files of the VFP code still use
AutoDiffBlock; Unfortunately this cannot easily be changed because
`flow_legacy` depends on these methods. (`flow_ebos` does not use the
incriminating methods.)
2016-12-30 11:46:27 +01:00
babrodtk
841411037a Added throw if unsupported unit in deck for fluid in place 2016-12-16 13:40:20 +01:00
babrodtk
ccec17f81b Fixed missing unit conversion for total fluid in place 2016-12-16 13:15:22 +01:00
Jørgen Kvalsvik
28c36ef949 Mini deck is reference, not pointer 2016-12-01 16:18:04 +01:00
Andreas Lauser
8c5f92dbc4 extend and clean up the SimulatorReport 2016-11-25 21:19:57 +01:00
Andreas Lauser
b2f7b8c989 Merge remote-tracking branch 'origin/master' into frankenstein 2016-11-18 11:09:41 +01:00
Kai Bao
f62d40fc05 adding a pointer to the well_collection of WellsManger
might change to reference later. Using pointer now is trying to keep the
WellModel constant.
2016-11-16 13:22:52 +01:00
Andreas Lauser
6754bad00b Merge branch 'master' into frankenstein
* master:
  Update to shared_ptr-less parser interface.
2016-10-20 20:16:42 +02:00
Jørgen Kvalsvik
1c6a4b34da Update to shared_ptr-less parser interface. 2016-10-20 14:08:04 +02:00
Andreas Lauser
44d3d5b536 Merge branch 'master' into frankenstein
* master: (42 commits)
  Let only one rank write to step_timing.txt
  Do not refer users to issue tracker if multiple procs log.
  Remove unused variable.
  Use vector instead of VLA, also add missing includes.
  changed: bundle eigen3 in the original tarball for debian
  update redhat6 packaging
  Bugfix parallel computation of weighted pressure etc.
  Fixed uninitialized bug, and added logging/comment
  Removed superfluous std::move
  Refactoring
  Initial version of summary data
  Do not store collective communication in the wells object.
  Make sure that updateWellControls is called on each process.
  Make WellSwitchingLogger work with DUNE 2.3
  Schedule::getGroup returns reference, not pointer
  Removed warning in WellSwitchLogger::calculateMessageSize
  Correctly initialize MPI for multisegment wells test
  Changed some names in WellSwitchingLogger
  Use speaking name for bool in getCellData
  Whitespace and other formatting changes
  ...
2016-10-14 19:31:56 +02:00
Markus Blatt
a7cc4962e2 Let only one rank write to step_timing.txt
All ranks were still writing to step_timing.txt at the same time.
This made it unusable for parallel runs. With this commit only
one processes writes to this file.
2016-10-14 11:14:54 +02:00
Jørgen Kvalsvik
13a4364d55 Schedule::getGroup returns reference, not pointer 2016-10-05 15:32:24 +02:00
Markus Blatt
d4b818c948 Omit fluid in place messages on non-root process 2016-10-05 10:33:14 +02:00
Tor Harald Sandve
bef33ed00c Add an option for using values from TUNING in the timestepping.
if the paramter use_TUNING is set to true, the adaptive timestepper will
initalize with relevant values from the TUNING keywords.
2016-09-30 10:28:34 +02:00
Andreas Lauser
6722c67534 Merge remote-tracking branch 'origin/master' into frankenstein_merge_master_v2 2016-09-29 18:38:39 +02:00
Andreas Lauser
36b00ba570 Merge remote-tracking branch 'origin/master' into frankenstein_merge_master 2016-09-28 21:20:47 +02:00
Markus Blatt
0bdab6e579 Correct number of (nonlineat) iterations/linearizations in step_timing.txt
Previously, for all step zero was reported. With this commit
we set these numbers in the SimulatorReport and now they end
up correctly in step_timings.txt
2016-09-28 12:05:52 +02:00
Atgeirr Flø Rasmussen
06e41bdaca Merge pull request #819 from blattms/use-defunct-wells-from-loadbalancer-for-wellsmanager
Use names of defunct wells from loadbalancer for wellsmanager
2016-09-19 13:42:42 +02:00
Markus Blatt
2c70f05d6b Correctly parallelize computeFluidInPlace.
Its first implementation computed wrong results in parallel. With this commit
we noe have completely parallelized the computations and the results seem correct
for parallel runs with norne.
2016-09-15 15:43:08 +02:00
Andreas Lauser
4ecd6ca64a fix some serious screw-ups
almost all of them were caused by recent changes in the master
branch:

- there were methods added which depend on the types `V` and
`DataBlock`. these do not make much sense in the context of the
frankenstein simulator. Also, these types are defined globally for the
whole Opm namespace in `BlackoilModelBase_impl.hpp` (which should be
prosecuted as a fellony IMO)! Besides this, their names are useless;
'V' is the letter which comes after `U` in the alphabet and when it
comes to computers basically everything can be seen as a chunk of data
(i.e., a `DataBlock`).
- it seems like the new and shiny dense-AD based well model was never
compiled with assertations enabled, at least some asserts referenced
non-existing variables.
- the recent output-related API changes were pretty unfortunate
because they had the effect of tying the (sub-optimal, IMO) internal
structure of the model even closer to the output code: as far as I can
see, `rq` does only make sense if the model works *exactly* like
BlackoilModelBase and friends. (for flow_ebos, this could be
replicated, but first it would be another unnecessary conversion step
and second, most of the quantities in `rq` are of type `ADB` and much
of the "frankenstein" excercise is devoted to getting rid of these.) I
thus reverted back to an old version of the output code and created a
`frankenstein` branch in my personal `opm-output` github fork.
2016-09-13 23:58:59 +02:00
Markus Blatt
33edf62a78 Use set of names of defunct wells from load balancer for parallel WellManager.
Instead of the WellsManager guessing which wells are handled by other
processes we now use tha ouput of the load balancer to compute wells
that are handled by other processes.

With the previous approach it was not possible to calculate this information
correctly. Wells with only one completion next to the border of the
processes' partition were represented on multiple processes. In additition
wells that the eclipse schedule section defined with completions on non-active
cells in sequential runs were not at all calculated in parallel runs.

With the new approach the CpGrid::loaBalance routine returns the set names of
wells that are not handled by this process when setting up the simulation. This
information is then used throughout the simulation.
2016-09-13 10:58:26 +02:00
babrodtk
eb56ecab12 Refactored the logic of writing without cell properties 2016-09-07 14:59:16 +02:00
babrodtk
35bed24465 Initial version for outputting cell data 2016-09-07 14:55:53 +02:00
Atgeirr Flø Rasmussen
98ec930a25 Merge pull request #770 from blattms/call-writeInit-before-distributing-grid
Call writeInit with global grid and properties.
2016-09-07 11:29:19 +02:00
Liu Ming
4b88d4edd1 use PV weighted pressure when HCPV is zero. 2016-09-07 14:00:30 +08:00
Liu Ming
d5b4194a0e format fIP output for field units and check the phase is present or not. 2016-09-06 09:33:41 +08:00
Liu Ming
c5a490c75a fix typo. 2016-09-02 16:58:42 +08:00
Liu Ming
490dbbf133 correct the formulation for PAV calculations. 2016-09-02 16:53:39 +08:00
Atgeirr Flø Rasmussen
b5e986df5f Remove well state argument from computeFluidInPlace(). 2016-08-30 13:34:18 +02:00