I'm doing a large set of symbolic linear system (about 7000) and using solve() is slow (program takes almos an hour to finish).
I've spent 2 days trying to optimize the surrounding code and I've come to the conclusion that the bottleneck is the external calls to solve. Now, all the systems I'm doing are linear (which may have unique, infinte or no solutions) so I went to the docs looking for a specialized function which may be faster. On the docs I found: http://sagemath.org/doc/constructions/linear_algebra.html#solving-systems-of-linear-equations You can also solve linear equations symbolically using the solve_linear command: sage: var('x,y,z,a') (x, y, z, a) sage: eqns = [x + z == y, 2*a*x - y == 2*a^2, y - 2*z == 2] sage: solve(eqns, x, y, z) [[x == a + 1, y == 2*a, z == a - 1]] But... that's solve() not solve_linear() and I can't find a solve_linear either. So.. am I missing something? --~--~---------~--~----~------------~-------~--~----~ 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/sage-support URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---
