This commit is contained in:
Melanie Darcis authored and Andreas Lauser committed 2012-07-12 21:22:50 +02:00
1 parent 2849154a60
commit 205c0ffa0c
1 file changed
+20 -3
+20 -3
View File
@@ -114,8 +114,6 @@ public:
const GridView &gridView) const GridView &gridView)
: ParentType(timeManager, gridView) : ParentType(timeManager, gridView)
{ {
// initialize the tables of the fluid system
GET_PROP_TYPE(TypeTag, PTAG(FluidSystem))::init();
} }
// Specified the problem name. This is used as a prefix for files // Specified the problem name. This is used as a prefix for files
@@ -123,6 +121,24 @@ public:
const char *name() const const char *name() const
{ return "tutorial_coupled"; } { return "tutorial_coupled"; }
//! Returns true if a restart file should be written.
/* The default behaviour is to write no restart file.
*/
bool shouldWriteRestartFile() const /*@\label{tutorial-coupled:restart}@*/
{
return false;
}
//! Returns true if the current solution should be written to disk (i.e. as a VTK file)
/*! The default behaviour is to write out the solution for
* every time step. Else, change divisor.
*/
bool shouldWriteOutput() const /*@\label{tutorial-coupled:output}@*/
{
return this->timeManager().timeStepIndex() > 0 &&
(this->timeManager().timeStepIndex() % 1 == 0);
}
// Return the temperature within a finite volume. We use constant // Return the temperature within a finite volume. We use constant
// 10 degrees Celsius. // 10 degrees Celsius.
Scalar temperature(const Element &element, Scalar temperature(const Element &element,
@@ -164,7 +180,8 @@ public:
const GlobalPosition &pos = const GlobalPosition &pos =
fvElemGeom.boundaryFace[boundaryFaceIdx].ipGlobal; fvElemGeom.boundaryFace[boundaryFaceIdx].ipGlobal;
Scalar right = this->bboxMax()[0]; Scalar right = this->bboxMax()[0];
if (pos[0] > right - eps_) { // extraction of oil on the right boundary for approx. 1.e6 seconds
if (pos[0] > right - eps_ && this->timeManager().time() <= 1.e6) {
// oil outflux of 0.3 g/(m * s) on the right boundary. // oil outflux of 0.3 g/(m * s) on the right boundary.
values[Indices::contiWEqIdx] = 0; values[Indices::contiWEqIdx] = 0;
values[Indices::contiNEqIdx] = 3e-4; values[Indices::contiNEqIdx] = 3e-4;