26#ifndef DUMUX_DISCRETIZATION_CC_TPFA_COMPUTE_TRANSMISSIBILITY_HH
27#define DUMUX_DISCRETIZATION_CC_TPFA_COMPUTE_TRANSMISSIBILITY_HH
29#include <dune/common/typetraits.hh>
30#include <dune/common/fmatrix.hh>
46template<
class SubControlVolumeFace,
class SubControlVolume,
class Tensor >
48 const SubControlVolume& scv,
50 typename SubControlVolume::Traits::Scalar extrusionFactor)
52 using GlobalPosition =
typename SubControlVolumeFace::Traits::GlobalPosition;
53 GlobalPosition Knormal;
54 T.mv(scvf.unitOuterNormal(), Knormal);
56 auto distanceVector = scvf.ipGlobal();
57 distanceVector -= scv.center();
58 distanceVector /= distanceVector.two_norm2();
60 return (Knormal*distanceVector) * extrusionFactor;
75template<
class SubControlVolumeFace,
76 class SubControlVolume,
78 typename std::enable_if_t<Dune::IsNumber<Tensor>::value,
int> = 0 >
80 const SubControlVolume &scv,
82 typename SubControlVolumeFace::Traits::Scalar extrusionFactor)
84 auto distanceVector = scvf.ipGlobal();
85 distanceVector -= scv.center();
86 distanceVector /= distanceVector.two_norm2();
88 return t * extrusionFactor * (distanceVector * scvf.unitOuterNormal());
Tensor::field_type computeTpfaTransmissibility(const SubControlVolumeFace &scvf, const SubControlVolume &scv, const Tensor &T, typename SubControlVolume::Traits::Scalar extrusionFactor)
Free function to evaluate the Tpfa transmissibility associated with the flux (in the form of flux = T...
Definition: tpfa/computetransmissibility.hh:47
make the local view function available whenever we use the grid geometry
Definition: adapt.hh:29