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

Implement a better method of passing state #7

Closed
reverendbedford opened this issue Nov 12, 2018 · 1 comment · Fixed by #142
Closed

Implement a better method of passing state #7

reverendbedford opened this issue Nov 12, 2018 · 1 comment · Fixed by #142
Assignees
Labels
enhancement New feature or request

Comments

@reverendbedford
Copy link
Collaborator

Right now we pass in a huge list of parameters to update the material model state. This is both ugly and makes it very hard to extend to add new types of state descriptions (e.g. radiation dose).

We have the same problem when it comes to history variables. Right now we just pass around vectors of doubles. We need a way to label variables with names and accommodate non scalar state variables.

I think we could deal with both of these issues with the same data structure. Requirements:

  1. Store scalars, vectors, symmetric 2nd order tensors (Mandel notation), and general 2nd order tensors along with an instance of this same data structure (to store history variables).
  2. Be able to report which type each of the above has.
  3. Associate a name with each variable and be able to retrieve variables by name.
  4. Be able to marshal the struct into a flat vector and reconstruct the structure from the marshaled vector.

Objects would all need to be updated to:

  1. Report what sort of state they need (both history and general state).
  2. Take the state structs instead of flat vectors as input.

Interfaces would all need to be updated to:

  1. Provide the struct instead of enumerated parameters (or a flat vector for history).
@reverendbedford reverendbedford self-assigned this Nov 12, 2018
@reverendbedford reverendbedford added the enhancement New feature or request label Nov 21, 2018
@reverendbedford
Copy link
Collaborator Author

The History structure provides all this for the crystal plasticity objects. "All" that would need to be done is to update the macroscale plasticity models to match.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant