serac icon indicating copy to clipboard operation
serac copied to clipboard

Add shape sensitivities to the `SolidFunctional` module

Open jamiebramwell opened this issue 2 years ago • 7 comments

This adds shape velocity fields to the solid mechanics module. Specifically, we consider a new configuration in the solid mechanics pipeline:

image

where X is the original reference configuration, p is the shape displacement field describing the movement of mesh nodes under shape optimization, and X' is the perturbed reference configuration. Additionally, we have:

image

where x' is the current configuration and u is the displacement field. Note that the displacement gradient that is passed to the material models is now:

image

As a verification problem, I performed a body load simulation using a fixed and non-affine transformed mesh. However, the boundary nodes remain fixed. The displacement field was equivalent.

MicrosoftTeams-image (3)

MicrosoftTeams-image (2)

jamiebramwell avatar Mar 31 '22 23:03 jamiebramwell

@barreracruz FYI

jamiebramwell avatar Mar 31 '22 23:03 jamiebramwell

Wait, I just realized an error in my calculation. Fix incoming tomorrow.

jamiebramwell avatar Mar 31 '22 23:03 jamiebramwell

Codecov Report

Merging #663 (b0e277a) into develop (c79912d) will increase coverage by 0.05%. The diff coverage is 93.54%.

@@             Coverage Diff             @@
##           develop     #663      +/-   ##
===========================================
+ Coverage    94.86%   94.91%   +0.05%     
===========================================
  Files          140      142       +2     
  Lines         8974     9172     +198     
===========================================
+ Hits          8513     8706     +193     
- Misses         461      466       +5     
Impacted Files Coverage Δ
...c/physics/materials/thermal_expansion_material.hpp 100.00% <ø> (ø)
src/serac/physics/state/finite_element_dual.hpp 100.00% <ø> (+20.00%) :arrow_up:
src/serac/physics/state/finite_element_vector.cpp 76.92% <ø> (+9.81%) :arrow_up:
src/serac/physics/state/finite_element_vector.hpp 100.00% <ø> (+2.85%) :arrow_up:
src/serac/physics/state/state_manager.cpp 92.92% <40.00%> (-0.89%) :arrow_down:
src/serac/physics/state/finite_element_state.cpp 74.50% <74.50%> (ø)
src/serac/physics/tests/serac_solid_functional.cpp 96.10% <83.33%> (-0.03%) :arrow_down:
src/serac/physics/solid_functional.hpp 99.12% <98.41%> (+0.61%) :arrow_up:
src/serac/numerics/functional/isotropic_tensor.hpp 100.00% <100.00%> (ø)
...ac/physics/materials/solid_functional_material.hpp 100.00% <100.00%> (ø)
... and 11 more

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

codecov-commenter avatar Apr 01 '22 18:04 codecov-commenter

Thanks for the fix @samuelpmishLLNL ! Adding some tests now...

jamiebramwell avatar Apr 20 '22 17:04 jamiebramwell

@btalamini @samuelpmishLLNL @sethwatts @barreracruz Any other thoughts? Now that I have more reasonable examples and documentation, I was going to give another stab at explaining this PR during the meeting tomorrow.

jamiebramwell avatar Apr 27 '22 17:04 jamiebramwell

I found the last subtle bug (thanks @samuelpmishLLNL !) so this branch should now be ready for a final review.

jamiebramwell avatar Jun 21 '22 16:06 jamiebramwell

I believe this refactor is now done. It has an "always on" version of shape sensitivities as it was getting very messy to change function signatures. I propose we add this as an initial step, but I am open to suggestions. Any thoughts @samuelpmishLLNL @btalamini @sethwatts @kswartz92 ?

jamiebramwell avatar Sep 01 '22 16:09 jamiebramwell

This should be ready for a final review.

jamiebramwell avatar Sep 08 '22 23:09 jamiebramwell