GCC Code Coverage Report


Directory: ../../../builds/dumux-repositories/
File: dumux/dumux/material/fluidmatrixinteractions/dispersiontensors/fulltensor.hh
Date: 2025-04-12 19:19:20
Exec Total Coverage
Lines: 4 4 100.0%
Functions: 0 0 -%
Branches: 2 4 50.0%

Line Branch Exec Source
1 // -*- mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2 // vi: set et ts=4 sw=4 sts=4:
3 //
4 // SPDX-FileCopyrightText: Copyright © DuMux Project contributors, see AUTHORS.md in root folder
5 // SPDX-License-Identifier: GPL-3.0-or-later
6 //
7 /*!
8 * \file
9 * \ingroup DispersionTensors
10 * \brief Full dispersion tensor
11 */
12
13 #ifndef DUMUX_MATERIAL_FLUIDMATRIX_DISPERSIONTENSORS_FULLTENSOR_HH
14 #define DUMUX_MATERIAL_FLUIDMATRIX_DISPERSIONTENSORS_FULLTENSOR_HH
15
16 #include <dune/common/fmatrix.hh>
17 #include <dumux/common/properties.hh>
18
19 namespace Dumux {
20 /*!
21 * \addtogroup DispersionTensors
22 * \copydetails Dumux::FullDispersionTensor
23 */
24
25 /*!
26 * \ingroup DispersionTensors
27 * \brief Full dispersion tensor
28 *
29 * ### Full dispersion tensor
30 * The full dispersion tensor is given by the spatial parameters.
31 */
32 template<class TypeTag>
33 class FullDispersionTensor
34 {
35 using Problem = GetPropType<TypeTag, Properties::Problem>;
36 using GridGeometry = GetPropType<TypeTag, Properties::GridGeometry>;
37 using FVElementGeometry = typename GridGeometry::LocalView;
38 using SubControlVolumeFace = typename GridGeometry::SubControlVolumeFace;
39 using ElementVolumeVariables = typename GetPropType<TypeTag, Properties::GridVolumeVariables>::LocalView;
40
41 using Scalar = GetPropType<TypeTag, Properties::Scalar>;
42 using GridView = typename GetPropType<TypeTag, Properties::GridGeometry>::GridView;
43 static const int dimWorld = GridView::dimensionworld;
44 using DimWorldMatrix = Dune::FieldMatrix<Scalar, dimWorld, dimWorld>;
45
46 public:
47
48 template <class ElementFluxVariablesCache>
49 7232000 static DimWorldMatrix compositionalDispersionTensor(const Problem& problem,
50 const SubControlVolumeFace& scvf,
51 const FVElementGeometry&,
52 const ElementVolumeVariables&,
53 const ElementFluxVariablesCache&,
54 const int phaseIdx,
55 const int compIdx)
56
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 7232000 times.
7232000 { return problem.spatialParams().dispersionTensor(scvf.center(), phaseIdx, compIdx); }
57
58 template <class ElementFluxVariablesCache>
59 3539200 static DimWorldMatrix thermalDispersionTensor(const Problem& problem,
60 const SubControlVolumeFace& scvf,
61 const FVElementGeometry&,
62 const ElementVolumeVariables&,
63 const ElementFluxVariablesCache&,
64 const int phaseIdx)
65
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 3539200 times.
3539200 { return problem.spatialParams().dispersionTensor(scvf.center(), phaseIdx); }
66
67 };
68
69 } // end namespace Dumux
70
71 #endif
72