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

Question about the thermal thin_wall #28

Open
funderal opened this issue Jun 12, 2024 · 6 comments
Open

Question about the thermal thin_wall #28

funderal opened this issue Jun 12, 2024 · 6 comments

Comments

@funderal
Copy link

Hello everyone,
I've been exploring this code with a keen interest in solving thermoplastic problems. However, I've encountered a stumbling block while trying to work with the thin_wall. I'm facing a ModuleNotFoundError: as detailed below:
`
ModuleNotFoundError Traceback (most recent call last)
Cell In[1], line 10
7 import time
9 from jax_fem.generate_mesh import Mesh
---> 10 from jax_fem.core import FEM
11 from jax_fem.solver import solver
12 from jax_fem.utils import save_sol

ModuleNotFoundError: No module named 'jax_fem.core'
`
But I can't find the core file in jax-fem. I'm wondering if there's something I might miss. Any guidance or suggestions would be greatly appreciated!

@tianjuxue
Copy link
Collaborator

I believe you are referring to an outdated example. Perhaps this newer one can be of some relevance to you. Also check this example for thermal-mechanical coupling.

@funderal
Copy link
Author

Thank you for your answer,I made the appropriate changes based on the code you provided, however a new error was reported as follows:
`
TypeError Traceback (most recent call last)
Cell In[13], line 148
143 # if j > 10:
144 # exit()
147 if name == "main":
--> 148 ded_thin_wall()

Cell In[13], line 92, in ded_thin_wall()
90 dt = t[1] - t[0]
91 sol = full_sol[points_map_active]
---> 92 problem = Thermal(active_mesh, vec=vec, dim=dim, dirichlet_bc_info=[[],[],[]], neumann_bc_info=neumann_bc_info_laser_off,
93 additional_info=(sol, rho, Cp, dt, external_faces))
95 for j in range(num_laser_off):
96 print(f"\n############################################################")

TypeError: init() got an unexpected keyword argument 'neumann_bc_info'
`
How do I make the change?

@tianjuxue
Copy link
Collaborator

I think you are using the old version of JAX-FEM (in the JAX-AM repo), which is discouraged. Please use the new version in this repo.

@funderal
Copy link
Author

But I'm using jax version 0.4.23, jax-fem version 0.4.4, and jaxlib version 0.4.23, aren't these the latest versions?
444

@tianjuxue
Copy link
Collaborator

You are using the right JAX-FEM version, but I think you are referring to an old JAX-FEM example.

I saw "init() got an unexpected keyword argument 'neumann_bc_info'" - This seems to be from an old example.

@funderal
Copy link
Author

Thanks, as per your suggestion I ran the code for quiet_element example. However, after running it for a long time I got the following error:
1111
2222
3333

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

No branches or pull requests

2 participants