Commit Graph

1280 Commits

Author SHA1 Message Date
Edvin Brudevoll
b4e01187ff OPM-188: Fixup after review 2015-06-17 09:41:00 +02:00
Fredrik Gundersen
13f30e294a Added support for WPIMULT 2015-06-02 13:24:37 +02:00
Atgeirr Flø Rasmussen
a5da86a9ec Silence multiple warnings.
Also add more warnings to the disabling list of disable_warnings.h.
2015-05-28 14:05:09 +02:00
Markus Blatt
7f266458b5 Fix creation of initial value for computing the max (Fixes PR #805).
Bård spotet a bug after PR #805 was merged. Indead returning
-numeric_limits<type>::min() does not make sense for integral
values. This commit resorts to returning numeric_limits<type>::min().

Kudos to Bård for his attention.
2015-05-27 15:03:28 +02:00
Markus Blatt
a4e28119a3 Adds the possibility to compute a parallel inner product. 2015-05-27 11:07:15 +02:00
Markus Blatt
3fb7af1719 Do not use the masked value of the first container entry as initial value.
This behaviour does not work for computing a global inner product.
Therfore this commit introduces a new function to the functor that
returns an appropriate initial value.
2015-05-27 11:07:15 +02:00
Markus Blatt
fa279d6b16 Use correct type get the maximum value.
Previously we hardcoded float. Now we use the result_type of
the binary_function without any qualifiers. With any cv or reference
qualifiers std::numeric_limits uses a default implementation which
produces nonesense (e.g. numeric_limits<const int>::max() returns 0).
2015-05-27 11:07:15 +02:00
Markus Blatt
3aa869cfa0 Removes well debugging output. 2015-05-27 09:22:54 +02:00
Markus Blatt
63d8d5e781 [bugfix,parallel] Deactivate non-existing wells in manager.
Previously, we used the setStatus method to set wells that do not
exist on the local grid to SHUT. Or at least this is what I thought
that ```well.setStatus(timestep, SHUT)```. Unfortunately, my
assumption was wrong. This was revealed while testing a parallel run
with SPE9 that threw an expeption about "Elements must be added in
weakly increasing order" in Opm::DynamicState::add(int, T). Seems like
the method name is a bit misleading.

As it turns out the WellManager has its own complete list of active
wells (shut wells are simply left out). Therefore we can use this
behaviour to our advantage: With this commit we not only exclude shut
wells from the list, but also the ones that do not exist on the local
grid. We even get rid of an ugly const_cast.

Currently, I have running a parallel SPE9 test that has not yet
aborted.
2015-05-26 21:01:16 +02:00
Markus Blatt
ca3bcb2662 Use more accurate name for the size of the global components.
The new name is num_global_components, which actually is an upper bound
for the the number of global components (1 plus the maximum global index).
2015-05-19 19:58:05 +02:00
Markus Blatt
e2df1e981c Add spaces around binaries and explicit braces. 2015-05-19 19:56:37 +02:00
Markus Blatt
be7abe0706 Rename no_components to num_components. 2015-05-19 19:53:37 +02:00
Markus Blatt
202a0ab827 Update copyright information. 2015-05-19 16:20:57 +02:00
Markus Blatt
104c75d575 Allow to create the correct communication information if there are several unknowns.
In this case the parallel index set might represent N entries (this might be the number of
cells of grid). Nevertheless, there several (n) equations/unknowns attached to each index.
In this case we construct a larger index set representing N*n unknows, where each unknown
is attached to an index.

This change only affects parallel runs.
2015-05-19 16:18:14 +02:00
Atgeirr Flø Rasmussen
f24b9a1dc2 Merge pull request #800 from blattms/parallel-verbose-only-on-master
Allow to prevent printing to std::cout.
2015-05-13 14:42:37 +02:00
Markus Blatt
1a7ab6b81c Get rid of unclear continue; statement in favor of if-else 2015-05-12 15:30:20 +02:00
Markus Blatt
9514b8c89a Switched from default constructing to explicit construction with false. 2015-05-08 19:44:50 +02:00
Markus Blatt
2b4ebb94cc Adds possibility of having a well not stored on a grid partitioning.
In a parallel run each process only knows a part of the grid. Nevertheless
it does hold the complete well information. To resolve this the WellsManager
must be able to handle this case.

With this commit its constructor gets a flag indicating whether this is
a parallel run. If it is, then it does not throw if a well has cells that
are not present on the local part of the grid. Nevertheless it will check
that either all or none of the cells of a well are stored in the local part
of the grid.

Wells with no perforated cells on the local will still be present but set to SHUT.
2015-05-08 16:35:00 +02:00
Markus Blatt
802895acaf Allow to prevent SimulatorReport for printing to std::cout.
This commit adds a verbose flag to the constructor of
SimulatorReport to allow for deactivating any
output to std:cout. This is handy for parallel runs where we only
want to print statistics on one process.
2015-05-08 11:12:23 +02:00
Atgeirr Flø Rasmussen
928660ec0f New method SimulatorReport::reportFullyImplicit().
It does not make sense to report transport and pressure separately
for fully implicit solvers. It still makes sense to separate solver
from init and output though.
2015-04-21 10:48:02 +02:00
Markus Blatt
16d05fcc93 Correct documentation of why we use operator[] to initialize map.
This commit updates the source code comment about using operator[] to
initialize the unordered map. Thanks to Bard's persistence we found
out that the cause is not the construction of the key value of type
std::string from const char* but the mapped type being a (mutable)
char* (due to C?).

This completes the PR #784.
2015-04-14 09:36:47 +02:00
Markus Blatt
236718cff9 Deactivate PETSc's KSPCHEBYSHEV (not available in 3.2!) 2015-04-13 11:01:24 +02:00
Markus Blatt
b791d0743b Use operator[] to populize unordered_map with string as the key
g++-4.4 has problems converting const char* to char*
which it thinks is needed for constructing std::string.
Using operator[] circumvents this problem.

The compiler error fixed here was:
/usr/include/c++/4.4/bits/stl_pair.h: In constructor ‘std::pair<_T1, _T2>::pair(std::pair<_U1, _U2>&&) [with _U1 = const char*, _U2 = const char*, _T1 = const std::basic_string<char, std::char_traits<char>, std::allocator<char> >, _T2 = char*]’:
/home/mblatt/src/dune/opm/opm-core/opm/core/linalg/LinearSolverPetsc.cpp:40:   instantiated from here
/usr/include/c++/4.4/bits/stl_pair.h:107: error: invalid conversion from ‘const char*’ to ‘char*’
make[2]: *** [CMakeFiles/opmcore.dir/opm/core/linalg/LinearSolverPetsc.cpp.o] Fehler 1
2015-04-13 10:58:31 +02:00
Atgeirr Flø Rasmussen
d0820dcb3f Suppress sign-comparison warnings. 2015-03-27 15:38:21 +01:00
Atgeirr Flø Rasmussen
aa7dcf91d3 Merge pull request #765 from andlaus/implement_temperature_dependent_density
Implement temperature dependent density
2015-03-26 15:10:13 +01:00
Atgeirr Flø Rasmussen
2d534f0536 Fix property method calls.
Cell argument can not be null for BlackoilPropertiesFromDeck class.
2015-03-23 16:19:40 +01:00
Andreas Lauser
53aa151e1c add a wrapper for thermal gas PVT objects 2015-03-17 12:40:14 +01:00
Andreas Lauser
44e218ffca add a wrapper for thermal oil PVT objects 2015-03-17 12:40:09 +01:00
Andreas Lauser
1b961652b8 add a wrapper for thermal water PVT objects 2015-03-17 12:40:07 +01:00
Robert Kloefkorn
a77f681999 iostream --> ostream. 2015-03-04 14:48:50 +01:00
Robert Kloefkorn
e75551127f SimulatorReport: add total number of newton and linear iterations to report struct. 2015-03-04 14:01:13 +01:00
Atgeirr Flø Rasmussen
8a1b35d4f6 Fix unneeded-internal-declaration warning.
Again related to anonymous namespace function only being used
in template functions.
2015-03-02 10:28:55 +01:00
Markus Blatt
7539a80ed2 Put spaces around operators. 2015-02-20 14:30:06 +01:00
Markus Blatt
c1d61705c9 Rely on auto instead of querying the explicit type
via e.g. typename UgGridHelpers::Face2VerticesTraits<Grid>::Type
2015-02-20 14:29:05 +01:00
Markus Blatt
5b8442d985 Ported initStateEquil to using the GridHelpers.
Currently the keyword EQUIL is not supported by the fully
implicit blackoil simulator when using CpGrid. This
commit is a first step towards this as it makes the
implementation of initStateEquil generic.
2015-02-20 09:39:50 +01:00
Markus Blatt
a458aa7688 Prevents unsigned-signed-comparison warnings for container with signed size.
Well, you never know. There are containers that use a signed integer
for storing its size. This results in a warning about comparing signed with
unsigned integers. This commit prevents this by explicitly casting the size
to std::size_t.
2015-02-19 09:13:39 +01:00
Atgeirr Flø Rasmussen
529662ca1a Complete function argument cleanup. 2015-02-17 13:56:02 +01:00
Atgeirr Flø Rasmussen
a38bdaf4c3 Remove unused argument from several functions. 2015-02-17 10:28:11 +01:00
Atgeirr Flø Rasmussen
2f7a87aa4b Merge pull request #755 from blattms/istl-consistent-rhs
Makes right hand side passed to linear solver consistent.
2015-02-16 12:48:28 +01:00
Markus Blatt
a35b2f2b7c [fixup] Use the correct function.
This should have been in the las commit and should be added there before
merging.
2015-02-13 11:00:28 +01:00
Markus Blatt
50aba2c8f6 Makes right hand side passed to linear solver consistent.
Due to the size of the overlap layer and the discretization scheme
the rhs might not contain correct values for overlap cells. This
commit makes sure they are correct by an additional communication step.
2015-02-12 21:00:32 +01:00
Atgeirr Flø Rasmussen
28597d18ee Added computeWellPairs() function. 2015-02-11 14:03:47 +01:00
Markus Blatt
95f62e6e12 Improve the documentation a bit. 2015-02-05 15:43:48 +01:00
Markus Blatt
20f3a4151a Makes BlackoilPropertiesFromDeck copyable.
We need this for the parallel sim_fibo_ad_cp, where we will need
to point to the same parts in two copies without duplicating data.
2015-02-05 15:41:02 +01:00
Atgeirr Flø Rasmussen
fb983a44b1 Add default producer BHP control when not given in deck.
Default limit is 1 atm.
2015-02-04 10:30:15 +01:00
Atgeirr Flø Rasmussen
9cb9ec50b1 Rename directory opm/core/tof -> opm/core/flowdiagnostics. 2015-02-03 21:44:24 +01:00
Joakim Hove
f27f75b0b9 Use Value<double> for Connection Factor 2015-02-03 13:10:38 +01:00
Atgeirr Flø Rasmussen
4f327a5329 Merge pull request #738 from blattms/constify-parallelinformatio-workaround-eigen
Constify parallelinformation and workaround Eigen's weirdness
2015-01-30 20:35:33 +01:00
Markus Blatt
2caaca4160 Do not rely on begin()/end() of the containers to compute reductions.
One would think that such an assumption is safe in any case,
wouldn't one? But foen Eigen'S container this does not hold.
They do not provide STL compliant iterators, and access to them.
With this patch make the even stricter assumption that the containers
are random access and use operator[] instead of iterators.
2015-01-30 16:10:41 +01:00
Robert K
1f2a429a59 BlackoilState: added forgotten rv to equal method. 2015-01-29 11:07:24 +01:00