Commit Graph
151 Commits
Author SHA1 Message Date
Atgeirr Flø Rasmussen 7dbb9b50e1 Work in progress on adding wells. 2013-05-15 09:23:15 +02:00
Atgeirr Flø Rasmussen 90a4984dea Fix multiple symbol issue. 2013-05-15 09:22:45 +02:00
Atgeirr Flø Rasmussen 959f7cbcac Added superset() functions.
The reverse of subset(), superset() takes a sparse representation of a vector
and makes a full representation of it.

Also added a little documentation.
2013-05-15 08:50:22 +02:00
Atgeirr Flø Rasmussen 38259f43bf Added size() member for ease of use.
This makes it easier to write for example templated code
acting on either AD vectors or non-ad vectors.
2013-05-15 08:48:36 +02:00
Atgeirr Flø Rasmussen 51a5bdd039 Updated for helper class name change (UpwindSelector). 2013-05-15 08:35:38 +02:00
Atgeirr Flø Rasmussen e95bafb0a2 Merge remote-tracking branch 'bska/master' 2013-05-15 08:32:43 +02:00
Atgeirr Flø Rasmussen 3c2031cd2e Moved spdiag out of an anonymous namespace.
It is a function meant to be called by clients, not an implementation detail.
2013-05-15 07:42:00 +02:00
Bård Skaflestad 0225e6c9ee Ignore autosave files from Vim. 2013-05-14 17:45:20 +02:00
Bård Skaflestad b85c0dce88 Add test cases for density and water viscosity.
Currently, ViscosityAD fails due to missing pressure derivatives in
the viscosity primitives.
2013-05-14 17:29:49 +02:00
Bård Skaflestad cebb6fd5fa Add required fluid densities 2013-05-14 15:46:00 +02:00
Bård Skaflestad eb1836c977 Disable 'param' output for all test cases. 2013-05-14 15:45:31 +02:00
Bård Skaflestad 6583aca34c Default to using tables as-is. 2013-05-14 15:41:45 +02:00
Bård Skaflestad ac5350a598 All "parameter" values must be strings. 2013-05-14 15:41:34 +02:00
Bård Skaflestad 667cae6d84 Expose 'param' and 'deck' in TestFixture. 2013-05-14 15:31:41 +02:00
Bård Skaflestad a1ca968991 Merge remote-tracking branch 'atgeirr/master' 2013-05-14 15:19:13 +02:00
Atgeirr Flø Rasmussen e8baa4a967 Merge remote-tracking branch 'bska/master' 2013-05-14 15:12:18 +02:00
Atgeirr Flø Rasmussen 995e8d7a91 Initial untested implementation of relperm() methods. 2013-05-14 15:11:46 +02:00
Bård Skaflestad 99c3ec2824 Start a test suite for class BlackoilPropsAd.
Relies on external data ("fluid.data") to describe the fluid model.
2013-05-14 14:59:31 +02:00
Bård Skaflestad 1069cfae6d Merge remote-tracking branch 'atgeirr/master' 2013-05-14 13:41:11 +02:00
Bård Skaflestad a13d78bb06 Start fleshing out overall structure of Newton loop
Specifically,
  - Extract method solveJacobianSystem() for solving a single,
    system of linear equations (i.e., the Newton step).
  - Extract method residualNorm() for computing the residual norm.
    Used in loop control.
  - Stub out a method for computing fluxes.

Compile and run-tested on a linear, gravity-driven flow problem.
2013-05-14 13:40:56 +02:00
Atgeirr Flø Rasmussen 604f137d83 Merge remote-tracking branch 'bska/master' 2013-05-14 13:35:33 +02:00
Atgeirr Flø Rasmussen 53cfceea04 Implemented most of the fluid interface.
Missing is: rsMax() [postponed] and relperm() [coming soon].
2013-05-14 13:33:14 +02:00
Bård Skaflestad 55165bd68d Enforce row-major ordering of the pressure Jacobian
Otherwise, we will use the transposed Jacobian as a coefficient
matrix in the 'linsolver_'.  This is wrong when solving compressible
problems for which the Jacobian matrix is not symmetric.
2013-05-14 11:53:09 +02:00
Bård Skaflestad 3f0f0363c3 Add first, working gravity solution
When run as

    ./test_impestfpa_ad permeability=1.01325e15 ref_pressure=1.0e-5 \
    mu1=1000 mu2=1000 rho1=1 rho2=1

this example reproduces the expected solution (a one-Pascal pressure
increase per cell).

Note that this is an incompressible case, so 'test_impestpfa_ad' must
be compiled with the pre-processor symbol

    HACK_INCOMPRESSIBLE_GRAVITY

defined to a true value (e.g., -DHACK_INCOMPRESSIBLE_GRAVITY=1)
2013-05-14 11:40:07 +02:00
Bård Skaflestad 35cb155537 Merge remote-tracking branch 'atgeirr/master' 2013-05-13 16:37:27 +02:00
Bård Skaflestad e31486e288 Add tentative implementation of gravity flux. 2013-05-13 16:31:26 +02:00
Bård Skaflestad a141e79ead Construct (and store) gravity operator on grid.
The gravity flux of phase 'i' across an (internal) interface is then
given by

    gflux = mob_i * (G * rho_i)

assuming 'rho_i' contains the phase density (at reservoir conditions)
of phase 'i' and 'mob_i' is the phase mobility of phase 'i' at the
interface.
2013-05-13 16:11:48 +02:00
Atgeirr Flø Rasmussen 68aee4d044 Added interface for properties for use with AD code. 2013-05-13 14:03:03 +02:00
Bård Skaflestad 4b737497d5 Implement static gravity potential in DerivedGeology.
This is a stepping stone towards implementing gravity support in
ImpesTPFAAD.
2013-05-13 13:30:00 +02:00
Bård Skaflestad 4721d402e4 Remove an instance of EOL whitespace. 2013-05-13 10:35:50 +02:00
Atgeirr Flø Rasmussen 9620339476 Merge remote-tracking branch 'bska/master'
Conflicts:
	ImpesTPFAAD.hpp
2013-05-13 10:31:15 +02:00
Atgeirr Flø Rasmussen dd679892bc Work in progress on adding well eqns. 2013-05-13 10:26:16 +02:00
Atgeirr Flø Rasmussen e633f59df4 ImpesTPFAAD now takes a linear solver parameter.
Also work in progress on adding well bhp to the system.
2013-05-13 08:35:39 +02:00
Atgeirr Flø Rasmussen 2f62b2e565 Added null() static construction method. 2013-05-13 08:34:22 +02:00
Bård Skaflestad 61f184cdc9 Use constant intermediate quantities. 2013-05-12 22:48:15 +02:00
Atgeirr Flø Rasmussen b0cf134479 Added wells to solver interface, not used for anything yet. 2013-05-12 21:43:54 +02:00
Atgeirr Flø Rasmussen 2f6f32bf6e Added variables() static construction method. 2013-05-12 21:43:32 +02:00
Bård Skaflestad a174d4eb51 Put spdiag() into an anonymous namespace.
This avoids warnings (GCC 4.6) about missing prior function declaration.
2013-05-08 19:21:09 +02:00
Bård Skaflestad 92592672fe Use upwind mobility flux. 2013-05-08 15:06:13 +02:00
Bård Skaflestad 093daa93d7 Implement first cut at pressure system assembly.
Compile-tested only.
2013-05-08 14:34:48 +02:00
Bård Skaflestad baab2cdf43 Implement simple constructor for sparse, diagonal matrix.
This is, effectively, the same as MATLAB's

    spdiags(d, 0)

constructor.
2013-05-08 14:32:48 +02:00
Bård Skaflestad 673c044a6c Rename 'phase' parameter p->phase to avoid confusion. 2013-05-08 13:13:57 +02:00
Bård Skaflestad dfd33d8973 Merge remote-tracking branch 'atgeirr/master' 2013-05-08 13:02:59 +02:00
Bård Skaflestad ea1cdcd478 Assert non-empty state quantities.
This avoids generating a null-pointer dereference for

   &s[0]

in case of s.empty().
2013-05-08 13:02:51 +02:00
Atgeirr Flø Rasmussen a797ce5f32 Use subset() for simpler code. 2013-05-08 12:59:38 +02:00
Atgeirr Flø Rasmussen 1065dbd2f8 Add subset() free function.
Also add overload for UpwindSelector::select() taking constants (not AD variables).
2013-05-08 12:57:38 +02:00
Atgeirr Flø Rasmussen 9fd6678d99 Variable name change. 2013-05-08 12:55:25 +02:00
Bård Skaflestad 3ff5347ac9 Distinguish fluid from geology properties.
Most of class ImpesTPFAAD deals (or will deal) with fluid properties
with only a token nod to the geology--mostly in the form of derived
quantities such as transmissibility and pore volumes.  There is no
need to conflate the roles of fluid interface and geology interface
for this purpose.
2013-05-08 09:39:48 +02:00
Bård Skaflestad 1b3e43068f Include proper file header. 2013-05-08 00:19:25 +02:00
Bård Skaflestad 146b1223d2 Don't check input values. Defaults are fine.
While here, also return zero, which although not strictly needed,
nevertheless indicates to the reader that we're exiting successfully.
2013-05-08 00:17:35 +02:00