diff --git a/ProcessLib/LIE/Common/MeshUtils.cpp b/ProcessLib/LIE/Common/MeshUtils.cpp index 9fa1349ee32cc77ac2cbfb0e862745379b3be56a..0e13861aaeab0eabc9d8f0e65e76bc4b2347033e 100644 --- a/ProcessLib/LIE/Common/MeshUtils.cpp +++ b/ProcessLib/LIE/Common/MeshUtils.cpp @@ -84,8 +84,8 @@ void getFractureMatrixDataInMesh( vec_matrix_elements.size(), all_fracture_elements.size()); // get fracture material IDs - auto opt_material_ids( - mesh.getProperties().getPropertyVector<int>("MaterialIDs")); + auto opt_material_ids(mesh.getProperties().getPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1)); for (MeshLib::Element* e : all_fracture_elements) vec_fracture_mat_IDs.push_back((*opt_material_ids)[e->getID()]); BaseLib::makeVectorUnique(vec_fracture_mat_IDs); diff --git a/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcess.cpp b/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcess.cpp index d1c64ca41efcb13dac072150771bb90fb0dd9ffe..48f9b926593c22f8f67dbf17ec7cccdb8f51ab7f 100644 --- a/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcess.cpp +++ b/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcess.cpp @@ -318,8 +318,8 @@ void HydroMechanicsProcess<GlobalDim>::initializeConcreteProcess( const_cast<MeshLib::Mesh&>(mesh), "aperture", MeshLib::MeshItemType::Cell, 1); mesh_prop_b->resize(mesh.getNumberOfElements()); - auto mesh_prop_matid = - mesh.getProperties().getPropertyVector<int>("MaterialIDs"); + auto mesh_prop_matid = mesh.getProperties().getPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1); auto frac = _process_data.fracture_property.get(); for (MeshLib::Element const* e : _mesh.getElements()) { diff --git a/ProcessLib/LiquidFlow/CreateLiquidFlowProcess.cpp b/ProcessLib/LiquidFlow/CreateLiquidFlowProcess.cpp index 51a53a7ddb19c5d3602ff2e9b6d6a393a2a168a1..f8fc4511dc3923cc35a2f3b2e4b2e6f42516462c 100644 --- a/ProcessLib/LiquidFlow/CreateLiquidFlowProcess.cpp +++ b/ProcessLib/LiquidFlow/CreateLiquidFlowProcess.cpp @@ -91,12 +91,13 @@ std::unique_ptr<Process> createLiquidFlowProcess( //! \ogs_file_param{prj__processes__process__LIQUID_FLOW__material_property} auto const& mat_config = config.getConfigSubtree("material_property"); - if (mesh.getProperties().existsPropertyVector<int>("MaterialIDs")) + if (mesh.getProperties().existsPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1)) { INFO("The liquid flow is in heterogeneous porous media."); const bool has_material_ids = true; - auto const& mat_ids = - mesh.getProperties().getPropertyVector<int>("MaterialIDs"); + auto const& mat_ids = mesh.getProperties().getPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1); return std::unique_ptr<Process>{new LiquidFlowProcess{ mesh, std::move(jacobian_assembler), parameters, integration_order, std::move(process_variables), std::move(secondary_variables), diff --git a/ProcessLib/RichardsFlow/CreateRichardsFlowProcess.cpp b/ProcessLib/RichardsFlow/CreateRichardsFlowProcess.cpp index f0651c3825b8d45236815889cd977936a64e0279..ab9694e8661834adef9fe385a57a5e7b055c3729 100644 --- a/ProcessLib/RichardsFlow/CreateRichardsFlowProcess.cpp +++ b/ProcessLib/RichardsFlow/CreateRichardsFlowProcess.cpp @@ -80,8 +80,12 @@ std::unique_ptr<Process> createRichardsFlowProcess( //! \ogs_file_param{prj__processes__process__RICHARDS_FLOW__material_property} auto const& mat_config = config.getConfigSubtree("material_property"); - auto const material_ids = - mesh.getProperties().getPropertyVector<int>("MaterialIDs"); + auto const* material_ids = + mesh.getProperties().existsPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1) + ? mesh.getProperties().getPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1) + : nullptr; if (material_ids != nullptr) { INFO("The Richards flow is in heterogeneous porous media."); diff --git a/ProcessLib/SurfaceFlux/SurfaceFlux.cpp b/ProcessLib/SurfaceFlux/SurfaceFlux.cpp index 35996b53126a74264fce81ae559412354c8314f3..a5735a825e81993585e2010a24ba7f13add4cf4b 100644 --- a/ProcessLib/SurfaceFlux/SurfaceFlux.cpp +++ b/ProcessLib/SurfaceFlux/SurfaceFlux.cpp @@ -40,10 +40,10 @@ SurfaceFlux::SurfaceFlux( auto const bulk_element_ids = boundary_mesh.getProperties().template getPropertyVector<std::size_t>( - "bulk_element_ids"); + "bulk_element_ids", MeshLib::MeshItemType::Cell, 1); auto const bulk_face_ids = boundary_mesh.getProperties().template getPropertyVector<std::size_t>( - "bulk_face_ids"); + "bulk_face_ids", MeshLib::MeshItemType::Cell, 1); ProcessLib::createLocalAssemblers<SurfaceFluxLocalAssembler>( boundary_mesh.getDimension() + 1, // or bulk_mesh.getDimension()? diff --git a/ProcessLib/TwoPhaseFlowWithPP/CreateTwoPhaseFlowWithPPProcess.cpp b/ProcessLib/TwoPhaseFlowWithPP/CreateTwoPhaseFlowWithPPProcess.cpp index b210b4c7352516de93c4cf76940c7d98933710ea..e46d4d4d76e63058a9b0ec78e9285be558a3a5a5 100644 --- a/ProcessLib/TwoPhaseFlowWithPP/CreateTwoPhaseFlowWithPPProcess.cpp +++ b/ProcessLib/TwoPhaseFlowWithPP/CreateTwoPhaseFlowWithPPProcess.cpp @@ -79,11 +79,12 @@ std::unique_ptr<Process> createTwoPhaseFlowWithPPProcess( auto const& mat_config = config.getConfigSubtree("material_property"); boost::optional<MeshLib::PropertyVector<int> const&> material_ids; - if (mesh.getProperties().existsPropertyVector<int>("MaterialIDs")) + if (mesh.getProperties().existsPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1)) { INFO("The twophase flow is in heterogeneous porous media."); - material_ids = - *mesh.getProperties().getPropertyVector<int>("MaterialIDs"); + material_ids = *mesh.getProperties().getPropertyVector<int>( + "MaterialIDs", MeshLib::MeshItemType::Cell, 1); } else {