Giter Site home page Giter Site logo

Comments (7)

tianjuxue avatar tianjuxue commented on May 28, 2024

@xwpken Please also push the input data files to Github if they are not too large. Thanks!

from jax-fem.

xwpken avatar xwpken commented on May 28, 2024

@hw-wu Hello, we have uploaded the necessary data files. If you have installed the FEniCS, you may also run the 'fenics.py' in the same folder to genereate these files.

from jax-fem.

hw-wu avatar hw-wu commented on May 28, 2024

@xwpken I really appreciate your reply. It seems that FEniCS is used to generate input file... However, when I installed mshr, it said

File "", line 198, in _run_module_as_main
File "", line 88, in _run_code
File "/home/hongwei/Desktop/jax-fem/demos/thermal_mechanical_full/fenics.py", line 16, in
domain = Rectangle(Point(0., 0.), Point(L, L)) - Circle(Point(0., 0.), R, 100)
^^^^^^^^^
NameError: name 'Rectangle' is not defined

And after searching, I found Rectangle() and Circle() functions have been deprecated (https://fenicsproject.discourse.group/t/rectangle-and-circle-functions-deprecated/3845).
So we should use an old version of mshr to generate it?

from jax-fem.

tianjuxue avatar tianjuxue commented on May 28, 2024

@xwpken I really appreciate your reply. It seems that FEniCS is used to generate input file... However, when I installed mshr, it said

File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "/home/hongwei/Desktop/jax-fem/demos/thermal_mechanical_full/fenics.py", line 16, in domain = Rectangle(Point(0., 0.), Point(L, L)) - Circle(Point(0., 0.), R, 100) ^^^^^^^^^ NameError: name 'Rectangle' is not defined

And after searching, I found Rectangle() and Circle() functions have been deprecated (https://fenicsproject.discourse.group/t/rectangle-and-circle-functions-deprecated/3845). So we should use an old version of mshr to generate it?

You don't need to run FEniCS yourself. I think Weipeng already uploaded the necessary input data to the latest repo. Please pull from Github.

from jax-fem.

hw-wu avatar hw-wu commented on May 28, 2024

Thanks for your instant reply. Yeah, you are right. The example.py can run now.. but I am trying to understand how to generate the mesh like @xwpken did in the demo...

from jax-fem.

xwpken avatar xwpken commented on May 28, 2024

Thanks to Prof Xue for his explanation. For using 'fenics.py' to generate data files, you can first check the version of FEniCS. For my Linux machine, the version of FEniCS (including mshr) is 2019.1.0. In the latest FEniCSx, many APIs have changed, so running errors may occur.

from jax-fem.

hw-wu avatar hw-wu commented on May 28, 2024

Thanks for your reply. It can run now. But I also have a question. It seems that the problem is solved twice by FEniCs and JAX-FEM? I am wondering whether it is possibile to use other mesh generation tool like gmsh?

from jax-fem.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.