Commit Graph

3002 Commits

Author SHA1 Message Date
Andreas Lauser
f7910af7d7 flow_ebos: do not use (smart) pointers for opm-parser objects anymore
this patch also includes code to make FlowMainEbos more autonomous
(i.e. it does not derive from FlowMainBase anymore). this allows more
flexibility how and what stuff gets created.
2016-12-05 20:11:43 +01:00
Kai Bao
8148105ae3 Revert "changing polymer production concentration to be the grid block concnetration." 2016-12-05 15:05:56 +01:00
Tor Harald Sandve
e614c42818 Avoid hard-coded appelyard parameter in flow_ebos
Start using the parameters in the parameter file instead of the hard-
coded ones.
Unify the restriction of the drs and drv in black-oil and black-oil-
solvent updateState
2016-12-05 13:44:33 +01:00
Tor Harald Sandve
6e03b9706f Apply Appleyard fixes to solven model
Tested on SPE5 and Model2 + co2
2016-12-05 13:44:33 +01:00
Tor Harald Sandve
294ca31fc8 Fixes in the Appelyard in updateState and updateWellState
1) changes dp_max_rel default to 0.2
2) introduces a dbhp_max_rel paramter to restrict the bhp update in the
updateWellState() (instead of using the dp_max_rel) Default is set to
1.0
3) Restrict rs and rv between 0,and the satruation value
4) Set rs and rv to zero for the water only cases
5) Guard against zero rs and rv when calcuating the maximum allowed rs
and rv change.

Tested on norne, model 2 and model 2.2

Number of problems for the different models with and without this fix
Case
this PR master
Norne
10
45
Model 2
21
78
Model 2.2
200
248
2016-12-05 13:44:33 +01:00
Kai Bao
81a73650de polymer production concentration to be the grid block concnetration.
To be more consistent with the injection well.
2016-12-05 12:52:21 +01:00
Andreas Lauser
676af2b00b AdaptiveTimeStepping: fix stupid (but harmless) mistake in the sub-step info message
that was a copy-and-pasto: newton iterations = linearizations - 1
2016-12-03 15:04:32 +01:00
Robert Kloefkorn
42ab4d133f [bugfix] add defunct_well_names to BlackoilModelEbos. 2016-12-02 11:13:06 +01:00
Robert Kloefkorn
2eca5d71e6 [bugfix] fix ownerMask for parallel FIP code. 2016-12-01 22:25:46 +01:00
Andreas Lauser
e6acf888cc flow_ebos: tell the ebos in ourselves to not handle SWATINIT
because the flow part also wants to do this. (and it is quite a bit
more stubborn!)
2016-12-01 16:50:31 +01:00
Robert Kloefkorn
c5ca9649d7 [bugfix] Make initialization work in parallel for flow_ebos. 2016-12-01 16:50:31 +01:00
Robert Kloefkorn
1c2a2c417c [bugfix] make flow_ebos work when no wells are present. 2016-12-01 16:50:28 +01:00
Andreas Lauser
5ebed2f500 flow_ebos: only instantiate the grid once
it now uses the grid object which gets created by ebos for everything
which should make the parallelization efforts easier. I also tried to
cut back the use of the legacy property objects (i.e., for the fluid,
geologic and rock properties), but this effort ran aground because of
the initialization and output code. (also, if those two were fixed,
there would probably be issues with the Newton update.)

I ran Norne with this and there did not seem to be any notable
performance regressions or benefits.
2016-12-01 16:50:06 +01:00
Jørgen Kvalsvik
28c36ef949 Mini deck is reference, not pointer 2016-12-01 16:18:04 +01:00
Atgeirr Flø Rasmussen
2abb2c8144 Merge pull request #914 from GitPaean/test_iterative_wellcontrol
[WIP] making the updateWellControls an iterative process for StandardWells
2016-12-01 10:52:03 +01:00
Atgeirr Flø Rasmussen
63b0498843 Merge pull request #951 from andlaus/improve_SimulatorReport
extend and clean up the SimulatorReport
2016-11-30 19:34:11 +01:00
Andreas Lauser
6720eb7a75 clean up and extend the SimulationReport class
it now also accounts for assembly, linear solve, update and output
write time and indicates if an operation has converged.
2016-11-30 11:27:49 +01:00
Andreas Lauser
69240fe435 StandardWellsDense: fix two assertations
the compiler suggested braces around the conditions, and by look of
it, it was right: these asserts most likely want express that only the
threephase case or the twophase case without gas are handled...
2016-11-29 14:29:51 +01:00
Andreas Lauser
fdb01cb9a3 flow_ebos: fix build with debugging flags
once more, it seems like we became a victim of the combinatorial
explosion of possibilities.
2016-11-29 11:36:30 +01:00
Andreas Lauser
5bb23cfe9d Merge pull request #946 from andlaus/implement_two-phase_blackoil
Implement two phase blackoil
2016-11-28 15:16:19 +01:00
Andreas Lauser
8c5f92dbc4 extend and clean up the SimulatorReport 2016-11-25 21:19:57 +01:00
Kai Bao
69d5ec94c9 adding localWellsActive() checking for two MSW functions
updatePerfPhaseRatesAndPressures() and addWellFluxEq()
2016-11-25 13:45:38 +01:00
Arne Morten Kvarving
312491f349 Merge pull request #2 from andlaus/flow_ebos-fix-kr-units
also fix the units of the relperm in SimulatorFullyImplicitBlackoilOutputEbos
2016-11-24 18:19:33 +01:00
Andreas Lauser
12bed02b1e also fix the units of the relperm in SimulatorFullyImplicitBlackoilOutputEbos 2016-11-24 18:13:49 +01:00
Arne Morten Kvarving
f813d829e4 fixed: [WAT|OIL|GAS)KR are ratios and thus dimensionless 2016-11-24 17:43:06 +01:00
Kai Bao
e57da11fbd making the updateWellControls an iterative process for StandardWells
Seperating the updateWellStateWithTarget from updateWellControls, will
update the controls when any of the control constraints gets broken.

The reason is that the updated well control can still break some of
other the contstaints. We need to choose one control to make sure all the
constraints are honored.
2016-11-24 11:27:59 +01:00
Atgeirr Flø Rasmussen
bda6a42299 Merge pull request #939 from blattms/fix-ebos-warnings
Fixes unsused parameter warnings for ebos stuff
2016-11-22 15:33:34 +01:00
Tor Harald Sandve
d23270c98f Fix the 2p simulator
Only tested for oil+water case
The blockmatrix and vectors are hardcoded to be 3
and a trivial equation is used for the Gas phase.
2016-11-22 15:01:48 +01:00
Andreas Lauser
5e0804b39f some twophase fixes for flow_ebos
this changes the conversion of the results to hopefully make it work
with twophase simulations. Note that flow_ebos still does not work
because there is a crash in the well model that I don't understand
(and also, I've disabled an assertation in the well model plus I'm not
completely sure if the conversion code need to do something about the
primary variables in the twophase case).
2016-11-22 15:01:48 +01:00
Joakim Hove
21b1b2318d Merge pull request #943 from jokva/write-init-and-egrid-rename
Rename to EclipseWriter.writeInitial
2016-11-22 12:59:51 +01:00
Atgeirr Flø Rasmussen
621a72bb25 Merge pull request #941 from blattms/read-write-perforation-rates-and-pressure
Read write perforation rates, pressure, phase reates, and control of wells.
2016-11-22 11:16:19 +01:00
Jørgen Kvalsvik
ffc3de0f6e Rename to EclipseWriter.writeInitial 2016-11-22 09:52:41 +01:00
Markus Blatt
0179a17704 Gather well controll, too. 2016-11-21 21:20:47 +01:00
Markus Blatt
f601ac4013 Gather perforation phase rates, too.
To do this we needed to switch from WellState to WellStateFullyImplicitBlackoil
as only the latter stores this information.
2016-11-21 21:19:51 +01:00
Markus Blatt
88e118d76a Consistently use WellStateFullyImplicitBlackoil in output
Otherwise we cannot write out all the data in a parallel run.
2016-11-21 21:19:51 +01:00
Markus Blatt
a6c323c48b Read and write rate and pressure per well perforation when gathering. 2016-11-21 21:19:39 +01:00
Robert Kloefkorn
feea8c1753 Introduce parameter for time step in days when single precision should be used
in the linear solvers. Also, a parameter was introduced to toggle the use of AMG.
2016-11-21 17:18:24 +01:00
Markus Blatt
a16bce8785 Fixes unsused parameter warnings for ebos stuff 2016-11-21 15:23:12 +01:00
Atgeirr Flø Rasmussen
720d341c76 Merge pull request #938 from dr-robertk/PR/cleanup-paralleldebugoutput
ParallelDebugOutput: remove unused variable and tabbing.
2016-11-21 12:20:32 +01:00
Robert Kloefkorn
a2b2e6dd27 [cleanup][ParallelDebugOutput] remove unused variable and tabbing. 2016-11-21 11:26:08 +01:00
Atgeirr Flø Rasmussen
95cc415fba Merge pull request #937 from akva2/quell_warnings
Quell some compiler warnings
2016-11-21 11:11:46 +01:00
Arne Morten Kvarving
caac9d7843 fixed: put variable under ifdef to avoid unused warnings without mpi 2016-11-21 10:21:11 +01:00
Arne Morten Kvarving
b0aae037f6 quell unused variable warning 2016-11-21 10:20:24 +01:00
Atgeirr Flø Rasmussen
e223c03647 Merge pull request #800 from OPM/frankenstein
Frankenstein V2
2016-11-18 15:49:31 +01:00
Robert Kloefkorn
5fce54fd44 [bugfix][ISTLSolver] make code compile with AMG when different matrix operator
is used.
2016-11-18 12:47:54 +01:00
Robert Kloefkorn
59f40ba14e [cleanup][WellModelMatrixAdapter] use only one implementation of the matrix
adapter to avoid confusion.
2016-11-18 12:47:54 +01:00
Robert Kloefkorn
a0da20378c [bugfix][WellModelMatrixAdapter] fix applyscaleadd method. 2016-11-18 12:47:54 +01:00
Robert Kloefkorn
439a084508 [bugfix][BlockoilModelEbos] fix invalidation of intensive quantities after
linear solver failure.
2016-11-18 12:47:54 +01:00
Atgeirr Flø Rasmussen
54ad92ff40 Merge pull request #931 from atgeirr/fix-deck-error
Do not assign to dereferenced null pointers.
2016-11-18 11:59:40 +01:00
Andreas Lauser
2f208962f0 revert AutoDiffMatrix back to the master version
that class is not used by flow_ebos anymore...
2016-11-18 11:24:35 +01:00
Andreas Lauser
b2f7b8c989 Merge remote-tracking branch 'origin/master' into frankenstein 2016-11-18 11:09:41 +01:00
Atgeirr Flø Rasmussen
1bd58cf471 Merge pull request #862 from GitPaean/group_control
group control_updating well production targets within a group
2016-11-17 23:27:00 +01:00
Andreas Lauser
a3fecc8edc flow_ebos: fix the build
this broke after the latest master merge (again, the reason were API
changes. this time they did not lead to merge conflicts.)

I've verified that flow_ebos works with Norne and that the performance
did not regress.
2016-11-17 16:34:53 +01:00
Andreas Lauser
0d00579f7d Merge remote-tracking branch 'origin/master' into frankenstein_merge_master_v12
* origin/master:
  Start with a clean globalCellData_ for each data gathering.
  Added assertion that entry was added to globalCellData_ for pack/unpack
  Use data::Solution to gather cell data including user requested data.
  Warn about broken parallel matlab output.
  a few warning fixing.
  Removed second implementation of matlab output.
  Fix spelling in warning about unhandled parallel ouput.
2016-11-17 16:08:21 +01:00
Kai Bao
0ab04b04cd checking whethter group control is active
When applying group control related functions.
2016-11-17 16:01:59 +01:00
Andreas Lauser
b8a0bb6aea Merge pull request #926 from totto82/frankenstein_revertChanges
Revert som changes in default values
2016-11-17 13:46:37 +01:00
Atgeirr Flø Rasmussen
71bd419c03 Do not assign to dereferenced null pointers. 2016-11-17 13:18:02 +01:00
Atgeirr Flø Rasmussen
cf84626da0 Merge pull request #929 from blattms/flexible-parallel-ouput
Allow output for user requested data in parallel runs.
2016-11-17 11:40:09 +01:00
Markus Blatt
80bbabc0b6 Start with a clean globalCellData_ for each data gathering.
Otherwise there might entries from the last call that should
either not be there this time or might have a different size.
2016-11-16 21:21:51 +01:00
Markus Blatt
098bd8f9fc Added assertion that entry was added to globalCellData_ for pack/unpack 2016-11-16 21:20:14 +01:00
Bård Skaflestad
8cc64402be Merge pull request #927 from GitPaean/warning_fixing
a few warning fixing.
2016-11-16 18:48:51 +01:00
Markus Blatt
00440ab344 Use data::Solution to gather cell data including user requested data.
Previously only the cell data registered with SimulationDataContainer
war gathered during parallel output. User requested data was neglected
and a warning was issued. With this commit we intialize the local view
of data::Solution on all processes with the data registered in
SimulationDataContainer and add cell data requested by the user. This is
then gathered on the IO process, and used for the output layer. To
rudimentarily support matlab we also create a global view of
SimulationDataContainer for it.
2016-11-16 17:11:24 +01:00
Markus Blatt
5ad813b4bd Warn about broken parallel matlab output.
If this is a parallel run and matlab output is requested then
we issue a warning that it is broken because of wrong velocities.
2016-11-16 17:09:53 +01:00
Tor Harald Sandve
b66bb27a65 Revert som changes in default values
Make sure flow in Frankenstein and flow in master uses the same default
values
2016-11-16 15:09:54 +01:00
Kai Bao
d38a6eb459 adapting the change of the function findWellNode(). 2016-11-16 14:28:35 +01:00
Kai Bao
d06acaa4b5 adapting to the change in opm-core 2016-11-16 14:06:20 +01:00
Kai Bao
f85da3768e cleaning up and updating MultisegmentWells 2016-11-16 13:27:30 +01:00
Kai Bao
6bbc726bc2 checking and outputing the residuals for the well equations.
Before, the tolerance for the norm of the residual of the well control
equations was 1bar, which makes no sense for rate control.
For some rate controls, we are not able to update the well state with
the target rates, we have to enforce the convergence throught the
residual checking.
2016-11-16 13:26:54 +01:00
Kai Bao
002439c5b1 WIP in testing new group update strtegy.
results with min_iter=2 works okay, while not min_iter=1.

It means the iteration stop at the wrong situation.
2016-11-16 13:26:28 +01:00
Kai Bao
753da2dd36 putting the VREP control update after updateWellControls
which makes it almost should be put inside updateWellControls function.

it does not change the result.
2016-11-16 13:25:35 +01:00
Kai Bao
a5aaf9b802 easier way to update whether the well under group control
potentially can be more consistent way.
It does not change the result.
2016-11-16 13:25:35 +01:00
Kai Bao
8a1e1e010a using findWellNode() to avoid dynamic_casting
form WellGroupInterface* to WellNode*.
2016-11-16 13:25:35 +01:00
Kai Bao
337693cc65 removing the wrongly wrapped std::vector
adding more comments for future reference.
2016-11-16 13:25:35 +01:00
Kai Bao
9150c217f2 making the VREP enforcement into a small method.
in BlackoilModelBase.
2016-11-16 13:25:35 +01:00
Kai Bao
9a95697fde updating some comments. 2016-11-16 13:25:35 +01:00
Kai Bao
75e0ff0018 Trying always to give a valid control when initing WellState.
Without the fix, when we specify GRUP control for WCONINJE, the control
mode will be initialized to be -1.
2016-11-16 13:25:35 +01:00
Kai Bao
8474ff2895 fixing all the simulators that call solveWellEq.
Not all the group control functionalities working for allt the
simulators. Some need to be fixed later.
2016-11-16 13:25:35 +01:00
Kai Bao
0f3e34bb25 cleaning up some comments. 2016-11-16 13:25:35 +01:00
Kai Bao
cb897b07d0 Adding VREP injection support.
As part of it, adding a function to calculate reservoir voidage rate.
2016-11-16 13:25:35 +01:00
Kai Bao
a15513e546 adding a rate converter to the BlackoilModelBase 2016-11-16 13:25:35 +01:00
Kai Bao
e65d24aa16 removing outdated log ouptut code about control switching
Which results from the rebasing process.
2016-11-16 13:25:35 +01:00
Kai Bao
e13cf827b5 applying the efficiency factors to the multi-segment wells. 2016-11-16 13:25:35 +01:00
Kai Bao
623ef3850e applying the efficiency factor to flow 2016-11-16 13:25:35 +01:00
Kai Bao
aca587b76b calculate efficiency factor in StandardWells
which will be used to scale the perforation flow rate when entering the
matrial balance equations.
2016-11-16 13:25:35 +01:00
Kai Bao
ac67a10316 removing one updateWellControls from solveWellEq
not recalling why adding it in the first place.

And correcting some comments for clarification.
2016-11-16 13:25:35 +01:00
Kai Bao
e049508eec adding the group control related part to MultisegmentWells
while looks like the well potentials part may not work with multisegment
wells.

Will check later.
2016-11-16 13:25:35 +01:00
Kai Bao
0df52603d7 fixing the interface of wellModel constructors
to make all the simulators compile.
2016-11-16 13:25:35 +01:00
Kai Bao
26b16c1050 cleaning up the output and adding more comments. 2016-11-16 13:25:11 +01:00
Kai Bao
d992161b82 output cleaning up and add more comment. 2016-11-16 13:24:39 +01:00
Kai Bao
e323f15d2f putting more things in the prototyping test. 2016-11-16 13:23:55 +01:00
Kai Bao
e0dd9bfabd keeping putting group control in. 2016-11-16 13:22:52 +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
Kai Bao
1c34af4dea a few warning fixing. 2016-11-16 13:17:35 +01:00
Markus Blatt
b91f747a3e Removed second implementation of matlab output.
There is already a generic one with the Grid implementation
being the template parameter in the header file. The other
implementation using UnstructuredGrid does exactly the same.
Therefore we remove it with this commit.
2016-11-16 12:16:40 +01:00
Atgeirr Flø Rasmussen
fd4d57e68c Merge pull request #923 from blattms/fix-spelling-for-unhandled-ouput
Fix spelling in warning about unhandled parallel ouput.
2016-11-15 20:50:40 +01:00
Andreas Lauser
89f2636b2e Merge pull request #921 from totto82/frankenstein_output_fixes
Frankenstein output fixes
2016-11-15 13:05:27 +01:00
Tor Harald Sandve
b04f79b15f Fix 2phase celldata output 2016-11-15 12:48:25 +01:00
Andreas Lauser
fc4dfea185 Merge remote-tracking branch 'origin/master' into frankenstein
* origin/master:
  checking the residual for the well control equations.
2016-11-15 12:27:04 +01:00
Tor Harald Sandve
f8bf7c392c Fix some temporary fallouts in the outputwriter 2016-11-15 12:23:46 +01:00
Markus Blatt
55362ecdc2 Fix spelling in warning about unhandled parallel ouput. 2016-11-15 12:08:58 +01:00
Andreas Lauser
e1178455a2 flow_ebos: fix a memory error in the fluid in place code
as usual for such errors, this was found using valgrind.
2016-11-14 19:49:33 +01:00
Andreas Lauser
293f7ca1c7 Merge pull request #916 from totto82/frankenstein_fix_appleyard2
Improvments in convergence for flow_ebos
2016-11-14 15:02:00 +01:00
Andreas Lauser
e84de929cf flow_ebos: alter the startup message
... to make apparent from the output which simulator was used.
2016-11-14 14:18:11 +01:00
Andreas Lauser
4271da8d84 flow_ebos: fix the build
mainly, the "linsolver_" attribute is called "istlSolver_" in the
BlackoilModelEbos class. Also, this problem possibly only occured if
MPI was enabled...
2016-11-14 13:36:01 +01:00
Tor Harald Sandve
739c0906ef Improvments in convergence for flow_ebos
- restrict pressure changes. Set default to 1.0 (this also effects flow)
- change default number of linear iterations to 150
- tell stabilized newton the residual occilates even if it occilates in
only one phase (this also effects flow)
- avoid problems realated to division on small numbers

Tested on SPE9, norne and Model 2 with significant improvments.
2016-11-14 13:26:38 +01:00
Atgeirr Flø Rasmussen
ae9cd62a5c Merge pull request #906 from GitPaean/test_residual_checking
checking the residual for the well control equations.
2016-11-14 10:44:44 +01:00
Tor Harald Sandve
36ce159411 Calculation the original FIP at the beginning 2016-11-14 10:16:57 +01:00
Tor Harald Sandve
5a917a4828 Output FIP in flow_ebos 2016-11-14 09:34:40 +01:00
Andreas Lauser
d989c1e2fc Merge remote-tracking branch 'origin/master' into frankenstein
* origin/master:
  Do not throw for unrecognized file when merging log files.
  Do not populate cellData but issue a warning in parallel.
  Removed ternary operator in inline initialization.
  Correctly mark transfer of ownership for ouptut writer
  Indent nested #if
  Remove Solution.sdc assignment
  Cater variable name change in BCRSMatrix of DUNE 2.5
  Fix using local active cells for writing eclipse files in parallel.
  add restart test for SPE1CASE2_ACTNUM
  rename the 'flow' binary to 'flow_legacy' and set a symbolic link
  Added ctest for restart files
2016-11-11 18:29:46 +01:00
Atgeirr Flø Rasmussen
129db89dc0 Merge pull request #900 from blattms/fix-parallel-eclipse-writing
Fix using local active cells for writing eclipse files in parallel.
2016-11-11 15:28:46 +01:00
Atgeirr Flø Rasmussen
38abf56d5e Merge pull request #905 from blattms/do-not-throw-for-unrecognized-parallel-file
Do not throw for unrecognized file when merging log files.
2016-11-11 15:23:42 +01:00
Andreas Lauser
5c67d79c72 adapt to the rename of "applications/ebos" to "ebos" inside eWoms 2016-11-11 15:05:13 +01:00
Andreas Lauser
42e55ee38b fix the build if MPI is not available
I'm not really sure if the fix is semantically correct (Dune
communicators are strange beasts if you're new to them), but at least
this patch fixes the build without MPI and the resulting flow_ebos
binary seems to work fine.
2016-11-11 14:25:19 +01:00
Kai Bao
ce8498c4d7 checking the residual for the well control equations. 2016-11-11 13:26:22 +01:00
Markus Blatt
1882d3315a Do not throw for unrecognized file when merging log files.
The regex we are using might also consider a file named bla.2.blub.
In that case it is not nice to throw an exception. Instead we print
a message to std::cerr.
2016-11-11 12:00:49 +01:00
Markus Blatt
8632c71cef Do not populate cellData but issue a warning in parallel.
This will lead to some data missing in the parallel runs
but will allow successful runs.
2016-11-10 17:46:49 +01:00
Markus Blatt
747c93e898 Removed ternary operator in inline initialization.
This made the code rather hard to read. Now we do the initialization
in the constructor body if needed.
2016-11-10 13:28:21 +01:00
Markus Blatt
3eba3353d0 Correctly mark transfer of ownership for ouptut writer 2016-11-10 13:04:30 +01:00
Atgeirr Flø Rasmussen
736585e85b Merge pull request #902 from blattms/support-dune-2.5
Cater for variable name change in BCRSMatrix of DUNE 2.5
2016-11-09 12:19:41 +01:00
Markus Blatt
85c0bbcc10 Indent nested #if 2016-11-09 10:08:56 +00:00
Jørgen Kvalsvik
2bdc46c557 Remove Solution.sdc assignment 2016-11-09 10:46:26 +01:00
Markus Blatt
3f7f81ef03 Cater variable name change in BCRSMatrix of DUNE 2.5
One of the variables now has a trailing underline.
2016-11-08 18:59:08 +00:00
Markus Blatt
077dc02481 Fix using local active cells for writing eclipse files in parallel.
Previously, the eclipseGrid used by EclipseWriter was constructed from
the one in the EclipseState with the current CpGrid. Unfortunately the
latter was the distributed version resembling only the local part that
the processor works on. Therefore the information about the active cells
was wrong when writing results (which raised an exception in the writer).

With this commit we construct the EclipseWriter before distributing the grid
and use this writer later on in the OutputWriter.
2016-11-07 19:35:53 +01:00
Andreas Lauser
414dda420a Merge remote-tracking branch 'origin/master' into frankenstein_merge_master_v9
* origin/master:
  dune.module: change version to 2017.04-pre
  FlowMain: make sure to always print exception messages to the terminal
2016-11-04 13:56:44 +01:00
Andreas Lauser
0858de32b7 Merge pull request #888 from dr-robertk/PR/wip-frankenstone
[WIP] some cleanup and features for Frankenstone.
2016-11-03 19:02:40 +01:00
Andreas Lauser
edbfdb5ef3 FlowMain: make sure to always print exception messages to the terminal
this patch only uses OpmLog if it is set up properly, else it uses
std::cout. the reason why this is needed is that there's a
chicken-and-egg problem: exceptions which are thrown before the
logging system has been initialized -- most prominently while parsing
the deck -- cause the simulator to silently abort without any user
notification which can be very confusing. On the other hand,
initializing the logging system requires a fully initialized
EclipseState object, i.e. currently to initialze the logging system
the deck must be parsed and in order to print the exceptions thrown
while parsing the deck one needs the logging system.

v2: only prevent using the logging system if has not been set
up. thanks to [at]blattms for the suggestion!
2016-11-03 17:22:51 +01:00
Andreas Lauser
bc4c43a56a Merge branch 'master' into frankenstein
* master:
  changed: drop usage of python based comparison script in spe integration tests
  changed: drop usage of python based comparison script in polymer integration test
  Remove weak enum Opm::Phase
2016-11-03 13:33:45 +01:00
Robert Kloefkorn
90247a02b2 [feature] make convergenceReduction work in parallel (needs testing). 2016-11-02 17:44:06 +01:00
Robert Kloefkorn
4ff23191eb [feature] make flow and flow_ebos use the same linear solver setup. 2016-11-02 16:41:11 +01:00
Robert Kloefkorn
01bb7ee4d7 [cleanup] only print first letter of phaseName in iteration output. 2016-11-02 11:25:43 +01:00
Robert Kloefkorn
11238b1997 [cleanup] Use class variables instead of creating new vectors inside the apply
method of StandardWellsDense.
2016-11-02 10:43:55 +01:00
Atgeirr Flø Rasmussen
59b7d8c8fc Merge pull request #883 from jokva/relax-opm-phase-enum-constexpr
Remove weak enum Opm::Phase; replace with constexpr
2016-11-01 14:52:22 +01:00
Tor Harald Sandve
77d5c8fa38 Remove Eigen from StandardWellsDense 2016-11-01 14:27:05 +01:00
Tor Harald Sandve
f1a9b1f21b Remove unused file and #includes
removes StandardWellsDense_impl.hpp
2016-11-01 13:44:38 +01:00
Tor Harald Sandve
362968c315 New WellStateFullyImplicitBlackoilDense
The WellStateFullyImplicitBlackoil is reverted to master and all
extentions moved to WellStateFullyImplicitBlackoilDense
2016-11-01 13:44:38 +01:00
Andreas Lauser
a773fd4c85 use accessor methods to access the value and derivatives of Evaluation objects 2016-11-01 13:30:41 +01:00
Andreas Lauser
88e2641f1a Merge remote-tracking branch 'origin/master' into frankenstein_merge_master_v5
* origin/master:
  use accessor methods to access the value and derivatives of Evaluation objects
2016-11-01 13:27:15 +01:00
Jørgen Kvalsvik
6488cfcfe5 Remove weak enum Opm::Phase
This weak enum is really just an alias for four other constants which in
turn alias another enum. Since they're mostly used for indexing they're
relaxed to constexpr ints.
2016-11-01 12:59:26 +01:00
Robert Kloefkorn
134bf914dc Merge branch 'frankenstein' into PR/remove-Eigen-from-BMEbos 2016-10-28 16:24:55 +02:00
Andreas Lauser
4be9e95f0f fix the build
wellsToState() now seems to require a phase usage argument...
2016-10-28 09:27:57 +02:00
Andreas Lauser
ddecdc9dbe Merge remote-tracking branch 'origin/master' into frankenstein_merge_master_v7
* origin/master:
  Bugfix: use correct object in sequential model.
  Bugfix: properly handle two-phase cases.
  Bugfix: pass both normal and extra data to output.
  Update well data output integration.
  Adapt to API change in opm-parser.
  Ensure logging only on first rank.
  Add isIORank_ member to avoid repeated calls.
  Rename isRankZero() -> isIORank() for consistency.
  Ensure only first-rank logging.
  Add isRankZero() utility.
  Bugfix: missing return.
  do not set limits for prt log and set correct value for Note.
  correct function call order and add whitespace.
  supprot MESSAGES default vaule.
  wellToState reads new opm-output data exchange
  Write control to data::Wells. Missing ability to restore.
  Avoid using buggy wellstate api
  Stop report early if there are no wells
  Update to interface change in opm-output
2016-10-28 09:22:38 +02:00
Tor Harald Sandve
a083f46d44 Make it possible to set initial timestep
Default is kept at -1.0. I.e. this PR does not change the current
behaviour.
2016-10-28 09:03:29 +02:00
Andreas Lauser
73d7a3ca10 use accessor methods to access the value and derivatives of Evaluation objects 2016-10-27 17:29:29 +02:00
Atgeirr Flø Rasmussen
e762844cdf Bugfix: use correct object in sequential model.
Discovered as a side effect of two-phase fix.
2016-10-27 13:20:10 +02:00
Atgeirr Flø Rasmussen
1fe610ef5a Bugfix: properly handle two-phase cases.
Errors were found in FIP handling and output.
2016-10-27 11:02:04 +02:00
Atgeirr Flø Rasmussen
7da420869b Bugfix: pass both normal and extra data to output.
Normal meaning SWAT, PRESSURE, RS etc.
Extra meaning KR, VISC etc. as asked for in RPTRST.
2016-10-25 15:27:59 +02:00
Atgeirr Flø Rasmussen
17a9f28fb8 Update well data output integration.
Includes the following changes:
 - update to match API change in opm-output (vector not map for data::Wells::completions),
 - restore WellStateFullyImplicitBlackoil::perfPhaseRates() from output,
 - restore WellStateFullyImplicitBlackoil::currentControls() from output.

Remaining non-restored well-related data are:
 - well potentials,
 - the dynamic list of econ-limited completions.
2016-10-25 10:53:40 +02:00
Atgeirr Flø Rasmussen
77abb6de1c Merge pull request #840 from jokva/output-data-wells-sans-vectors
WIP: Output data wells sans vectors
2016-10-21 15:00:39 +02:00
Robert Kloefkorn
31724030c9 Merge branch 'frankenstein' into PR/remove-Eigen-from-BMEbos 2016-10-21 14:13:58 +02:00
Robert Kloefkorn
c8374a4b95 [cleanup] Remove Eigen from BlackoilModelEbos. 2016-10-21 13:26:48 +02:00
Atgeirr Flø Rasmussen
1edbc9f238 Merge pull request #866 from atgeirr/convergence-failure-not-error
Convergence failure classification, fix for parallel logging
2016-10-21 12:49:07 +02:00
Atgeirr Flø Rasmussen
2d15c1ffec Adapt to API change in opm-parser. 2016-10-21 11:21:02 +02:00
Atgeirr Flø Rasmussen
3a6353a455 Merge pull request #820 from qilicun/support-MESSAGES
support MESSAGES keyword.
2016-10-21 11:04:39 +02:00
Atgeirr Flø Rasmussen
d527b6862a Ensure logging only on first rank. 2016-10-20 22:47:30 +02:00
Atgeirr Flø Rasmussen
a2c9e64291 Add isIORank_ member to avoid repeated calls. 2016-10-20 22:40:24 +02:00
Atgeirr Flø Rasmussen
e4731fc14d Rename isRankZero() -> isIORank() for consistency. 2016-10-20 22:40:24 +02:00
Atgeirr Flø Rasmussen
8ed3418245 Ensure only first-rank logging.
Also classify convergence troubles or out-of-bounds residuals as
"problem" not "error".
2016-10-20 22:40:24 +02:00
Atgeirr Flø Rasmussen
5559fbd233 Add isRankZero() utility. 2016-10-20 22:40:24 +02:00
Atgeirr Flø Rasmussen
9e1ba49554 Bugfix: missing return. 2016-10-20 22:40:24 +02:00
Atgeirr Flø Rasmussen
08b7db6c7f Classify convergence failure as a "problem" not "error". 2016-10-20 22:36:20 +02:00
Atgeirr Flø Rasmussen
83b3d8a149 Ensure logging only on first rank. 2016-10-20 22:36:20 +02: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
Liu Ming
7c51158ec4 do not set limits for prt log and set correct value for Note. 2016-10-20 21:00:51 +08:00
Jørgen Kvalsvik
1c6a4b34da Update to shared_ptr-less parser interface. 2016-10-20 14:08:04 +02:00
Liu Ming
0695555a77 correct function call order and add whitespace. 2016-10-20 16:27:46 +08:00
Jørgen Kvalsvik
ad6b77cc15 Update to shared_ptr-less parser interface. 2016-10-20 10:14:41 +02:00
Liu Ming
164f74c93c supprot MESSAGES default vaule. 2016-10-20 15:54:02 +08:00
Andreas Lauser
7cfe8322e2 Merge branch 'master' into frankenstein
* master:
  adapt to the removal of the unit system of opm-core
2016-10-19 13:30:44 +02:00
Andreas Lauser
b824c30e0c Merge pull request #870 from totto82/frankenstein_cache_reuse_fix
Frankenstein: InvalidateCache when restaring the timestep
2016-10-19 13:16:25 +02:00
Andreas Lauser
5007d99c0d flow_ebos: re-eanable the 'tempV.maxCoff()' convergence check for the well model
the 'tempV' object currently only contains garbagee but the condition
is needed and will thus be fixed in a different PR.

thanks goes to @totto82 for the clarifications.
2016-10-19 12:28:07 +02:00
Tor Harald Sandve
89fcbe3e60 InvalidateCache when restaring the timestep
Keep track of whether it is a restart or not and invalidate the
intensive quantitiesCache in ebos when restarting the timestep due to
convergence issues.
2016-10-19 12:08:49 +02:00
Jørgen Kvalsvik
26f1a69903 wellToState reads new opm-output data exchange 2016-10-19 12:06:46 +02:00
Jørgen Kvalsvik
545f55bd3b Write control to data::Wells. Missing ability to restore. 2016-10-19 12:06:46 +02:00
Jørgen Kvalsvik
df4e163796 Avoid using buggy wellstate api 2016-10-19 12:06:46 +02:00
Jørgen Kvalsvik
dfb7f8ff63 Stop report early if there are no wells 2016-10-19 12:06:46 +02:00
Jørgen Kvalsvik
6ba21fd4c0 Update to interface change in opm-output 2016-10-19 12:06:43 +02:00
Atgeirr Flø Rasmussen
93ffb318cd Merge pull request #855 from andlaus/opm-parser_units
adapt to the removal of the unit system of opm-core
2016-10-18 15:25:42 +02:00
Andreas Lauser
45f11d8820 StandardWellsDense: fix some valgrind complaints
note that I don't know if these changes are semantically correct (I
doubt it), but this patch fixes the valgrind complaints I saw for
SPE9_CP and on Norne.

Also, this makes the timing of flow_ebos for SPE9 determinisic between
runs: without this, I got some random time steps fail in a given run
and in the next run a completely different set of timesteps
failed. Since this was on the same same machine, without any
recompiles and no changes to the deck or any other input parameters, I
initially attributed the behavior to cosmic rays ;)

@totto82: could you have a thorough look on this?
2016-10-17 18:56:38 +02:00
Andreas Lauser
b8e5a6e12d flow_ebos: support for geology changes during the simulation
the actual work is done in the EclProblem. Removing the stuff here is
just necessary in order not to apply the modifier deck twice...
2016-10-17 17:06:20 +02:00
Andreas Lauser
2dc69b4551 *arg* I accidentally merged some local changes with the last PR... 2016-10-17 16:32:28 +02:00
Andreas Lauser
1c1e0c18b7 flow_ebos: fix the build
once again, the culprit was an API change in opm-output. I suppose
this means that the frankenstein branch should be merged soon after
the release in order to avoid to continue breaking the flow_ebos build
twice a week.
2016-10-17 16:24:49 +02:00
Andreas Lauser
6a093c3e24 Merge remote-tracking branch 'origin/master' into frankenstein 2016-10-17 14:33:34 +02:00
Joakim Hove
f90e608bfc Merge pull request #851 from joakim-hove/use-celldata-container
data::Solution for opm-output communication.
2016-10-17 11:46:45 +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
Atgeirr Flø Rasmussen
79de15e21d Merge pull request #861 from blattms/fix-parallel-step_timings.txt-writing
Let only one rank write to step_timing.txt
2016-10-14 13:42:33 +02:00
Atgeirr Flø Rasmussen
d007cd8e6e Merge pull request #859 from atgeirr/compile-fixes
Compile fixes
2016-10-14 13:31:12 +02:00
Atgeirr Flø Rasmussen
262d2e1172 Merge pull request #860 from blattms/skip-hint-to-issue-tracker
Do not refer users to issue tracker if multiple procs log.
2016-10-14 13:30:00 +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
Markus Blatt
a424516639 Do not refer users to issue tracker if multiple procs log.
This is currently still happening due to the implementation of
OPM_THROW whenever the linear solver does not converge. This
happens quite often and we might not want to get overwhelmed by
the issue tracker.
2016-10-14 10:47:16 +02:00
Atgeirr Flø Rasmussen
580e76cf05 Remove unused variable. 2016-10-13 17:09:43 +02:00
Atgeirr Flø Rasmussen
654a24b625 Use vector instead of VLA, also add missing includes. 2016-10-13 17:08:52 +02:00
Andreas Lauser
144318b567 consolidate the unit system to opm-parser
since the unit code within opm-parser is now a drop-in replacement,
this simplifies things and make them less error-prone.

unfortunately, this requires quite a few PRs. (most are pretty
trivial, though.)
2016-10-10 17:50:26 +02:00
Andreas Lauser
d76bf11902 adapt to the removal of the unit system of opm-core
the one which is in opm-parser is now a drop-in replacement.
2016-10-10 17:00:09 +02:00
Joakim Hove
39be053aef Using data::Solution for transfer of 3D data. 2016-10-10 10:52:51 +02:00
Atgeirr Flø Rasmussen
7e0cb99bad Merge pull request #839 from babrodtk/summary_data
Summary data output
2016-10-10 10:00:17 +02:00
babrodtk
68f1cff930 Bugfix parallel computation of weighted pressure etc. 2016-10-07 15:11:59 +02:00
babrodtk
8ff349253c Fixed uninitialized bug, and added logging/comment 2016-10-07 15:11:59 +02:00
babrodtk
4f696809b3 Removed superfluous std::move 2016-10-07 15:11:59 +02:00
babrodtk
2d8e612d01 Refactoring 2016-10-07 15:11:59 +02:00
babrodtk
b774982878 Initial version of summary data 2016-10-07 15:06:53 +02:00