Skip to content
Snippets Groups Projects
Commit 4e5c3329 authored by renchao.lu's avatar renchao.lu
Browse files

[PL/CT] Remove mapping process id to component name.

parent 0396d73f
No related branches found
No related tags found
No related merge requests found
...@@ -31,15 +31,12 @@ ComponentTransportProcess::ComponentTransportProcess( ...@@ -31,15 +31,12 @@ ComponentTransportProcess::ComponentTransportProcess(
ComponentTransportProcessData&& process_data, ComponentTransportProcessData&& process_data,
SecondaryVariableCollection&& secondary_variables, SecondaryVariableCollection&& secondary_variables,
bool const use_monolithic_scheme, bool const use_monolithic_scheme,
std::unique_ptr<ProcessLib::SurfaceFluxData>&& surfaceflux, std::unique_ptr<ProcessLib::SurfaceFluxData>&& surfaceflux)
std::vector<std::pair<int, std::string>>&& process_id_to_component_name_map)
: Process(std::move(name), mesh, std::move(jacobian_assembler), parameters, : Process(std::move(name), mesh, std::move(jacobian_assembler), parameters,
integration_order, std::move(process_variables), integration_order, std::move(process_variables),
std::move(secondary_variables), use_monolithic_scheme), std::move(secondary_variables), use_monolithic_scheme),
_process_data(std::move(process_data)), _process_data(std::move(process_data)),
_surfaceflux(std::move(surfaceflux)), _surfaceflux(std::move(surfaceflux))
_process_id_to_component_name_map(
std::move(process_id_to_component_name_map))
{ {
} }
......
...@@ -102,9 +102,7 @@ public: ...@@ -102,9 +102,7 @@ public:
ComponentTransportProcessData&& process_data, ComponentTransportProcessData&& process_data,
SecondaryVariableCollection&& secondary_variables, SecondaryVariableCollection&& secondary_variables,
bool const use_monolithic_scheme, bool const use_monolithic_scheme,
std::unique_ptr<ProcessLib::SurfaceFluxData>&& surfaceflux, std::unique_ptr<ProcessLib::SurfaceFluxData>&& surfaceflux);
std::vector<std::pair<int, std::string>>&&
process_id_to_component_name_map);
//! \name ODESystem interface //! \name ODESystem interface
//! @{ //! @{
...@@ -116,12 +114,6 @@ public: ...@@ -116,12 +114,6 @@ public:
MathLib::Point3d const& p, double const t, MathLib::Point3d const& p, double const t,
std::vector<GlobalVector*> const& x) const override; std::vector<GlobalVector*> const& x) const override;
std::vector<std::pair<int, std::string>> const&
getProcessIDToComponentNameMap() const
{
return _process_id_to_component_name_map;
}
void setCoupledTermForTheStaggeredSchemeToLocalAssemblers( void setCoupledTermForTheStaggeredSchemeToLocalAssemblers(
int const process_id) override; int const process_id) override;
...@@ -164,9 +156,6 @@ private: ...@@ -164,9 +156,6 @@ private:
std::vector<std::unique_ptr<GlobalVector>> _xs_previous_timestep; std::vector<std::unique_ptr<GlobalVector>> _xs_previous_timestep;
std::unique_ptr<ProcessLib::SurfaceFluxData> _surfaceflux; std::unique_ptr<ProcessLib::SurfaceFluxData> _surfaceflux;
std::vector<std::pair<int, std::string>> const
_process_id_to_component_name_map;
}; };
} // namespace ComponentTransport } // namespace ComponentTransport
......
...@@ -130,7 +130,6 @@ std::unique_ptr<Process> createComponentTransportProcess( ...@@ -130,7 +130,6 @@ std::unique_ptr<Process> createComponentTransportProcess(
it->get().getNumberOfComponents()); it->get().getNumberOfComponents());
} }
std::vector<std::pair<int, std::string>> process_id_to_component_name_map;
// Allocate the collected process variables into a two-dimensional vector, // Allocate the collected process variables into a two-dimensional vector,
// depending on what scheme is adopted // depending on what scheme is adopted
if (use_monolithic_scheme) // monolithic scheme. if (use_monolithic_scheme) // monolithic scheme.
...@@ -147,15 +146,7 @@ std::unique_ptr<Process> createComponentTransportProcess( ...@@ -147,15 +146,7 @@ std::unique_ptr<Process> createComponentTransportProcess(
per_process_variable.emplace_back(pv); per_process_variable.emplace_back(pv);
process_variables.push_back(std::move(per_process_variable)); process_variables.push_back(std::move(per_process_variable));
} }
auto variable_id = 0;
for (unsigned process_id = 1; process_id < process_variables.size();
process_id++)
{ {
auto const& transport_process_variable =
process_variables[process_id][variable_id].get().getName();
process_id_to_component_name_map.emplace_back(
process_id, transport_process_variable);
} }
} }
...@@ -214,8 +205,7 @@ std::unique_ptr<Process> createComponentTransportProcess( ...@@ -214,8 +205,7 @@ std::unique_ptr<Process> createComponentTransportProcess(
std::move(name), mesh, std::move(jacobian_assembler), parameters, std::move(name), mesh, std::move(jacobian_assembler), parameters,
integration_order, std::move(process_variables), integration_order, std::move(process_variables),
std::move(process_data), std::move(secondary_variables), std::move(process_data), std::move(secondary_variables),
use_monolithic_scheme, std::move(surfaceflux), use_monolithic_scheme, std::move(surfaceflux));
std::move(process_id_to_component_name_map));
} }
} // namespace ComponentTransport } // namespace ComponentTransport
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment