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

Wrong result of umat.plot() for LinearElastic with stretches ≤ 0 #852

Closed
adtzlr opened this issue Sep 17, 2024 · 0 comments · Fixed by #872
Closed

Wrong result of umat.plot() for LinearElastic with stretches ≤ 0 #852

adtzlr opened this issue Sep 17, 2024 · 0 comments · Fixed by #872
Labels
bug Something isn't working

Comments

@adtzlr
Copy link
Owner

adtzlr commented Sep 17, 2024

not only for $\lambda \le 0$ but for the whole range if a stretch $\lambda \le 0$ is included! This happens because all stretches are solved in one scipy.optimize.root()-call by a least-squares problem.

Possible Solution

Try to raise an error if $\lambda \le 0$ is included. There shouldn't be the case where these non-physical stretches are of interest.

Example

import felupe as fem

umat = fem.LinearElastic(E=1, nu=0.3)

x = fem.math.linsteps([1, 0], num=50)

ax = umat.plot(ux=x, bx=x, ps=x)
ax.set_ylim([-1, 1])

image

While it should be:

import felupe as fem

umat = fem.LinearElastic(E=1, nu=0.3)

x = fem.math.linsteps([1, 1e-6], num=50)

ax = umat.plot(ux=x, bx=x, ps=x)
ax.set_ylim([-1, 1])

image

@adtzlr adtzlr added the bug Something isn't working label Sep 17, 2024
@adtzlr adtzlr changed the title umat.plot() generates a wrong result for LinearElastic with stretches lower or equal zero umat.plot() generates a wrong result for LinearElastic with stretches ≤ 0 Sep 17, 2024
@adtzlr adtzlr changed the title umat.plot() generates a wrong result for LinearElastic with stretches ≤ 0 Wrong result of umat.plot() for LinearElastic with stretches ≤ 0 Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant