diff --git a/dumux/discretization/fvgridvariables.hh b/dumux/discretization/fvgridvariables.hh index 039fe29d42a7de506562f6a1681922e0b4e3f5e4..ab49a56ee83b866e3812e3bc289b450ae3e9197b 100644 --- a/dumux/discretization/fvgridvariables.hh +++ b/dumux/discretization/fvgridvariables.hh @@ -63,7 +63,7 @@ public: template FVGridVariables(std::shared_ptr problem, - std::shared_ptr fvGridGeometry) + std::shared_ptr fvGridGeometry) : fvGridGeometry_(fvGridGeometry) , curGridVolVars_(*problem) , prevGridVolVars_(*problem) diff --git a/dumux/geomechanics/poroelastic/couplingmanager.hh b/dumux/geomechanics/poroelastic/couplingmanager.hh index 0c42b5265eef6d99a300ad4003b1c05ca97d3ae8..de49960670cc1251a2e41ce5beeb715b62711e86 100644 --- a/dumux/geomechanics/poroelastic/couplingmanager.hh +++ b/dumux/geomechanics/poroelastic/couplingmanager.hh @@ -58,7 +58,7 @@ class PoroMechanicsCouplingManager : public virtual CouplingManager< MDTraits > using ParentType = CouplingManager< MDTraits >; // the sub-domain type tags - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; // further types specific to the sub-problems template using Scalar = GetPropType, Properties::Scalar>; diff --git a/dumux/multidomain/boundary/darcydarcy/couplingmanager.hh b/dumux/multidomain/boundary/darcydarcy/couplingmanager.hh index d2afc37ea074014e4fe6498d83d65d25b857fad8..6cc54be3ae4050506b8b46ed98265bc41fa34886 100644 --- a/dumux/multidomain/boundary/darcydarcy/couplingmanager.hh +++ b/dumux/multidomain/boundary/darcydarcy/couplingmanager.hh @@ -58,13 +58,13 @@ class DarcyDarcyBoundaryCouplingManager using Scalar = typename MDTraits::Scalar; using SolutionVector = typename MDTraits::SolutionVector; - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; template using PrimaryVariables = GetPropType, Properties::PrimaryVariables>; template using NumEqVector = GetPropType, Properties::NumEqVector>; template using ElementVolumeVariables = typename GetPropType, Properties::GridVolumeVariables>::LocalView; template using VolumeVariables = typename GetPropType, Properties::GridVolumeVariables>::VolumeVariables; - template using FVGridGeometry = typename MDTraits::template SubDomainFVGridGeometry; + template using FVGridGeometry = typename MDTraits::template SubDomain::FVGridGeometry; template using FVElementGeometry = typename FVGridGeometry::LocalView; template using SubControlVolumeFace = typename FVGridGeometry::SubControlVolumeFace; template using SubControlVolume = typename FVGridGeometry::SubControlVolume; @@ -73,7 +73,7 @@ class DarcyDarcyBoundaryCouplingManager template static constexpr auto domainIdx() - { return typename MDTraits::template DomainIdx{}; } + { return typename MDTraits::template SubDomain::Index{}; } template static constexpr bool isCCTpfa() diff --git a/dumux/multidomain/boundary/darcydarcy/couplingmapper.hh b/dumux/multidomain/boundary/darcydarcy/couplingmapper.hh index 6ddda7ed9d9800dcf840f03c8510386517cd5680..f22e8a1f1ca118c8d1449d52ab6bbaa4849ecc13 100644 --- a/dumux/multidomain/boundary/darcydarcy/couplingmapper.hh +++ b/dumux/multidomain/boundary/darcydarcy/couplingmapper.hh @@ -53,14 +53,14 @@ class DarcyDarcyBoundaryCouplingMapper { using Scalar = typename MDTraits::Scalar; - template using FVGridGeometry = typename MDTraits::template SubDomainFVGridGeometry; + template using FVGridGeometry = typename MDTraits::template SubDomain::FVGridGeometry; template using SubControlVolumeFace = typename FVGridGeometry::SubControlVolumeFace; template using GridView = typename FVGridGeometry::GridView; template using Element = typename GridView::template Codim<0>::Entity; template static constexpr auto domainIdx() - { return typename MDTraits::template DomainIdx{}; } + { return typename MDTraits::template SubDomain::Index{}; } template static constexpr bool isCCTpfa() diff --git a/dumux/multidomain/boundary/stokesdarcy/couplingdata.hh b/dumux/multidomain/boundary/stokesdarcy/couplingdata.hh index b7f12b80202bdaab5de5b31e256337881ce4cd64..dd03b033768d25990ae3fd84ab6b233ccfc004a1 100644 --- a/dumux/multidomain/boundary/stokesdarcy/couplingdata.hh +++ b/dumux/multidomain/boundary/stokesdarcy/couplingdata.hh @@ -217,8 +217,8 @@ class StokesDarcyCouplingDataImplementation; */ template using StokesDarcyCouplingData = StokesDarcyCouplingDataImplementation, Properties::ModelTraits>::enableEnergyBalance(), - (GetPropType, Properties::ModelTraits>::numComponents() > 1)>; + GetPropType::TypeTag, Properties::ModelTraits>::enableEnergyBalance(), + (GetPropType::TypeTag, Properties::ModelTraits>::numComponents() > 1)>; /*! * \ingroup MultiDomain @@ -231,7 +231,7 @@ class StokesDarcyCouplingDataImplementationBase { using Scalar = typename MDTraits::Scalar; - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using Element = typename FVGridGeometry::GridView::template Codim<0>::Entity; template using FVElementGeometry = typename FVGridGeometry::LocalView; @@ -469,14 +469,14 @@ class StokesDarcyCouplingDataImplementation; using Scalar = typename MDTraits::Scalar; - static constexpr auto stokesIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto darcyIdx = typename MDTraits::template DomainIdx<2>(); + static constexpr auto stokesIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto darcyIdx = typename MDTraits::template SubDomain<2>::Index(); static constexpr auto stokesCellCenterIdx = stokesIdx; - static constexpr auto stokesFaceIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto stokesFaceIdx = typename MDTraits::template SubDomain<1>::Index(); // the sub domain type tags template - using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using Element = typename FVGridGeometry::GridView::template Codim<0>::Entity; @@ -633,14 +633,14 @@ class StokesDarcyCouplingDataImplementation; using Scalar = typename MDTraits::Scalar; - static constexpr auto stokesIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto darcyIdx = typename MDTraits::template DomainIdx<2>(); + static constexpr auto stokesIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto darcyIdx = typename MDTraits::template SubDomain<2>::Index(); static constexpr auto stokesCellCenterIdx = stokesIdx; - static constexpr auto stokesFaceIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto stokesFaceIdx = typename MDTraits::template SubDomain<1>::Index(); // the sub domain type tags template - using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using Element = typename FVGridGeometry::GridView::template Codim<0>::Entity; diff --git a/dumux/multidomain/boundary/stokesdarcy/couplingmanager.hh b/dumux/multidomain/boundary/stokesdarcy/couplingmanager.hh index df2e4d1e4ec218ef5f78c2a933d0f571b51f7f1d..16ed0624c1b041d26cdceb27ceb4a7069e111de1 100644 --- a/dumux/multidomain/boundary/stokesdarcy/couplingmanager.hh +++ b/dumux/multidomain/boundary/stokesdarcy/couplingmanager.hh @@ -55,27 +55,27 @@ class StokesDarcyCouplingManager using ParentType = StaggeredCouplingManagerBase>; public: - static constexpr auto stokesCellCenterIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto stokesFaceIdx = typename MDTraits::template DomainIdx<1>(); - static constexpr auto cellCenterIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto faceIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto stokesCellCenterIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto stokesFaceIdx = typename MDTraits::template SubDomain<1>::Index(); + static constexpr auto cellCenterIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto faceIdx = typename MDTraits::template SubDomain<1>::Index(); static constexpr auto stokesIdx = stokesCellCenterIdx; - static constexpr auto darcyIdx = typename MDTraits::template DomainIdx<2>(); + static constexpr auto darcyIdx = typename MDTraits::template SubDomain<2>::Index(); private: using SolutionVector = typename MDTraits::SolutionVector; // obtain the type tags of the sub problems - using StokesTypeTag = typename MDTraits::template SubDomainTypeTag<0>; - using DarcyTypeTag = typename MDTraits::template SubDomainTypeTag<2>; + using StokesTypeTag = typename MDTraits::template SubDomain<0>::TypeTag; + using DarcyTypeTag = typename MDTraits::template SubDomain<2>::TypeTag; using CouplingStencils = std::unordered_map >; using CouplingStencil = CouplingStencils::mapped_type; // the sub domain type tags template - using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; static constexpr bool isCompositional = GetPropType, Properties::ModelTraits>::numComponents() > 1; @@ -91,7 +91,7 @@ private: template using ElementFluxVariablesCache = typename GetPropType, Properties::GridFluxVariablesCache>::LocalView; template using GridVariables = GetPropType, Properties::GridVariables>; template using Element = typename GridView::template Codim<0>::Entity; - template using PrimaryVariables = typename MDTraits::template PrimaryVariables; + template using PrimaryVariables = typename MDTraits::template SubDomain::PrimaryVariables; template using SubControlVolumeFace = typename FVElementGeometry::SubControlVolumeFace; using CellCenterSolutionVector = GetPropType; diff --git a/dumux/multidomain/boundary/stokesdarcy/couplingmapper.hh b/dumux/multidomain/boundary/stokesdarcy/couplingmapper.hh index ea9ae18f42d0e7c5b215fe78b4754667471c3ac0..b6d68ef6065c1f52c2289790622fb7656a548c6c 100644 --- a/dumux/multidomain/boundary/stokesdarcy/couplingmapper.hh +++ b/dumux/multidomain/boundary/stokesdarcy/couplingmapper.hh @@ -54,18 +54,18 @@ class StokesDarcyCouplingMapper using Scalar = typename MDTraits::Scalar; public: - static constexpr auto stokesCellCenterIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto stokesFaceIdx = typename MDTraits::template DomainIdx<1>(); - static constexpr auto cellCenterIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto faceIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto stokesCellCenterIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto stokesFaceIdx = typename MDTraits::template SubDomain<1>::Index(); + static constexpr auto cellCenterIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto faceIdx = typename MDTraits::template SubDomain<1>::Index(); static constexpr auto stokesIdx = stokesCellCenterIdx; - static constexpr auto darcyIdx = typename MDTraits::template DomainIdx<2>(); + static constexpr auto darcyIdx = typename MDTraits::template SubDomain<2>::Index(); private: // obtain the type tags of the sub problems - using StokesTypeTag = typename MDTraits::template SubDomainTypeTag<0>; - using DarcyTypeTag = typename MDTraits::template SubDomainTypeTag<2>; + using StokesTypeTag = typename MDTraits::template SubDomain<0>::TypeTag; + using DarcyTypeTag = typename MDTraits::template SubDomain<2>::TypeTag; struct ElementMapInfo { @@ -76,7 +76,7 @@ private: // the sub domain type tags template - using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; using CouplingManager = GetPropType; static_assert(GetPropType, Properties::FVGridGeometry>::discMethod == DiscretizationMethod::staggered, diff --git a/dumux/multidomain/couplingmanager.hh b/dumux/multidomain/couplingmanager.hh index 9e220aa31a359133729e0021046e74afaf57ff13..37f2b20f5f8c2a4947596547d7d1943b3f97f803 100644 --- a/dumux/multidomain/couplingmanager.hh +++ b/dumux/multidomain/couplingmanager.hh @@ -44,13 +44,13 @@ namespace Dumux { template class CouplingManager { - template using SubDomainTypeTag = typename Traits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename Traits::template SubDomain::TypeTag; template using PrimaryVariables = GetPropType, Properties::PrimaryVariables>; template using GridView = typename GetPropType, Properties::FVGridGeometry>::GridView; template using Element = typename GridView::template Codim<0>::Entity; template using Problem = GetPropType, Properties::Problem>; template using ProblemWeakPtr = std::weak_ptr>; - using Problems = typename Traits::template MakeTuple; + using Problems = typename Traits::template Tuple; public: //! default type used for coupling element stencils diff --git a/dumux/multidomain/embedded/couplingmanager1d3d.hh b/dumux/multidomain/embedded/couplingmanager1d3d.hh index 41b0ae8eeaab3ba739399658fe40d51737d6461b..c7a4b65e65c9d2da5ab4a6a73cd9afdd0f6043ad 100644 --- a/dumux/multidomain/embedded/couplingmanager1d3d.hh +++ b/dumux/multidomain/embedded/couplingmanager1d3d.hh @@ -54,7 +54,7 @@ template struct CircleAveragePointSourceTraits { private: - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using NumEqVector = GetPropType, Properties::NumEqVector>; public: @@ -98,11 +98,11 @@ class EmbeddedCouplingManager1d3d using Scalar = typename MDTraits::Scalar; using SolutionVector = typename MDTraits::SolutionVector; - static constexpr auto bulkIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto lowDimIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto bulkIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto lowDimIdx = typename MDTraits::template SubDomain<1>::Index(); // the sub domain type aliases - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using GridView = typename FVGridGeometry::GridView; @@ -198,11 +198,11 @@ class EmbeddedCouplingManager1d3d using SolutionVector = typename MDTraits::SolutionVector; using PointSourceData = typename ParentType::PointSourceTraits::PointSourceData; - static constexpr auto bulkIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto lowDimIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto bulkIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto lowDimIdx = typename MDTraits::template SubDomain<1>::Index(); // the sub domain type aliases - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using GridView = typename FVGridGeometry::GridView; @@ -576,11 +576,11 @@ class EmbeddedCouplingManager1d3d(); - static constexpr auto lowDimIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto bulkIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto lowDimIdx = typename MDTraits::template SubDomain<1>::Index(); // the sub domain type aliases - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using GridView = typename FVGridGeometry::GridView; @@ -853,11 +853,11 @@ class EmbeddedCouplingManager1d3d using SolutionVector = typename MDTraits::SolutionVector; using PointSourceData = typename ParentType::PointSourceTraits::PointSourceData; - static constexpr auto bulkIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto lowDimIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto bulkIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto lowDimIdx = typename MDTraits::template SubDomain<1>::Index(); // the sub domain type aliases - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using GridView = typename FVGridGeometry::GridView; diff --git a/dumux/multidomain/embedded/couplingmanagerbase.hh b/dumux/multidomain/embedded/couplingmanagerbase.hh index fa5fec57f1a3b56a12cd9316dfdde495d25a93ed..c56ad8e041a1e10e95785e6654805a1e0166c395 100644 --- a/dumux/multidomain/embedded/couplingmanagerbase.hh +++ b/dumux/multidomain/embedded/couplingmanagerbase.hh @@ -51,7 +51,7 @@ template struct DefaultPointSourceTraits { private: - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using NumEqVector = GetPropType, Properties::NumEqVector>; public: @@ -79,14 +79,14 @@ class EmbeddedCouplingManagerBase { using ParentType = CouplingManager; using Scalar = typename MDTraits::Scalar; - static constexpr auto bulkIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto lowDimIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto bulkIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto lowDimIdx = typename MDTraits::template SubDomain<1>::Index(); using SolutionVector = typename MDTraits::SolutionVector; using PointSourceData = typename PSTraits::PointSourceData; // the sub domain type tags template using PointSource = typename PSTraits::template PointSource; - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; template using PrimaryVariables = GetPropType, Properties::PrimaryVariables>; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; diff --git a/dumux/multidomain/embedded/extendedsourcestencil.hh b/dumux/multidomain/embedded/extendedsourcestencil.hh index ead7fb11a7a4117e1075689471edd16ee668bf6e..ad266597aaf8a22400942273c503a0105298634b 100644 --- a/dumux/multidomain/embedded/extendedsourcestencil.hh +++ b/dumux/multidomain/embedded/extendedsourcestencil.hh @@ -50,13 +50,13 @@ class ExtendedSourceStencil using MDTraits = typename CouplingManager::MultiDomainTraits; using Scalar = typename MDTraits::Scalar; - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; template using GridView = typename FVGridGeometry::GridView; template using Element = typename GridView::template Codim<0>::Entity; - static constexpr auto bulkIdx = typename MDTraits::template DomainIdx<0>(); - static constexpr auto lowDimIdx = typename MDTraits::template DomainIdx<1>(); + static constexpr auto bulkIdx = typename MDTraits::template SubDomain<0>::Index(); + static constexpr auto lowDimIdx = typename MDTraits::template SubDomain<1>::Index(); template static constexpr bool isBox() diff --git a/dumux/multidomain/embedded/pointsourcedata.hh b/dumux/multidomain/embedded/pointsourcedata.hh index 088defdf6704c2aff382c1c8b5675eaf31794d5c..4bade7c0a900a0900e59b9040ba51ead970026f5 100644 --- a/dumux/multidomain/embedded/pointsourcedata.hh +++ b/dumux/multidomain/embedded/pointsourcedata.hh @@ -47,8 +47,8 @@ class PointSourceData using ShapeValues = typename std::vector >; // obtain the type tags of the sub problems - using BulkTypeTag = typename MDTraits::template SubDomainTypeTag<0>; - using LowDimTypeTag = typename MDTraits::template SubDomainTypeTag<1>; + using BulkTypeTag = typename MDTraits::template SubDomain<0>::TypeTag; + using LowDimTypeTag = typename MDTraits::template SubDomain<1>::TypeTag; using BulkPrimaryVariables = GetPropType; using LowDimPrimaryVariables = GetPropType; @@ -155,8 +155,8 @@ class PointSourceDataCircleAverage : public PointSourceData using ShapeValues = typename std::vector >; // obtain the type tags of the sub problems - using BulkTypeTag = typename MDTraits::template SubDomainTypeTag<0>; - using LowDimTypeTag = typename MDTraits::template SubDomainTypeTag<1>; + using BulkTypeTag = typename MDTraits::template SubDomain<0>::TypeTag; + using LowDimTypeTag = typename MDTraits::template SubDomain<1>::TypeTag; using BulkPrimaryVariables = GetPropType; using LowDimPrimaryVariables = GetPropType; diff --git a/dumux/multidomain/facet/box/couplingmanager.hh b/dumux/multidomain/facet/box/couplingmanager.hh index 6c5f2b9acd741240c696eec20311090d9f5ad883..c725306a2d4cfde725e46f9213e3e62c4e53c217 100644 --- a/dumux/multidomain/facet/box/couplingmanager.hh +++ b/dumux/multidomain/facet/box/couplingmanager.hh @@ -55,13 +55,13 @@ class FacetCouplingManager; // convenience aliases and instances of the two domain ids - using BulkIdType = typename MDTraits::template DomainIdx; - using LowDimIdType = typename MDTraits::template DomainIdx; + using BulkIdType = typename MDTraits::template SubDomain::Index; + using LowDimIdType = typename MDTraits::template SubDomain::Index; static constexpr auto bulkId = BulkIdType(); static constexpr auto lowDimId = LowDimIdType(); // the sub-domain type tags - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; // further types specific to the sub-problems template using PrimaryVariables = GetPropType, Properties::PrimaryVariables>; diff --git a/dumux/multidomain/facet/cellcentered/tpfa/couplingmanager.hh b/dumux/multidomain/facet/cellcentered/tpfa/couplingmanager.hh index bc9bd8b214508f555968be3a4d9b059ed4b95890..b0b80259755b720fe8ff42a3b18a004e14b9e1be 100644 --- a/dumux/multidomain/facet/cellcentered/tpfa/couplingmanager.hh +++ b/dumux/multidomain/facet/cellcentered/tpfa/couplingmanager.hh @@ -55,13 +55,13 @@ class FacetCouplingManager; // convenience aliases and instances of the two domain ids - using BulkIdType = typename MDTraits::template DomainIdx; - using LowDimIdType = typename MDTraits::template DomainIdx; + using BulkIdType = typename MDTraits::template SubDomain::Index; + using LowDimIdType = typename MDTraits::template SubDomain::Index; static constexpr auto bulkId = BulkIdType(); static constexpr auto lowDimId = LowDimIdType(); // the sub-domain type tags - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; // further types specific to the sub-problems template using PrimaryVariables = GetPropType, Properties::PrimaryVariables>; diff --git a/dumux/multidomain/facet/couplingmanager.hh b/dumux/multidomain/facet/couplingmanager.hh index 11c8261594ac4e4d67277f51910b31328ad36887..4668b2cefe4cadad4d645fb807796442afcd3999 100644 --- a/dumux/multidomain/facet/couplingmanager.hh +++ b/dumux/multidomain/facet/couplingmanager.hh @@ -90,7 +90,7 @@ template< class MDTraits, class CouplingMapper, std::size_t bulkDomainId = 0, std::size_t lowDimDomainId = 1, - DiscretizationMethod bulkDM = GetPropType, Properties::FVGridGeometry>::discMethod > + DiscretizationMethod bulkDM = GetPropType::TypeTag, Properties::FVGridGeometry>::discMethod > class FacetCouplingManager; /*! @@ -119,15 +119,15 @@ class FacetCouplingThreeDomainManager using FacetEdgeManager = FacetCouplingManager; // convenience aliases and instances of the domain ids - using BulkIdType = typename MDTraits::template DomainIdx; - using FacetIdType = typename MDTraits::template DomainIdx; - using EdgeIdType = typename MDTraits::template DomainIdx; + using BulkIdType = typename MDTraits::template SubDomain::Index; + using FacetIdType = typename MDTraits::template SubDomain::Index; + using EdgeIdType = typename MDTraits::template SubDomain::Index; static constexpr auto bulkId = BulkIdType(); static constexpr auto facetId = FacetIdType(); static constexpr auto edgeId = EdgeIdType(); // the sub-domain type tags - template using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + template using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; // further types specific to the sub-problems template using LocalResidual = GetPropType, Properties::LocalResidual>; diff --git a/dumux/multidomain/fvassembler.hh b/dumux/multidomain/fvassembler.hh index 13e80fa458b1e8edd00e2b90c5d639096670954b..dfd40d2decc5c704687356fcdf966aedac1839dd 100644 --- a/dumux/multidomain/fvassembler.hh +++ b/dumux/multidomain/fvassembler.hh @@ -58,18 +58,25 @@ template - using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; public: using Traits = MDTraits; using Scalar = typename MDTraits::Scalar; + //! TODO get rid of this GetPropType template using LocalResidual = GetPropType, Properties::LocalResidual>; template - using GridVariables = typename std::tuple_element_t::element_type; + using GridVariables = typename MDTraits::template SubDomain::GridVariables; + + template + using FVGridGeometry = typename MDTraits::template SubDomain::FVGridGeometry; + + template + using Problem = typename MDTraits::template SubDomain::Problem; using JacobianMatrix = typename MDTraits::JacobianMatrix; using SolutionVector = typename MDTraits::SolutionVector; @@ -85,9 +92,9 @@ public: private: - using ProblemTuple = typename MDTraits::ProblemTuple; - using FVGridGeometryTuple = typename MDTraits::FVGridGeometryTuple; - using GridVariablesTuple = typename MDTraits::GridVariablesTuple; + using ProblemTuple = typename MDTraits::template TupleOfSharedPtrConst; + using FVGridGeometryTuple = typename MDTraits::template TupleOfSharedPtrConst; + using GridVariablesTuple = typename MDTraits::template TupleOfSharedPtr; using TimeLoop = TimeLoopBase; using ThisType = MultiDomainFVAssembler; @@ -119,9 +126,6 @@ private: using type = SubDomainStaggeredLocalAssembler, ThisType, diffMethod, isImplicit()>; }; - template - using FVGridGeometry = typename std::tuple_element::type::element_type; - template using SubDomainAssembler = typename SubDomainAssemblerType::discMethod, id>::type; diff --git a/dumux/multidomain/newtonsolver.hh b/dumux/multidomain/newtonsolver.hh index 2f3b2a987cac094720214fa16236c47ea87c96e2..8b2b4aa0e42770dde5304186547c96498dfb134b 100644 --- a/dumux/multidomain/newtonsolver.hh +++ b/dumux/multidomain/newtonsolver.hh @@ -60,7 +60,7 @@ class MultiDomainNewtonSolver: public NewtonSolver using PrivarSwitchPtr = std::unique_ptr>; - using PriVarSwitchPtrTuple = typename Assembler::Traits::template MakeTuple; + using PriVarSwitchPtrTuple = typename Assembler::Traits::template Tuple; public: diff --git a/dumux/multidomain/staggeredcouplingmanager.hh b/dumux/multidomain/staggeredcouplingmanager.hh index 60c90bdd0af23498d304903a938b3d14566a97cd..c463055362176b3c083d7da8e009e32fa1ef3d86 100644 --- a/dumux/multidomain/staggeredcouplingmanager.hh +++ b/dumux/multidomain/staggeredcouplingmanager.hh @@ -42,12 +42,12 @@ class StaggeredCouplingManagerBase: public CouplingManager { using ParentType = CouplingManager; template - using SubDomainTypeTag = typename MDTraits::template SubDomainTypeTag; + using SubDomainTypeTag = typename MDTraits::template SubDomain::TypeTag; template using Problem = GetPropType, Properties::Problem>; - using StaggeredSubDomainTypeTag = typename MDTraits::template SubDomainTypeTag<0>; + using StaggeredSubDomainTypeTag = typename MDTraits::template SubDomain<0>::TypeTag; - template using FVGridGeometry = typename std::tuple_element_t::element_type; + template using FVGridGeometry = typename MDTraits::template SubDomain::FVGridGeometry; template using GridView = typename FVGridGeometry::GridView; using FVElementGeometry = typename FVGridGeometry<0>::LocalView; @@ -205,8 +205,8 @@ public: decltype(auto) numericEpsilon(Dune::index_constant, const std::string& paramGroup) const { - constexpr std::size_t numEqCellCenter = Traits::template PrimaryVariables::dimension; - constexpr std::size_t numEqFace = Traits::template PrimaryVariables::dimension; + constexpr std::size_t numEqCellCenter = Traits::template SubDomain::PrimaryVariables::dimension; + constexpr std::size_t numEqFace = Traits::template SubDomain::PrimaryVariables::dimension; constexpr bool isCellCenter = FVGridGeometry::isCellCenter(); constexpr std::size_t numEq = isCellCenter ? numEqCellCenter : numEqFace; constexpr auto prefix = isCellCenter ? "CellCenter" : "Face"; diff --git a/dumux/multidomain/staggeredtraits.hh b/dumux/multidomain/staggeredtraits.hh index 96e9de31cd5a28dc0eaaeb5cd599ffaed8d23e7f..66b3af03f5e94e88b7370e21692b9ee6ed8a8d5c 100644 --- a/dumux/multidomain/staggeredtraits.hh +++ b/dumux/multidomain/staggeredtraits.hh @@ -43,6 +43,92 @@ #include "traits.hh" namespace Dumux { +namespace Detail { +namespace Staggered { + +////////////////////////////////////////////////////////// +template class SubDomainTypeTag, std::size_t i> +struct SubDomainFVGridGeometryImpl +{ using type = GetPropType, Properties::FVGridGeometry>; }; + +template class SubDomainTypeTag> +struct SubDomainFVGridGeometryImpl +{ using type = typename GetPropType, Properties::FVGridGeometry>::CellCenterFVGridGeometryType; }; + +template class SubDomainTypeTag> +struct SubDomainFVGridGeometryImpl +{ using type = typename GetPropType, Properties::FVGridGeometry>::FaceFVGridGeometryType; }; +////////////////////////////////////////////////////////// + +////////////////////////////////////////////////////////// +template class SubDomainTypeTag, std::size_t i> +struct SubDomainGridVariablesImpl +{ using type = GetPropType, Properties::GridVariables>; }; + +template class SubDomainTypeTag> +struct SubDomainGridVariablesImpl +{ using type = typename GetPropType, Properties::GridVariables>::CellCenterGridVariablesType; }; + +template class SubDomainTypeTag> +struct SubDomainGridVariablesImpl +{ using type = typename GetPropType, Properties::GridVariables>::FaceGridVariablesType; }; +////////////////////////////////////////////////////////// + +////////////////////////////////////////////////////////// +template class SubDomainTypeTag, std::size_t i> +struct SubDomainPrimaryVariablesImpl +{ using type = GetPropType, Properties::PrimaryVariables>; }; + +template class SubDomainTypeTag> +struct SubDomainPrimaryVariablesImpl +{ using type = GetPropType, Properties::CellCenterPrimaryVariables>; }; + +template class SubDomainTypeTag> +struct SubDomainPrimaryVariablesImpl +{ using type = GetPropType, Properties::FacePrimaryVariables>; }; +////////////////////////////////////////////////////////// + +template +struct JacobianTypeImpl +{ + private: + using MatrixBlock = typename Dune::FieldMatrix; + public: + using type = typename Dune::BCRSMatrix; +}; + +////////////////////////////////////////////////////////// +template class SubDomainTypeTag, std::size_t i> +struct SubDomainJacobianMatrixImpl +{ using type = GetPropType, Properties::JacobianMatrix>; }; + +template class SubDomainTypeTag> +struct SubDomainJacobianMatrixImpl +{ using type = typename JacobianTypeImpl, Properties::Scalar>, + getPropValue, Properties::NumEqCellCenter>()>::type; }; + +template class SubDomainTypeTag> +struct SubDomainJacobianMatrixImpl +{ using type = typename JacobianTypeImpl, Properties::Scalar>, + getPropValue, Properties::NumEqFace>()>::type; }; +////////////////////////////////////////////////////////// + +////////////////////////////////////////////////////////// +template class SubDomainTypeTag, std::size_t i> +struct SubDomainSolutionVectorImpl +{ using type = GetPropType, Properties::SolutionVector>; }; + +template class SubDomainTypeTag> +struct SubDomainSolutionVectorImpl +{ using type = GetPropType, Properties::CellCenterSolutionVector>; }; + +template class SubDomainTypeTag> +struct SubDomainSolutionVectorImpl +{ using type = GetPropType, Properties::FaceSolutionVector>; }; +////////////////////////////////////////////////////////// + +} // end namespace Staggered +} // end namespace Detail /* * \ingroup MultiDomain @@ -73,95 +159,83 @@ namespace Dumux { template struct StaggeredMultiDomainTraits { + //! the number of subdomains static constexpr std::size_t numSubDomains = sizeof...(SubDomainTypeTags); +private: + //! the type tag of a sub domain problem template using SubDomainTypeTag = typename std::tuple_element_t>; - //! the static domain indices - template - using DomainIdx = Dune::index_constant; - -private: + //! helper alias to construct derived multidomain types like tuples using Indices = std::make_index_sequence; - template - using SolutionSubVector = std::conditional_t<(id < 2), - std::conditional_t<(id == 0), - GetPropType, Properties::CellCenterSolutionVector>, - GetPropType, Properties::FaceSolutionVector>>, - GetPropType, Properties::SolutionVector>>; - + //! the scalar type of each sub domain template using SubDomainScalar = GetPropType, Properties::Scalar>; template - using SubDomainProblem = std::shared_ptr, Properties::Problem>>; + using SubDomainJacobianMatrix = typename Detail::Staggered::SubDomainJacobianMatrixImpl::type; template - using SubDomainFVGridGeometry = std::shared_ptr, Properties::FVGridGeometry>::CellCenterFVGridGeometryType, - typename GetPropType, Properties::FVGridGeometry>::FaceFVGridGeometryType>, - GetPropType, Properties::FVGridGeometry>>>; + using SubDomainSolutionVector = typename Detail::Staggered::SubDomainSolutionVectorImpl::type; + +public: + + /* + * \brief sub domain types + */ + //\{ template - using SubDomainGridVariables = std::shared_ptr, Properties::GridVariables>::CellCenterGridVariablesType, - typename GetPropType, Properties::GridVariables>::FaceGridVariablesType>, - GetPropType, Properties::GridVariables>>>; - - template - struct JacobianType + struct SubDomain { - private: - using MatrixBlock = typename Dune::FieldMatrix; - public: - using type = typename Dune::BCRSMatrix; + using Index = Dune::index_constant; + using TypeTag = SubDomainTypeTag; + using Problem = GetPropType, Properties::Problem>; + using FVGridGeometry = typename Detail::Staggered::SubDomainFVGridGeometryImpl::type; + using GridVariables = typename Detail::Staggered::SubDomainGridVariablesImpl::type; + using SolutionVector = typename Detail::Staggered::SubDomainSolutionVectorImpl::type; + using PrimaryVariables = typename Detail::Staggered::SubDomainPrimaryVariablesImpl::type; }; + //\} - template - using JacobianDiagBlock = std::conditional_t<(id < 2), - std::conditional_t<(id == 0), - typename JacobianType, Properties::Scalar>, getPropValue, Properties::NumEqCellCenter>()>::type, - typename JacobianType, Properties::Scalar>, getPropValue, Properties::NumEqFace>()>::type>, - GetPropType, Properties::JacobianMatrix>>; - -public: + /* + * \brief multi domain types + */ + //\{ //! the scalar type using Scalar = typename makeFromIndexedType::type; //! the solution vector type - using SolutionVector = typename makeFromIndexedType::type; - - template - using PrimaryVariables = std::conditional_t<(id < 2), - std::conditional_t<(id == 0), GetPropType, Properties::CellCenterPrimaryVariables>, - GetPropType, Properties::FacePrimaryVariables>>, - GetPropType, Properties::PrimaryVariables>>; - - template - using createMatrixType = typename Detail::createMultiTypeBlockMatrixType::type::type; + using SolutionVector = typename makeFromIndexedType::type; //! the jacobian type - using JacobianMatrix = typename makeFromIndexedType::type; + using JacobianMatrix = typename Detail::MultiDomainMatrixType::type; - //! the tuple of problems - using ProblemTuple = typename makeFromIndexedType::type; + //\} - //! the tuple of fv grid geometries - using FVGridGeometryTuple = typename makeFromIndexedType::type; + /* + * \brief helper aliases to contruct derived tuple types + */ + //\{ - //! the tuple of grid variables - using GridVariablesTuple = typename makeFromIndexedType::type; + //! helper alias to create tuple<...> from indexed type + template class T> + using Tuple = typename makeFromIndexedType::type; - //! convenience alias to create tuple from type + //! helper alias to create tuple> from indexed type template class T> - using MakeTuple = typename makeFromIndexedType::type; + using TupleOfSharedPtr = typename Detail::MultiDomainTupleSharedPtr::type; + + //! helper alias to create tuple> from indexed type + template class T> + using TupleOfSharedPtrConst = typename Detail::MultiDomainTupleSharedPtrConst::type; + + //\} }; } //end namespace Dumux diff --git a/dumux/multidomain/traits.hh b/dumux/multidomain/traits.hh index bf8b7806d1eef3c949c45f4da459def06ebcc600..3c4b0633cdc85e3204cc6da5242099b563a14231 100644 --- a/dumux/multidomain/traits.hh +++ b/dumux/multidomain/traits.hh @@ -28,6 +28,7 @@ #include #include #include +#include #include #include @@ -83,6 +84,36 @@ public: using type = typename makeMatrix::type; }; +//! helper alias to create a tuple of shared_ptr<...> from an indexed type +template class T, class Indices> +struct MultiDomainTupleSharedPtr +{ + template + using PtrType = std::shared_ptr>; + + using type = typename makeFromIndexedType::type; +}; + +//! helper alias to create a tuple of shared_ptr from an indexed type +template class T, class Indices> +struct MultiDomainTupleSharedPtrConst +{ + template + using PtrType = std::shared_ptr>; + + using type = typename makeFromIndexedType::type; +}; + +//! helper alias to create the JacobianMatrix type +template class SubDomainDiagBlocks, class Indices, class Scalar> +struct MultiDomainMatrixType +{ + template + using M = typename createMultiTypeBlockMatrixType::type::type; + + using type = typename makeFromIndexedType::type; +}; + } // end namespace Detail /* @@ -113,67 +144,86 @@ public: template struct MultiDomainTraits { + //! the number of subdomains static constexpr std::size_t numSubDomains = sizeof...(SubDomainTypeTags); +private: + //! the type tag of a sub domain problem template using SubDomainTypeTag = typename std::tuple_element_t>; - //! the static domain indices - template - using DomainIdx = Dune::index_constant; - - //! the sub domain geometry - template - using SubDomainFVGridGeometry = GetPropType, Properties::FVGridGeometry>; - -private: + //! helper alias to construct derived multidomain types like tuples using Indices = std::make_index_sequence; - template - using SolutionSubVector = GetPropType, Properties::SolutionVector>; - + //! the scalar type of each sub domain template using SubDomainScalar = GetPropType, Properties::Scalar>; + //! the jacobian type of each sub domain template - using SubDomainProblem = std::shared_ptr, Properties::Problem>>; + using SubDomainJacobianMatrix = GetPropType, Properties::JacobianMatrix>; + //! the solution type of each sub domain template - using SubDomainFVGridGeometryPtr = std::shared_ptr, Properties::FVGridGeometry>>; + using SubDomainSolutionVector = GetPropType, Properties::SolutionVector>; - template - using SubDomainGridVariables = std::shared_ptr, Properties::GridVariables>>; +public: + + /* + * \brief sub domain types + */ + //\{ template - using JacobianDiagBlock = GetPropType, Properties::JacobianMatrix>; + struct SubDomain + { + using Index = Dune::index_constant; + using TypeTag = SubDomainTypeTag; + using Grid = GetPropType, Properties::Grid>; + using FVGridGeometry = GetPropType, Properties::FVGridGeometry>; + using Problem = GetPropType, Properties::Problem>; + using GridVariables =GetPropType, Properties::GridVariables>; + using IOFields = GetPropType, Properties::IOFields>; + using SolutionVector = GetPropType, Properties::SolutionVector>; + }; -public: + //\} + + /* + * \brief multi domain types + */ + //\{ //! the scalar type using Scalar = typename makeFromIndexedType::type; //! the solution vector type - using SolutionVector = typename makeFromIndexedType::type; - - template - using createMatrixType = typename Detail::createMultiTypeBlockMatrixType::type::type; + using SolutionVector = typename makeFromIndexedType::type; //! the jacobian type - using JacobianMatrix = typename makeFromIndexedType::type; + using JacobianMatrix = typename Detail::MultiDomainMatrixType::type; - //! the tuple of problems - using ProblemTuple = typename makeFromIndexedType::type; + //\} - //! the tuple of fv grid geometries - using FVGridGeometryTuple = typename makeFromIndexedType::type; + /* + * \brief helper aliases to contruct derived tuple types + */ + //\{ - //! the tuple of grid variables - using GridVariablesTuple = typename makeFromIndexedType::type; + //! helper alias to create tuple<...> from indexed type + template class T> + using Tuple = typename makeFromIndexedType::type; + + //! helper alias to create tuple> from indexed type + template class T> + using TupleOfSharedPtr = typename Detail::MultiDomainTupleSharedPtr::type; - //! convenience alias to create tuple from type + //! helper alias to create tuple> from indexed type template class T> - using MakeTuple = typename makeFromIndexedType::type; + using TupleOfSharedPtrConst = typename Detail::MultiDomainTupleSharedPtrConst::type; + + //\} }; } //end namespace Dumux diff --git a/test/multidomain/boundary/darcydarcy/1p_1p/main.cc b/test/multidomain/boundary/darcydarcy/1p_1p/main.cc index a3015814e858d524dd9bab7708c3cc5706b18378..f17ef17321489a5821986213f822e56aeee78d70 100644 --- a/test/multidomain/boundary/darcydarcy/1p_1p/main.cc +++ b/test/multidomain/boundary/darcydarcy/1p_1p/main.cc @@ -195,8 +195,8 @@ int main(int argc, char** argv) try // the mixed dimension type traits using Traits = MultiDomainTraits; - constexpr auto domain0Idx = Traits::template DomainIdx<0>(); - constexpr auto domain1Idx = Traits::template DomainIdx<1>(); + constexpr auto domain0Idx = Traits::template SubDomain<0>::Index(); + constexpr auto domain1Idx = Traits::template SubDomain<1>::Index(); // the coupling manager using CouplingManager = GetPropType; diff --git a/test/multidomain/boundary/darcydarcy/1p_2p/main.cc b/test/multidomain/boundary/darcydarcy/1p_2p/main.cc index 71884942c06a20c518e7e550b9491862c3ea96e7..ac0d68bb7f57fa496529608ccb6acdf3adfda5c1 100644 --- a/test/multidomain/boundary/darcydarcy/1p_2p/main.cc +++ b/test/multidomain/boundary/darcydarcy/1p_2p/main.cc @@ -181,8 +181,8 @@ int main(int argc, char** argv) try // the mixed dimension type traits using Traits = MultiDomainTraits; - constexpr auto domain0Idx = Traits::template DomainIdx<0>(); - constexpr auto domain1Idx = Traits::template DomainIdx<1>(); + constexpr auto domain0Idx = Traits::template SubDomain<0>::Index(); + constexpr auto domain1Idx = Traits::template SubDomain<1>::Index(); // the coupling manager using CouplingManager = GetPropType; diff --git a/test/multidomain/embedded/1d3d/1p2c_richards2c/main.cc b/test/multidomain/embedded/1d3d/1p2c_richards2c/main.cc index 14000499b587f370b0491c3f505cc93e9250f078..3fcce4bade8ad2d943aa8d8c237431c5734d4400 100644 --- a/test/multidomain/embedded/1d3d/1p2c_richards2c/main.cc +++ b/test/multidomain/embedded/1d3d/1p2c_richards2c/main.cc @@ -214,8 +214,8 @@ int main(int argc, char** argv) try // the mixed dimension type traits using Traits = MultiDomainTraits; - constexpr auto bulkIdx = Traits::template DomainIdx<0>(); - constexpr auto lowDimIdx = Traits::template DomainIdx<1>(); + constexpr auto bulkIdx = Traits::template SubDomain<0>::Index(); + constexpr auto lowDimIdx = Traits::template SubDomain<1>::Index(); // the coupling manager using CouplingManager = GetPropType; diff --git a/test/multidomain/embedded/1d3d/1p_1p/main.cc b/test/multidomain/embedded/1d3d/1p_1p/main.cc index 56126b6cf3f258166f1cecb0094d2ab1e8eaea50..bec98efaf1a106d424e4dcc55e0ac6189bcf1d3b 100644 --- a/test/multidomain/embedded/1d3d/1p_1p/main.cc +++ b/test/multidomain/embedded/1d3d/1p_1p/main.cc @@ -131,8 +131,8 @@ int main(int argc, char** argv) try // the mixed dimension type traits using Traits = MultiDomainTraits; - constexpr auto bulkIdx = Traits::template DomainIdx<0>(); - constexpr auto lowDimIdx = Traits::template DomainIdx<1>(); + constexpr auto bulkIdx = Traits::template SubDomain<0>::Index(); + constexpr auto lowDimIdx = Traits::template SubDomain<1>::Index(); // the coupling manager using CouplingManager = GetPropType; diff --git a/test/multidomain/embedded/1d3d/1p_richards/main.cc b/test/multidomain/embedded/1d3d/1p_richards/main.cc index 06aa6c6fb6502ee3cf0a943b2f5e397034e8f6f6..01dc0c0b8b8d8b9333df8265a84ae4a7960443c7 100644 --- a/test/multidomain/embedded/1d3d/1p_richards/main.cc +++ b/test/multidomain/embedded/1d3d/1p_richards/main.cc @@ -124,8 +124,8 @@ int main(int argc, char** argv) try // the mixed dimension type traits using Traits = MultiDomainTraits; - constexpr auto bulkIdx = Traits::template DomainIdx<0>(); - constexpr auto lowDimIdx = Traits::template DomainIdx<1>(); + constexpr auto bulkIdx = Traits::template SubDomain<0>::Index(); + constexpr auto lowDimIdx = Traits::template SubDomain<1>::Index(); // the coupling manager using CouplingManager = GetPropType; diff --git a/test/multidomain/embedded/2d3d/1p_1p/main.cc b/test/multidomain/embedded/2d3d/1p_1p/main.cc index 8ab13d94355541386e028aacc32d35db76457496..0fca900c47796e94983e3ba8e2c9f052fdc84abb 100644 --- a/test/multidomain/embedded/2d3d/1p_1p/main.cc +++ b/test/multidomain/embedded/2d3d/1p_1p/main.cc @@ -179,8 +179,8 @@ int main(int argc, char** argv) try // the mixed dimension type traits using Traits = MultiDomainTraits; - constexpr auto bulkIdx = Traits::template DomainIdx<0>(); - constexpr auto lowDimIdx = Traits::template DomainIdx<1>(); + constexpr auto bulkIdx = Traits::template SubDomain<0>::Index(); + constexpr auto lowDimIdx = Traits::template SubDomain<1>::Index(); // the coupling manager using CouplingManager = GetPropType; diff --git a/test/multidomain/facet/1p_1p/analytical/main.cc b/test/multidomain/facet/1p_1p/analytical/main.cc index 16afe1e2f5779e5a1a6ad6892fa2f95e2383d387..775d9ba5760d7e4eecea8116c56babf516921bd1 100644 --- a/test/multidomain/facet/1p_1p/analytical/main.cc +++ b/test/multidomain/facet/1p_1p/analytical/main.cc @@ -246,8 +246,8 @@ int main(int argc, char** argv) try using SolutionVector = typename MDTraits::SolutionVector; SolutionVector x; - static const auto bulkId = typename MDTraits::template DomainIdx<0>(); - static const auto lowDimId = typename MDTraits::template DomainIdx<1>(); + static const auto bulkId = typename MDTraits::template SubDomain<0>::Index(); + static const auto lowDimId = typename MDTraits::template SubDomain<1>::Index(); x[bulkId].resize(bulkFvGridGeometry->numDofs()); x[lowDimId].resize(lowDimFvGridGeometry->numDofs()); bulkProblem->applyInitialSolution(x[bulkId]); diff --git a/test/multidomain/facet/1p_1p/threedomain/main.cc b/test/multidomain/facet/1p_1p/threedomain/main.cc index b13c76e0ecac785a2d8f32a9a78a21df69664706..f24a0fc57e52bdcbe67bad48783ee8190db1dca1 100644 --- a/test/multidomain/facet/1p_1p/threedomain/main.cc +++ b/test/multidomain/facet/1p_1p/threedomain/main.cc @@ -145,12 +145,9 @@ int main(int argc, char** argv) try using SolutionVector = typename Traits::SolutionVector; SolutionVector x; - static const auto bulkId = Traits::template DomainIdx<0>(); - static const auto facetId = Traits::template DomainIdx<1>(); - static const auto edgeId = Traits::template DomainIdx<2>(); - x[bulkId].resize(bulkFvGridGeometry->numDofs()); - x[facetId].resize(facetFvGridGeometry->numDofs()); - x[edgeId].resize(edgeFvGridGeometry->numDofs()); + static const auto bulkId = Traits::template SubDomain<0>::Index(); + static const auto facetId = Traits::template SubDomain<1>::Index(); + static const auto edgeId = Traits::template SubDomain<2>::Index(); bulkProblem->applyInitialSolution(x[bulkId]); facetProblem->applyInitialSolution(x[facetId]); edgeProblem->applyInitialSolution(x[edgeId]); diff --git a/test/multidomain/facet/tracer_tracer/main.cc b/test/multidomain/facet/tracer_tracer/main.cc index 45fd9a9cb318c2805848f52003ed6484b77d20a4..357ee5c56a942e739fa44c87b10ee4556d5281fd 100644 --- a/test/multidomain/facet/tracer_tracer/main.cc +++ b/test/multidomain/facet/tracer_tracer/main.cc @@ -250,8 +250,8 @@ int main(int argc, char** argv) try using OnePMDTraits = typename OnePTestTraits::MDTraits; using SolutionVector = typename OnePMDTraits::SolutionVector; using JacobianMatrix = typename OnePMDTraits::JacobianMatrix; - static const auto bulkId = typename OnePMDTraits::template DomainIdx<0>(); - static const auto lowDimId = typename OnePMDTraits::template DomainIdx<1>(); + static const auto bulkId = typename OnePMDTraits::template SubDomain<0>::Index(); + static const auto lowDimId = typename OnePMDTraits::template SubDomain<1>::Index(); //////////////////////////////////////////////////////////// // run stationary, simgle-phase problem on this grid diff --git a/test/multidomain/poromechanics/el1p/main.cc b/test/multidomain/poromechanics/el1p/main.cc index 226478ac8dbf37c815f8157ecec452a7057c3227..50175c4a693d63bf75f4be51788130b4b3f56d8a 100644 --- a/test/multidomain/poromechanics/el1p/main.cc +++ b/test/multidomain/poromechanics/el1p/main.cc @@ -130,8 +130,8 @@ int main(int argc, char** argv) try using SolutionVector = typename Traits::SolutionVector; SolutionVector x; - static const auto onePId = Traits::template DomainIdx<0>(); - static const auto poroMechId = Traits::template DomainIdx<1>(); + static const auto onePId = Traits::template SubDomain<0>::Index(); + static const auto poroMechId = Traits::template SubDomain<1>::Index(); x[onePId].resize(onePFvGridGeometry->numDofs()); x[poroMechId].resize(poroMechFvGridGeometry->numDofs()); onePProblem->applyInitialSolution(x[onePId]); diff --git a/test/multidomain/poromechanics/el2p/main.cc b/test/multidomain/poromechanics/el2p/main.cc index 65a170a88a420d6e41bef56b9857dff995658153..f833946d76c4cb85d6acd5ff2718fd7fb5eeb604 100644 --- a/test/multidomain/poromechanics/el2p/main.cc +++ b/test/multidomain/poromechanics/el2p/main.cc @@ -132,8 +132,8 @@ int main(int argc, char** argv) try using SolutionVector = typename Traits::SolutionVector; SolutionVector x; - static const auto twoPId = Traits::template DomainIdx<0>(); - static const auto poroMechId = Traits::template DomainIdx<1>(); + static const auto twoPId = Traits::template SubDomain<0>::Index(); + static const auto poroMechId = Traits::template SubDomain<1>::Index(); x[twoPId].resize(twoPFvGridGeometry->numDofs()); x[poroMechId].resize(poroMechFvGridGeometry->numDofs()); twoPProblem->applyInitialSolution(x[twoPId]);