38std::unique_ptr<Process> createSmallDeformationProcess(
39 std::string
const& name,
41 std::unique_ptr<ProcessLib::AbstractJacobianAssembler>&& jacobian_assembler,
42 std::vector<ProcessVariable>
const& variables,
43 std::vector<std::unique_ptr<ParameterLib::ParameterBase>>
const& parameters,
44 std::optional<ParameterLib::CoordinateSystem>
const&
45 local_coordinate_system,
46 unsigned const integration_order,
48 std::map<
int, std::shared_ptr<MaterialPropertyLib::Medium>>
const& media)
52 DBUG(
"Create SmallDeformationProcess.");
65 DBUG(
"Associate displacement with process variable '{:s}'.",
66 per_process_variables.back().get().getName());
68 if (per_process_variables.back().get().getNumberOfGlobalComponents() !=
72 "Number of components of the process variable '{:s}' is different "
73 "from the displacement dimension: got {:d}, expected {:d}",
74 per_process_variables.back().get().getName(),
75 per_process_variables.back().get().getNumberOfGlobalComponents(),
78 std::vector<std::vector<std::reference_wrapper<ProcessVariable>>>
80 process_variables.push_back(std::move(per_process_variables));
83 auto solid_constitutive_relations =
85 parameters, local_coordinate_system, materialIDs(mesh), config);
91 "The <solid_density> tag has been removed. Use <media> definitions "
92 "to specify solid's density.");
96 Eigen::Matrix<double, DisplacementDim, 1> specific_body_force;
98 std::vector<double>
const b =
101 "specific_body_force");
102 if (b.size() != DisplacementDim)
105 "The size of the specific body force vector does not match the "
106 "displacement dimension. Vector size is {:d}, displacement "
108 b.size(), DisplacementDim);
111 std::copy_n(b.data(), b.size(), specific_body_force.data());
120 "Check the media properties of SmallDeformation process "
122 checkMPLProperties(media);
123 DBUG(
"Media properties verified.");
129 config,
"reference_temperature", parameters, 1, &mesh);
130 if (reference_temperature)
132 DBUG(
"Use '{:s}' as reference temperature parameter.",
133 (*reference_temperature).name);
139 config,
"initial_stress", parameters,
146 std::move(media_map),
147 std::move(solid_constitutive_relations),
150 reference_temperature,
157 return std::make_unique<SmallDeformationProcess<DisplacementDim>>(
158 std::move(name), mesh, std::move(jacobian_assembler), parameters,
159 integration_order, std::move(process_variables),
160 std::move(process_data), std::move(secondary_variables));
std::map< int, std::shared_ptr< MaterialLib::Solids::MechanicsBase< DisplacementDim > > > createConstitutiveRelations(std::vector< std::unique_ptr< ParameterLib::ParameterBase > > const ¶meters, std::optional< ParameterLib::CoordinateSystem > const &local_coordinate_system, MeshLib::PropertyVector< int > const *const material_ids, BaseLib::ConfigTree const &config)
Parameter< ParameterDataType > * findOptionalTagParameter(BaseLib::ConfigTree const &process_config, std::string const &tag, std::vector< std::unique_ptr< ParameterBase > > const ¶meters, int const num_components, MeshLib::Mesh const *const mesh=nullptr)