-
Notifications
You must be signed in to change notification settings - Fork 90
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
First iteration of adaptivity hooks #1105
base: master
Are you sure you want to change the base?
Conversation
* Store DxDp so it can be retrieved * Allow to reset vector spaces at runtime (for adaptation)
* Add new observer that is Tempus-compatible * Call adaptivity hooks in the new observer
* Add dummy adaptation strategy for STK disc and 1d problems * Add new adv-diff test with adaptation
@@ -389,6 +392,16 @@ class AbstractDiscretization | |||
const bool overlapped = false, | |||
const bool force_write_solution = false) = 0; | |||
|
|||
// Check if mesh adaptation is needed, and if so what kind (topological or just mesh-movement) | |||
virtual Teuchos::RCP<AdaptationData> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm thinking I may change this. Namely, this may just return an AdaptationType enum. The reason is that instead of doing
auto data = disc->checkForAdaptation(x,xdot,xdotdot,dxdp);
if (data->type!=None) {
disc->adapt(data);
}
We could just do
auto type = disc->checkForAdaptation(x,xdot,xdotdot,dxdp);
if (type!=None) {
disc->adapt(x,xdot,xdotdot,dxdp);
}
without forcing the disc to stuff the OLD x/xdot/xdotdot/dxdp inside the returned type (the caller site already has them anyways).
@@ -54,6 +54,9 @@ class AbstractMeshFieldAccessor | |||
virtual void fillSolnMultiVector (Thyra_MultiVector& soln, | |||
const dof_mgr_ptr_t& sol_dof_mgr, | |||
const bool overlapped) = 0; | |||
virtual void fillSolnSensitivity (Thyra_MultiVector& dxdp, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This, and all the dxdp changes in the PR, are so that we can run a pb that computes sensitivities and do adaptation. I haven't tested the dxdp functionality though, so more work may be needed down the road.
This PR adds a first version of the adaptivity hooks. We may change them later if/when we realize they are insufficient/overkill/wrong/whatever. The goal was to get something working.
Some details: