GCC Code Coverage Report


Directory: ../../../builds/dumux-repositories/
File: /builds/dumux-repositories/dumux/dumux/porenetwork/solidenergy/fluxvariablescache.hh
Date: 2024-05-04 19:09:25
Exec Total Coverage
Lines: 5 11 45.5%
Functions: 2 5 40.0%
Branches: 0 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-FileCopyrightInfo: 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 PNMSolidEnergyModel
10 * \brief Flux variables cache for PNM solid-energy model
11 */
12 #ifndef DUMUX_PNM_SOLID_ENERGY_FLUXVARIABLESCACHE_HH
13 #define DUMUX_PNM_SOLID_ENERGY_FLUXVARIABLESCACHE_HH
14
15 namespace Dumux::PoreNetwork {
16
17 template<class Scalar>
18 class SolidEnergyFluxVariablesCache
19 {
20 public:
21 //! whether the cache needs an update when the solution changes
22 static bool constexpr isSolDependent = false;
23
24 template<class Problem, class Element, class FVElementGeometry,
25 class ElementVolumeVariables, class SubControlVolumeFace>
26 73944 void update(const Problem& problem,
27 const Element& element,
28 const FVElementGeometry& fvGeometry,
29 const ElementVolumeVariables& elemVolVars,
30 const SubControlVolumeFace& scvf)
31 {
32 147888 grainContactArea_ = problem.spatialParams().throatCrossSectionalArea(element, elemVolVars);
33 147888 throatLength_ = problem.spatialParams().throatLength(element, elemVolVars);
34 147888 throatInscribedRadius_ = problem.spatialParams().throatInscribedRadius(element, elemVolVars);
35 73944 }
36
37 Scalar grainContactArea() const
38 { return grainContactArea_; }
39
40 Scalar throatLength() const
41 { return throatLength_; }
42
43 Scalar throatInscribedRadius() const
44 { return throatInscribedRadius_; }
45
46 private:
47 Scalar grainContactArea_;
48 Scalar throatLength_;
49 Scalar throatInscribedRadius_;
50 };
51
52 } // end namespace Dumux::PoreNetwork
53
54 #endif
55