Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add adjoint load for the case of adjoints associated with resultant/dual forces. #1238

Merged
merged 17 commits into from
Oct 25, 2024

Conversation

tupek2
Copy link
Collaborator

@tupek2 tupek2 commented Sep 23, 2024

No description provided.

@tupek2
Copy link
Collaborator Author

tupek2 commented Sep 23, 2024

/style

@tupek2 tupek2 force-pushed the tupek/reaction_sensitivities branch from 35042a3 to a5d237b Compare October 1, 2024 14:46
@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 3, 2024

/style

@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 7, 2024

/style

@tupek2 tupek2 force-pushed the tupek/reaction_sensitivities branch from f7b60a7 to ab4ea41 Compare October 8, 2024 14:26
@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 8, 2024

/style

@tupek2 tupek2 force-pushed the tupek/reaction_sensitivities branch from 5b678f7 to a43765c Compare October 8, 2024 21:10
@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 8, 2024

/style

@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 8, 2024

/style

@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 8, 2024

/style

@tupek2 tupek2 added the ready for review Ready for active inspection by reviewers label Oct 9, 2024
@tupek2
Copy link
Collaborator Author

tupek2 commented Oct 9, 2024

This enables a simpler and more consistent interface for reaction force sensitivities. Also, add function to fetch a previous reaction force vector. This is really recomputing it behind the scenes.

@@ -1201,7 +1229,9 @@ class SolidMechanics<order, dim, Parameters<parameter_space...>, std::integer_se
std::unique_ptr<mfem::HypreParMatrix> m_mat(assemble(M));

// J = M + c0 * K
J_.reset();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this fixing a bug? Because the heat transfer module still does it the old way. If so, can you open an issue?

displacement_adjoint_load_ = disp_adjoint_load->second;
// Add the sign correction to move the term to the RHS
displacement_adjoint_load_ *= -1.0;
if (disp_adjoint_load != loads.end()) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This check and the SLIC_ERROR_ROOT_IF above look like they're guarding the same problem. Can we combine these so that they don't get out of sync? Doesn't need to happen in this PR.

@tupek2 tupek2 merged commit c1b9df0 into develop Oct 25, 2024
2 checks passed
@tupek2 tupek2 deleted the tupek/reaction_sensitivities branch November 1, 2024 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready for review Ready for active inspection by reviewers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants