-
Notifications
You must be signed in to change notification settings - Fork 9
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
[v1.0.1] Wrong stress projection to points #94
Comments
Gauss-Legendre points and weights are now calculated by numpy (#96). Two improvements should be made:
The first point is probably not a good idea because this also works for higher order elements if a permuted quadrature is applied, |
permutations are
set them as default for |
Fixed for |
this code does the job (getting started example): # ...
from felupe.math import dot, det, transpose, tovoigt
s = dot(P(F), transpose(F)) / det(F)
s2 = tovoigt(s).T.reshape(-1, 6)
m2 = mesh.as_discontinous()
q2 = quadrature.inv()
r2 = felupe.Region(m2, element, q2, grad=False)
f2 = felupe.Field(r2, dim=6, values=s2)
cauchy2 = f2.interpolate().T.reshape(-1, 6)
v2 = displacement.values[mesh.cells].reshape(-1, 3)
u2 = felupe.Field(r2, dim=3, values=v2)
felupe.tools.save(
r2,
u2,
filename="result_with_cauchy_dg.vtk",
point_data={"CauchyStress": cauchy2},
) |
What is missing:
|
|
|
Quadrature points are indexed differently compared to the cell connectivity (due to the usage of
quadpy
). Thus, stress projection delivers wrong results.A collection of tasks:
tools.project
function for the stress projection to mesh-points (basically the code-snippet above)tools.project()
to Getting Started Example (see tests)The text was updated successfully, but these errors were encountered: