Hi Kent, > Hi, I just implemented a small toolbox for finite element calculations > based on Lagrangian elements > and compared it to similar code using GiNaC. The difference in > efficiency is remarkable. My sympy > code takes about 20 seconds where corresponding GiNaC code is below > one second.
Thanks a lot for writing this. I am aware of SyFi [1] and I wanted to to write something like you just wrote in sympy. For those who want to know more about it, I suggest to read the tutorial [2], which explains everything. I myself am using the libmesh [3] library for finite elements, which is very good. But the SyFi's approach is very nice. Did you try it on some real example? How does it compare to the traditional approach, that libmesh is using? BTW, I am glad that SyFi is using swiginac[4], that we wrote with Ola Skavhaug. I thought that when I wrap ginac to python, I'll get an easy to use symbolic library, but I realized this is not the way. Can I add your example to the examples directory in SymPy? We use a BSD license. > Any comments on this ? As Fredrik has said, we need to improve the integration of polynomials. See recently discussed issues for that: http://code.google.com/p/sympy/issues/detail?id=461 http://code.google.com/p/sympy/issues/detail?id=463 But generally, Python is like 200 slower than C++ in my experience, so this is what has to be expected. Could you tell us what are the future plans with SyFi and also Fenics[5] etc? Last time I tried that, it took quite a long time to compile and it wasn't as versatile as libmesh (particularly I need to assign boundary conditions and changing conductivity in the body, which wasn't implemented at that time, but libmesh can do that easily). Generally I like the fenics ideas, but it wasn't yet ready for a production use. So I am curious what your own plans are, as I would like to help if I like it, because good finite elements in Python is exactly what I need. Ondrej [1] http://heim.ifi.uio.no/~kent-and/software/SyFi/doc/SyFi.html [2] http://heim.ifi.uio.no/~kent-and/software/SyFi/doc/tutorial/tutorial.pdf [3] http://libmesh.sourceforge.net/ [4] http://swiginac.berlios.de/ [5] http://www.fenics.org/wiki/FEniCS_Project --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sympy?hl=en -~----------~----~----~----~------~----~------~--~---
