Pull Request Checklist. Please read and check each box with an X. Delete any part not applicable. Ask on the forum if you need help with any step.
Describe what you did in this PR and why you did it.
The previous code gradients[d] works because the indices of velocity or velocity gradient in the vector gradient are at 1 to dim th locations and so doing a for loop from 1 to dim will get the correct results. However, if in the future, someone changed the orders of "struct ComponentIndices" in aspect/include/aspect/introspection.h, then it will be a hidden bug that could be hard to debug.
Before your first pull request:
[x ] I have read the guidelines in our CONTRIBUTING.md document.
Pull Request Checklist. Please read and check each box with an X. Delete any part not applicable. Ask on the forum if you need help with any step.
Describe what you did in this PR and why you did it. The previous code gradients[d] works because the indices of velocity or velocity gradient in the vector gradient are at 1 to dim th locations and so doing a for loop from 1 to dim will get the correct results. However, if in the future, someone changed the orders of "struct ComponentIndices" in aspect/include/aspect/introspection.h, then it will be a hidden bug that could be hard to debug.
Before your first pull request:
For all pull requests:
For new features/models or changes of existing features: