Loading [MathJax]/extensions/MathZoom.js
OGS
HMPhaseFieldFEM-impl.h
Go to the documentation of this file.
1
11#pragma once
12
13#include <Eigen/Core>
14#include <Eigen/Eigenvalues>
15#include <utility>
16
25
26namespace ProcessLib
27{
28namespace HMPhaseField
29{
30template <typename ShapeFunction, int DisplacementDim>
32 assembleWithJacobianForStaggeredScheme(double const t, double const dt,
33 Eigen::VectorXd const& local_x,
34 Eigen::VectorXd const& local_x_prev,
35 int const process_id,
36 std::vector<double>& local_b_data,
37 std::vector<double>& local_Jac_data)
38{
39 // For the equations with phase field.
40 if (process_id == _process_data._phasefield_process_id)
41 {
42 assembleWithJacobianPhaseFieldEquations(t, dt, local_x, local_b_data,
43 local_Jac_data);
44 return;
45 }
46
47 // For the equations for hydro
48 if (process_id == _process_data._hydro_process_id)
49 {
50 assembleWithJacobianHydroEquations(t, dt, local_x, local_x_prev,
51 local_b_data, local_Jac_data);
52 return;
53 }
54
55 // For the equations with deformation
56 assembleWithJacobianForDeformationEquations(t, dt, local_x, local_b_data,
57 local_Jac_data);
58}
59
60template <typename ShapeFunction, int DisplacementDim>
63 double const t, double const dt, Eigen::VectorXd const& local_x,
64 std::vector<double>& local_b_data, std::vector<double>& local_Jac_data)
65{
66 auto const d = local_x.template segment<phasefield_size>(phasefield_index);
67 auto const u =
68 local_x.template segment<displacement_size>(displacement_index);
69 auto const p = local_x.template segment<pressure_size>(pressure_index);
70
72 local_Jac_data, displacement_size, displacement_size);
73
75 local_b_data, displacement_size);
76
78 x_position.setElementID(_element.getID());
79
80 auto const& medium = _process_data.media_map.getMedium(_element.getID());
81 auto const& solid = medium->phase("Solid");
82 auto const& fluid = fluidPhase(*medium);
84
85 double const k = _process_data.residual_stiffness(t, x_position)[0];
86 double const ls = _process_data.crack_length_scale(t, x_position)[0];
87
88 auto const& identity2 = Invariants::identity2;
89
90 int const n_integration_points = _integration_method.getNumberOfPoints();
91 for (int ip = 0; ip < n_integration_points; ip++)
92 {
93 auto const& w = _ip_data[ip].integration_weight;
94 auto const& N = _ip_data[ip].N;
95 auto const& dNdx = _ip_data[ip].dNdx;
96 double const d_ip = N.dot(d);
97 double const p_ip = N.dot(p);
98
99 auto const x_coord =
101 _element, N);
102
103 auto const& B =
104 LinearBMatrix::computeBMatrix<DisplacementDim,
105 ShapeFunction::NPOINTS,
107 dNdx, N, x_coord, _is_axially_symmetric);
108
109 auto& eps = _ip_data[ip].eps;
110 eps.noalias() = B * u;
111
112 double const degradation =
113 _process_data.degradation_derivative->degradation(d_ip, k, ls);
114 _ip_data[ip].updateConstitutiveRelation(
115 t, x_position, dt, u, degradation,
116 _process_data.energy_split_model);
117
118 auto const& sigma = _ip_data[ip].sigma;
119 auto const& D = _ip_data[ip].D;
120
121 auto& biot_coefficient = _ip_data[ip].biot_coefficient;
122 auto& biot_modulus_inv = _ip_data[ip].biot_modulus_inv;
123 auto const& fracture_enhanced_porosity =
124 _ip_data[ip].fracture_enhanced_porosity;
125
126 // Update the effective bulk modulus
127 auto const& P_sph = Invariants::spherical_projection;
128 auto const D_sph = P_sph * D * identity2;
129 double const bulk_modulus_eff = Invariants::trace(D_sph) / 9.;
130
131 auto const& solid_material =
133 _process_data.solid_materials, _process_data.material_ids,
134 _element.getID());
135 auto const bulk_modulus = solid_material.getBulkModulus(t, x_position);
136 auto const alpha_0 =
137 solid.property(MPL::PropertyType::biot_coefficient)
138 .template value<double>(vars, x_position, t, dt);
139 auto const porosity_0 =
140 medium->property(MPL::PropertyType::porosity)
141 .template value<double>(vars, x_position, t, dt);
142 double const bulk_modulus_degradation = bulk_modulus_eff / bulk_modulus;
143
144 // Update Biot's coefficient
145 biot_coefficient = 1. - bulk_modulus_degradation * (1. - alpha_0);
146
147 // The reference porosity
148 auto const porosity_reference = porosity_0 + fracture_enhanced_porosity;
149
150 // Update Biot's modulus
151 biot_modulus_inv = bulk_modulus_degradation * (alpha_0 - porosity_0) *
152 (1. - alpha_0) / bulk_modulus;
153
154 auto const rho_sr =
155 solid.property(MPL::PropertyType::density)
156 .template value<double>(vars, x_position, t, dt);
157 auto const rho_fr =
158 fluid.property(MPL::PropertyType::density)
159 .template value<double>(vars, x_position, t, dt);
160
161 auto const rho =
162 rho_sr * (1. - porosity_reference) + porosity_reference * rho_fr;
163 auto const& b = _process_data.specific_body_force;
164
165 local_rhs.noalias() -=
166 (B.transpose() * (sigma - biot_coefficient * p_ip * identity2) -
167 N_u_op(N).transpose() * rho * b) *
168 w;
169 local_Jac.noalias() += B.transpose() * D * B * w;
170 }
171}
172
173template <typename ShapeFunction, int DisplacementDim>
175 assembleWithJacobianHydroEquations(double const t, double const dt,
176 Eigen::VectorXd const& local_x,
177 Eigen::VectorXd const& local_x_prev,
178 std::vector<double>& local_b_data,
179 std::vector<double>& local_Jac_data)
180{
181 auto const d = local_x.template segment<phasefield_size>(phasefield_index);
182
183 auto const p = local_x.template segment<pressure_size>(pressure_index);
184 auto const p_prev =
185 local_x_prev.template segment<pressure_size>(pressure_index);
186
188 local_Jac_data, pressure_size, pressure_size);
189
190 auto local_rhs = MathLib::createZeroedVector<PressureVector>(local_b_data,
191 pressure_size);
192
194 ShapeMatricesType::NodalMatrixType::Zero(pressure_size, pressure_size);
195
196 typename ShapeMatricesType::NodalMatrixType laplace =
197 ShapeMatricesType::NodalMatrixType::Zero(pressure_size, pressure_size);
198
199 typename ShapeMatricesType::NodalMatrixType stablizing =
200 ShapeMatricesType::NodalMatrixType::Zero(pressure_size, pressure_size);
201
203 x_position.setElementID(_element.getID());
204
205 auto const& medium = _process_data.media_map.getMedium(_element.getID());
206 auto const& fluid = fluidPhase(*medium);
208
209 auto const& P_sph = Invariants::spherical_projection;
210 auto const& P_dev = Invariants::deviatoric_projection;
211 auto const& identity2 = Invariants::identity2;
212 auto const& ones2 = Invariants::ones2;
213
214 double const k = _process_data.residual_stiffness(t, x_position)[0];
215 double const ls = _process_data.crack_length_scale(t, x_position)[0];
216 double const width = (*_process_data.width)[_element.getID()];
217 double const fracture_threshold = _process_data.fracture_threshold;
218 double const fracture_permeability_parameter =
219 _process_data.fracture_permeability_parameter;
220 double const fixed_stress_stabilization_parameter =
221 _process_data.fixed_stress_stabilization_parameter;
222 double const spatial_stabilization_parameter =
223 _process_data.spatial_stabilization_parameter;
224 auto const he =
225 ls / _process_data.diffused_range_parameter; // element size
226
227 int const n_integration_points = _integration_method.getNumberOfPoints();
228 for (int ip = 0; ip < n_integration_points; ip++)
229 {
230 auto const& w = _ip_data[ip].integration_weight;
231 auto const& N = _ip_data[ip].N;
232 auto const& dNdx = _ip_data[ip].dNdx;
233 double const d_ip = N.dot(d);
234
235 auto const rho_fr =
236 fluid.property(MPL::PropertyType::density)
237 .template value<double>(vars, x_position, t, dt);
238 double const cf = _process_data.fluid_compressibility;
239 auto const Km = medium->property(MPL::PropertyType::permeability)
240 .template value<double>(vars, x_position, t, dt);
241 auto const K = MPL::formEigenTensor<DisplacementDim>(Km);
242 auto const mu = fluid.property(MPL::PropertyType::viscosity)
243 .template value<double>(vars, x_position, t, dt);
244
245 auto const vol_strain = Invariants::trace(_ip_data[ip].eps);
246 auto const vol_strain_prev = Invariants::trace(_ip_data[ip].eps_prev);
247 auto const& biot_coefficient = _ip_data[ip].biot_coefficient;
248 auto const& biot_modulus_inv = _ip_data[ip].biot_modulus_inv;
249 auto const& fracture_enhanced_porosity =
250 _ip_data[ip].fracture_enhanced_porosity;
251
252 // The reference porosity
253 auto const porosity_0 =
254 medium->property(MPL::PropertyType::porosity)
255 .template value<double>(vars, x_position, t, dt);
256 auto const porosity_reference = porosity_0 + fracture_enhanced_porosity;
257
258 double const dv_dt = (vol_strain - vol_strain_prev) / dt;
259
260 // The degraded shear modulus
261 auto const& D = _ip_data[ip].D;
262 auto const D_sph = P_sph * D * identity2;
263 auto const D_dev = P_dev * D * (ones2 - identity2) / std::sqrt(2.);
264 auto const degraded_shear_modulus =
265 Invariants::FrobeniusNorm(D_dev) / 2.;
266 auto const degraded_bulk_modulus = Invariants::trace(D_sph) / 9.;
267
268 double const residual_bulk_modulus = [&]
269 {
270 if ((*_process_data.ele_d)[_element.getID()] <
271 _process_data.fracture_threshold)
272 {
273 // The residual bulk modulus in the fractured element
274 double const degradation_threshold =
275 _process_data.degradation_derivative->degradation(
276 fracture_threshold, k, ls);
277 auto const& D_threshold =
278 degradation_threshold * _ip_data[ip].C_tensile +
279 _ip_data[ip].C_compressive;
280 auto const D_sph_threshold = P_sph * D_threshold * identity2;
281
282 return Invariants::trace(D_sph_threshold) / 9.;
283 }
284 return degraded_bulk_modulus;
285 }();
286
287 double const modulus_rm = fixed_stress_stabilization_parameter *
288 biot_coefficient * biot_coefficient /
289 residual_bulk_modulus;
290
291 double const stablization_spatial =
292 spatial_stabilization_parameter * 0.25 * he * he /
293 (degraded_bulk_modulus + 4. / 3. * degraded_shear_modulus);
294 stablizing.noalias() +=
295 dNdx.transpose() * stablization_spatial * dNdx * w;
296
297 mass.noalias() +=
298 (biot_modulus_inv + cf * porosity_reference + modulus_rm) *
299 N.transpose() * N * w;
300
301 auto const K_over_mu = K / mu;
302 laplace.noalias() += dNdx.transpose() * K_over_mu * dNdx * w;
303 auto const& b = _process_data.specific_body_force;
304
305 // bodyforce-driven Darcy flow
306 local_rhs.noalias() += dNdx.transpose() * rho_fr * K_over_mu * b * w;
307
308 local_rhs.noalias() -= (biot_coefficient * dv_dt -
309 modulus_rm * _ip_data[ip].coupling_pressure) *
310 N.transpose() * w;
311
312 if ((*_process_data.ele_d)[_element.getID()] <
313 _process_data.irreversible_threshold)
314 {
315 // Fracture-enhanced permeability
316 auto const& normal_ip = _ip_data[ip].normal_ip;
317 auto const Kf =
318 std::pow(1. - d_ip, fracture_permeability_parameter) * width *
319 width * width / he / 12.0 *
320 (Eigen::Matrix<double, DisplacementDim,
321 DisplacementDim>::Identity() -
322 normal_ip * normal_ip.transpose());
323 laplace.noalias() += dNdx.transpose() * Kf / mu * dNdx * w;
324 }
325 }
326 local_Jac.noalias() = laplace + mass / dt + stablizing / dt;
327
328 local_rhs.noalias() -=
329 laplace * p + mass * (p - p_prev) / dt + stablizing * (p - p_prev) / dt;
330}
331
332template <typename ShapeFunction, int DisplacementDim>
334 assembleWithJacobianPhaseFieldEquations(double const t, double const dt,
335 Eigen::VectorXd const& local_x,
336 std::vector<double>& local_b_data,
337 std::vector<double>& local_Jac_data)
338{
339 auto const d = local_x.template segment<phasefield_size>(phasefield_index);
340 auto const p = local_x.template segment<pressure_size>(pressure_index);
341 auto const u =
342 local_x.template segment<displacement_size>(displacement_index);
343
345 local_Jac_data, phasefield_size, phasefield_size);
347 local_b_data, phasefield_size);
348
350 x_position.setElementID(_element.getID());
351
352 auto const& solid_material =
354 _process_data.solid_materials, _process_data.material_ids,
355 _element.getID());
356
357 auto const bulk_modulus = solid_material.getBulkModulus(t, x_position);
358 auto const& medium = _process_data.media_map.getMedium(_element.getID());
359 auto const& solid = medium->phase("Solid");
361
362 double const k = _process_data.residual_stiffness(t, x_position)[0];
363 double const ls = _process_data.crack_length_scale(t, x_position)[0];
364 double const gc = _process_data.crack_resistance(t, x_position)[0];
365
366 auto const& identity2 = Invariants::identity2;
367
368 int const n_integration_points = _integration_method.getNumberOfPoints();
369 for (int ip = 0; ip < n_integration_points; ip++)
370 {
371 auto const& w = _ip_data[ip].integration_weight;
372 auto const& N = _ip_data[ip].N;
373 auto const& dNdx = _ip_data[ip].dNdx;
374
375 double const d_ip = N.dot(d);
376 double const p_ip = N.dot(p);
377 double const degradation =
378 _process_data.degradation_derivative->degradation(d_ip, k, ls);
379 double const degradation_df1 =
380 _process_data.degradation_derivative->degradationDf1(d_ip, k, ls);
381 double const degradation_df2 =
382 _process_data.degradation_derivative->degradationDf2(d_ip, k, ls);
383
384 _ip_data[ip].updateConstitutiveRelation(
385 t, x_position, dt, u, degradation,
386 _process_data.energy_split_model);
387
388 auto& biot_coefficient = _ip_data[ip].biot_coefficient;
389 auto& biot_modulus_inv = _ip_data[ip].biot_modulus_inv;
390
391 auto const alpha_0 =
392 solid.property(MPL::PropertyType::biot_coefficient)
393 .template value<double>(vars, x_position, t, dt);
394 auto const porosity_0 =
395 medium->property(MPL::PropertyType::porosity)
396 .template value<double>(vars, x_position, t, dt);
397
398 auto const& D = _ip_data[ip].D;
399 auto const& P_sph = Invariants::spherical_projection;
400 auto const D_sph = P_sph * D * identity2;
401 double const bulk_modulus_eff = Invariants::trace(D_sph) / 9.;
402 double const bulk_modulus_degradation = bulk_modulus_eff / bulk_modulus;
403
404 // Update Biot's coefficient
405 biot_coefficient = 1. - bulk_modulus_degradation * (1. - alpha_0);
406
407 // Update Biot's modulus
408 biot_modulus_inv = bulk_modulus_degradation * (alpha_0 - porosity_0) *
409 (1. - alpha_0) / bulk_modulus;
410
411 auto const& strain_energy_tensile = _ip_data[ip].strain_energy_tensile;
412 auto const& C_tensile = _ip_data[ip].C_tensile;
413 auto const C_tensile_sph = P_sph * C_tensile * identity2;
414 double const bulk_modulus_plus = Invariants::trace(C_tensile_sph) / 9.;
415
416 auto const driven_energy =
417 N.transpose() *
418 (strain_energy_tensile + p_ip * p_ip / 2. * bulk_modulus_plus /
419 bulk_modulus * (alpha_0 - porosity_0) *
420 (1. - alpha_0) / bulk_modulus) *
421 w;
422
423 local_Jac.noalias() += driven_energy * N * degradation_df2;
424
425 local_rhs.noalias() -= driven_energy * degradation_df1;
426
427 calculateCrackLocalJacobianAndResidual<
428 decltype(dNdx), decltype(N), decltype(w), decltype(d),
429 decltype(local_Jac), decltype(local_rhs)>(
430 dNdx, N, w, d, local_Jac, local_rhs, gc, ls,
431 _process_data.phasefield_model);
432 }
433}
434
435template <typename ShapeFunction, int DisplacementDim>
437 postNonLinearSolverConcrete(Eigen::VectorXd const& local_x,
438 Eigen::VectorXd const& local_x_prev,
439 double const /*t*/, double const dt,
440 int const /*process_id*/)
441{
442 int const n_integration_points = _integration_method.getNumberOfPoints();
443 auto const p = local_x.template segment<pressure_size>(pressure_index);
444 auto const p_prev =
445 local_x_prev.template segment<pressure_size>(pressure_index);
446
447 for (int ip = 0; ip < n_integration_points; ip++)
448 {
449 auto const& N = _ip_data[ip].N;
450 _ip_data[ip].coupling_pressure = N.dot(p - p_prev) / dt;
451 }
452}
453
454template <typename ShapeFunction, int DisplacementDim>
457 std::size_t mesh_item_id,
458 std::vector<NumLib::LocalToGlobalIndexMap const*> const& dof_tables,
459 std::vector<GlobalVector*> const& x, double const t,
460 double const /*dt*/)
461{
462 std::vector<std::vector<GlobalIndexType>> indices_of_processes;
463 indices_of_processes.reserve(dof_tables.size());
464 std::transform(dof_tables.begin(), dof_tables.end(),
465 std::back_inserter(indices_of_processes),
466 [&](auto const dof_table)
467 { return NumLib::getIndices(mesh_item_id, *dof_table); });
468
469 auto local_coupled_xs = getCoupledLocalSolutions(x, indices_of_processes);
470 assert(local_coupled_xs.size() ==
471 phasefield_size + displacement_size + pressure_size);
472
473 auto const d = Eigen::Map<PhaseFieldVector const>(
474 &local_coupled_xs[phasefield_index], phasefield_size);
475
477 x_position.setElementID(_element.getID());
478
479 double const ele_d = std::clamp(d.sum() / d.size(), 0.0, 1.0);
480 (*_process_data.ele_d)[_element.getID()] = ele_d;
481
482 if ((*_process_data.ele_d)[_element.getID()] <
483 _process_data.irreversible_threshold)
484 {
485 double const width_init = _process_data.width_init(t, x_position)[0];
486 double const k = _process_data.residual_stiffness(t, x_position)[0];
487 double const ls = _process_data.crack_length_scale(t, x_position)[0];
488 double const he = ls / _process_data.diffused_range_parameter;
489
490 int const n_integration_points =
491 _integration_method.getNumberOfPoints();
492 double width = 0.0;
493 for (int ip = 0; ip < n_integration_points; ip++)
494 {
495 auto eps_tensor =
497 Eigen::EigenSolver<decltype(eps_tensor)> eigen_solver(eps_tensor);
498 Eigen::MatrixXf::Index maxIndex;
499 double const max_principal_strain =
500 eigen_solver.eigenvalues().real().maxCoeff(&maxIndex);
501 auto const max_eigen_vector =
502 eigen_solver.eigenvectors().real().col(maxIndex);
503
504 // Fracture aperture estimation
505 auto& width_ip = _ip_data[ip].width_ip;
506 width_ip = max_principal_strain * he;
507 width_ip = width_ip < width_init ? width_init : width_ip;
508 width += width_ip;
509
510 // Fracture direction estimation
511 auto& normal_ip = _ip_data[ip].normal_ip;
512 if (std::abs(max_principal_strain) > k)
513 {
514 for (int i = 0; i < DisplacementDim; i++)
515 {
516 normal_ip[i] = max_eigen_vector[i];
517 }
518 }
519
520 // Fracture enhanced porosity
521 auto& fracture_enhanced_porosity =
522 _ip_data[ip].fracture_enhanced_porosity;
523 fracture_enhanced_porosity = width_ip / he;
524 }
525
526 // Update aperture for the fractured element
527 (*_process_data.width)[_element.getID()] = width / n_integration_points;
528 }
529}
530
531template <typename ShapeFunction, int DisplacementDim>
533 std::size_t mesh_item_id,
534 std::vector<NumLib::LocalToGlobalIndexMap const*> const& dof_tables,
535 std::vector<GlobalVector*> const& x, double const t, double& elastic_energy,
536 double& surface_energy, double& pressure_work)
537{
538 std::vector<std::vector<GlobalIndexType>> indices_of_processes;
539 indices_of_processes.reserve(dof_tables.size());
540 std::transform(dof_tables.begin(), dof_tables.end(),
541 std::back_inserter(indices_of_processes),
542 [&](auto const dof_table)
543 { return NumLib::getIndices(mesh_item_id, *dof_table); });
544
545 auto const local_coupled_xs =
546 getCoupledLocalSolutions(x, indices_of_processes);
547 assert(local_coupled_xs.size() ==
548 phasefield_size + displacement_size + pressure_size);
549
550 auto const d = Eigen::Map<PhaseFieldVector const>(
551 &local_coupled_xs[phasefield_index], phasefield_size);
552 auto const u = Eigen::Map<DeformationVector const>(
553 &local_coupled_xs[displacement_index], displacement_size);
554 auto const p = Eigen::Map<PressureVector const>(
555 &local_coupled_xs[pressure_index], pressure_size);
556
558 x_position.setElementID(_element.getID());
559
560 double element_elastic_energy = 0.0;
561 double element_surface_energy = 0.0;
562 double element_pressure_work = 0.0;
563
564 double const gc = _process_data.crack_resistance(t, x_position)[0];
565 double const ls = _process_data.crack_length_scale(t, x_position)[0];
566 int const n_integration_points = _integration_method.getNumberOfPoints();
567 for (int ip = 0; ip < n_integration_points; ip++)
568 {
569 auto const& w = _ip_data[ip].integration_weight;
570 auto const& N = _ip_data[ip].N;
571 auto const& dNdx = _ip_data[ip].dNdx;
572 double const d_ip = N.dot(d);
573 double const p_ip = N.dot(p);
574
575 element_elastic_energy += _ip_data[ip].elastic_energy * w;
576
577 switch (_process_data.phasefield_model)
578 {
580 {
581 element_surface_energy +=
582 gc * 0.375 *
583 ((1 - d_ip) / ls + (dNdx * d).dot((dNdx * d)) * ls) * w;
584
585 break;
586 }
588 {
589 element_surface_energy += 0.5 * gc *
590 ((1 - d_ip) * (1 - d_ip) / ls +
591 (dNdx * d).dot((dNdx * d)) * ls) *
592 w;
593 break;
594 }
596 {
597 element_surface_energy +=
598 gc / std::numbers::pi *
599 ((1 - d_ip * d_ip) / ls + (dNdx * d).dot((dNdx * d)) * ls) *
600 w;
601 break;
602 }
603 }
604
605 element_pressure_work += p_ip * (N_u_op(N) * u).dot(dNdx * d) * w;
606 }
607
608#ifdef USE_PETSC
609 int const n_all_nodes = indices_of_processes[1].size();
610 int const n_regular_nodes = std::count_if(
611 begin(indices_of_processes[1]), end(indices_of_processes[1]),
612 [](GlobalIndexType const& index) { return index >= 0; });
613 if (n_all_nodes != n_regular_nodes)
614 {
615 element_elastic_energy *=
616 static_cast<double>(n_regular_nodes) / n_all_nodes;
617 element_surface_energy *=
618 static_cast<double>(n_regular_nodes) / n_all_nodes;
619 element_pressure_work *=
620 static_cast<double>(n_regular_nodes) / n_all_nodes;
621 }
622#endif // USE_PETSC
623 elastic_energy += element_elastic_energy;
624 surface_energy += element_surface_energy;
625 pressure_work += element_pressure_work;
626}
627
628template <typename ShapeFunction, int DisplacementDim>
629std::vector<double> const&
631 const double /*t*/,
632 std::vector<GlobalVector*> const& /*x*/,
633 std::vector<NumLib::LocalToGlobalIndexMap const*> const& /*dof_table*/,
634 std::vector<double>& cache) const
635{
637 &IpData::width_ip, cache);
638}
639} // namespace HMPhaseField
640} // namespace ProcessLib
GlobalMatrix::IndexType GlobalIndexType
void setElementID(std::size_t element_id)
MatrixType< _kelvin_vector_size, _number_of_dof > BMatrixType
void approximateFractureWidth(std::size_t mesh_item_id, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, std::vector< GlobalVector * > const &x, double const t, double const dt) override
void computeEnergy(std::size_t mesh_item_id, std::vector< NumLib::LocalToGlobalIndexMap const * > const &dof_tables, std::vector< GlobalVector * > const &x, double const t, double &elastic_energy, double &surface_energy, double &pressure_work) override
void assembleWithJacobianForStaggeredScheme(double const t, double const dt, Eigen::VectorXd const &local_x, Eigen::VectorXd const &local_x_prev, int const process_id, std::vector< double > &local_b_data, std::vector< double > &local_Jac_data) override
void postNonLinearSolverConcrete(Eigen::VectorXd const &local_x, Eigen::VectorXd const &local_x_prev, double const t, double const dt, int const process_id) override
std::vector< double > const & getIntPtWidth(const double, std::vector< GlobalVector * > const &, std::vector< NumLib::LocalToGlobalIndexMap const * > const &, std::vector< double > &cache) const override
void assembleWithJacobianPhaseFieldEquations(double const t, double const dt, Eigen::VectorXd const &local_x, std::vector< double > &local_b_data, std::vector< double > &local_Jac_data)
void assembleWithJacobianHydroEquations(const double t, double const dt, Eigen::VectorXd const &local_x, Eigen::VectorXd const &local_x_prev, std::vector< double > &local_b_data, std::vector< double > &local_Jac_data)
void assembleWithJacobianForDeformationEquations(double const t, double const dt, Eigen::VectorXd const &local_x, std::vector< double > &local_b_data, std::vector< double > &local_Jac_data)
auto & selectSolidConstitutiveRelation(SolidMaterialsMap const &constitutive_relations, MeshLib::PropertyVector< int > const *const material_ids, std::size_t const element_id)
Eigen::Matrix< double, GlobalDim, GlobalDim > formEigenTensor(MaterialPropertyLib::PropertyDataType const &values)
Eigen::Matrix< double, 3, 3 > kelvinVectorToTensor(Eigen::Matrix< double, 4, 1, Eigen::ColMajor, 4, 1 > const &v)
Eigen::Map< Vector > createZeroedVector(std::vector< double > &data, Eigen::VectorXd::Index size)
Eigen::Map< Matrix > createZeroedMatrix(std::vector< double > &data, Eigen::MatrixXd::Index rows, Eigen::MatrixXd::Index cols)
double interpolateXCoordinate(MeshLib::Element const &e, typename ShapeMatricesType::ShapeMatrices::ShapeType const &N)
BMatrixType computeBMatrix(DNDX_Type const &dNdx, N_Type const &N, const double radius, const bool is_axially_symmetric)
Fills a B-matrix based on given shape function dN/dx values.
std::vector< double > const & getIntegrationPointScalarData(IntegrationPointDataVector const &ip_data_vector, MemberType IpData::*const member, std::vector< double > &cache)
std::vector< double > getCoupledLocalSolutions(std::vector< GlobalVector * > const &global_solutions, std::vector< std::vector< GlobalIndexType > > const &indices)
MatrixType< ShapeFunction::NPOINTS, ShapeFunction::NPOINTS > NodalMatrixType