diffusivepart.hh 4.72 KB
Newer Older
1
2
// -*- mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
// vi: set et ts=4 sw=4 sts=4:
3
4
5
/*****************************************************************************
 *   Copyright (C) 2007-2009 by Bernd Flemisch                               *
 *   Copyright (C) 2008-2009 by Markus Wolff                                 *
Andreas Lauser's avatar
Andreas Lauser committed
6
 *   Institute for Modelling Hydraulic and Environmental Systems             *
7
8
9
 *   University of Stuttgart, Germany                                        *
 *   email: <givenname>.<name>@iws.uni-stuttgart.de                          *
 *                                                                           *
10
 *   This program is free software: you can redistribute it and/or modify    *
11
 *   it under the terms of the GNU General Public License as published by    *
12
13
 *   the Free Software Foundation, either version 2 of the License, or       *
 *   (at your option) any later version.                                     *
14
 *                                                                           *
15
16
17
18
19
20
21
 *   This program is distributed in the hope that it will be useful,         *
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of          *
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the           *
 *   GNU General Public License for more details.                            *
 *                                                                           *
 *   You should have received a copy of the GNU General Public License       *
 *   along with this program.  If not, see <http://www.gnu.org/licenses/>.   *
22
23
24
25
 *****************************************************************************/
#ifndef DUMUX_DIFFUSIVEPART_HH
#define DUMUX_DIFFUSIVEPART_HH

26
#include <dumux/decoupled/2p/transport/transportproperties2p.hh>
Bernd Flemisch's avatar
Bernd Flemisch committed
27

28
/**
Markus Wolff's avatar
Markus Wolff committed
29
30
31
 * \file
 * \brief  Base class for defining a diffusive part of the saturation transport equation
 * \author Bernd Flemisch, Markus Wolff
32
33
34
 */
namespace Dumux
{
Markus Wolff's avatar
Markus Wolff committed
35
36
/*!\ingroup FVSaturation2p
 * \brief  Base class for defining the diffusive part of the saturation transport equation
37
 *
Markus Wolff's avatar
Markus Wolff committed
38
 * \tparam TypeTag The problem TypeTag
39
40
41
42
43
 */
template<class TypeTag>
class DiffusivePart
{
private:
44
45
46
    typedef typename GET_PROP_TYPE(TypeTag, GridView) GridView;
      typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar;
      typedef typename GET_PROP_TYPE(TypeTag, Problem) Problem;
47
48
49

    enum{dim = GridView::dimension};
    typedef typename GridView::Traits::template Codim<0>::Entity Element;
50
    typedef typename GridView::Intersection Intersection;
51
    typedef Dune::FieldVector<Scalar, dim> DimVector;
52
53

public:
54
55
56
57

    //! For initialization
    void initialize(){};

Markus Wolff's avatar
Markus Wolff committed
58
59
60
61
62
63
64
    /*! \brief Returns diffusive term for current element face
     *
     *  \param flux        Flux vector (gets the flux from the function)
     *  \param intersection  Intersection of two grid elements/global boundary
     *  \param satI           saturation of current element
     *  \param satJ           saturation of neighbor element
     *  \param pcGradient     gradient of capillary pressure between element I and J
65
     */
66
    void getFlux(DimVector& flux, const Intersection& intersection, Scalar satI, Scalar satJ, const DimVector& pcGradient) const
67
    {}
68

Markus Wolff's avatar
Markus Wolff committed
69
70
71
72
73
74
75
    /*! \brief Returns diffusive term for current element face
     *
     *  \param flux        Flux vector (gets the flux from the function)
     *  \param intersection  Intersection of two grid elements/global boundary
     *  \param satIntersection  saturation at the face between element I and J
     *  \param satGradient       gradient of saturation between element I and J
     *  \param time             time
76
     */
77
78
    void getFlux(DimVector& flux, const Intersection& intersection,
                                    const Scalar satIntersection, const DimVector& satGradient, const Scalar time) const
79
    {}
80

Markus Wolff's avatar
Markus Wolff committed
81
82
83
84
85
86
87
88
89
    /*! \brief Returns diffusive term for current element face
     *
     *  \param flux        Flux vector (gets the flux from the function)
     *  \param intersection  Intersection of two grid elements/global boundary
     *  \param satIntersection  saturation at the face between element I and J
     *  \param satGradient       gradient of saturation between element I and J
     *  \param time             time
     *  \param satI             saturation of current element
     *  \param satJ             saturation of neighbor element
90
     */
91
92
    void getFlux(DimVector& flux, const Intersection& intersection,
                                    const Scalar satIntersection, const DimVector& satGradient, const Scalar time,
93
                                    Scalar satI, Scalar satJ) const
94
    {}
95
96


Markus Wolff's avatar
Markus Wolff committed
97
    //! Constructs a DiffusivePart object
98
    /*
Markus Wolff's avatar
Markus Wolff committed
99
     *  \param A problem class object
100
     */
101
102
    DiffusivePart(Problem& problem)
    {}
Markus Wolff's avatar
Markus Wolff committed
103

104
105
106
107
};
}

#endif