On Thu, 17 Feb 2022 at 19:04, Gerardo Suarez <[email protected]> wrote: > > Hi, sorry for not replying before I ended up solving my problem using > mathematica since I needed to compute this things quite a few times. But if > you could perhaps give out some references and some pointers as to how this > "gcd should be implemented using *sparse* polynomials" could be implemented, > like maybe some paper on the topic. Since I've never contributed to open > source and don't really know anything about sympy internals maybe I wouldn't > be able to work on it as a as a "GSOC project " but I would love to work on > the topic , this issue is the main reason I stoped using sympy lately.
I've added a description of what needs to be done in relation to sparse polynomial gcd here: https://github.com/sympy/sympy/issues/23131 > you mentioned that first step to take might be > > 1. Add code in inv to check for domains that can be handled > efficiently by DomainMatrix (e.g. at least ZZ, QQ, ZZ_I, QQ_I) and > delegate to the lower-level methods. > > Any documentation on which kind of domains can be handled efficiently and how > such check could be done ? or should it be benchmarked? It should just be benchmarked. If you test out the domains yourself though you will quickly discover what the differences are. The domain system is discussed here: https://docs.sympy.org/latest/modules/polys/domainsintro.html > the _rep works amazingly fast but the expressions are quite complicated to > simplify when compared to the Mathematica output, so In my case even though > the actual answer is simple I couldn't get it from the _rep inverse, same > with the connected components approach It shouldn't be too hard to simplify these so maybe there's some other problem. Can you show the full code that you used and what you expected as output? If the expressions are quite complicated it might be better just to focus on the expected output say for the top-left element of the matrix rather than every element. -- Oscar -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/CAHVvXxRoai2H_9jHbV3DUbm9ieDgA%2BjSZaD2-M3%2BNzi1Sc5cqQ%40mail.gmail.com.
