ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Tue, 24 May 2016 16:07:58 +0200Is there any easy way to parallel gröbnerbasis computations in sage?https://ask.sagemath.org/question/33534/is-there-any-easy-way-to-parallel-grobnerbasis-computations-in-sage/Hi, I have a problem I am currently working on where I wish to eliminate variables from a system of polynomials. I have managed to do it in several cases, but for large systems to check my hypothesis the memory usage becomes very large, and the computations take a long time. Therefore I wondered if there is any easy way to optimalize the gröbner basis computation in sage. I am currently using the .elimination_ideal([]) environment, but it turns out to be very ineffective in the examples I am computing. I figured out that one of the limitations is that the eliminate function runs on only one core of the computer. So I therefore thought that in order to speed up the computations, then one could parallelize the function. However, it turns out that all current environments on sage including @fork, @parallel and parallelism.set() does not help at all in this case, since the process still runs on only one core.
Any good ideas out there? Tue, 24 May 2016 14:26:36 +0200https://ask.sagemath.org/question/33534/is-there-any-easy-way-to-parallel-grobnerbasis-computations-in-sage/Comment by slelievre for <p>Hi, I have a problem I am currently working on where I wish to eliminate variables from a system of polynomials. I have managed to do it in several cases, but for large systems to check my hypothesis the memory usage becomes very large, and the computations take a long time. Therefore I wondered if there is any easy way to optimalize the gröbner basis computation in sage. I am currently using the .elimination_ideal([]) environment, but it turns out to be very ineffective in the examples I am computing. I figured out that one of the limitations is that the eliminate function runs on only one core of the computer. So I therefore thought that in order to speed up the computations, then one could parallelize the function. However, it turns out that all current environments on sage including @fork, @parallel and parallelism.set() does not help at all in this case, since the process still runs on only one core.</p>
<p>Any good ideas out there? </p>
https://ask.sagemath.org/question/33534/is-there-any-easy-way-to-parallel-grobnerbasis-computations-in-sage/?comment=33538#post-id-33538Can you provide some explicit examples that other users can play with to investigate your question?Tue, 24 May 2016 16:06:33 +0200https://ask.sagemath.org/question/33534/is-there-any-easy-way-to-parallel-grobnerbasis-computations-in-sage/?comment=33538#post-id-33538Answer by tmonteil for <p>Hi, I have a problem I am currently working on where I wish to eliminate variables from a system of polynomials. I have managed to do it in several cases, but for large systems to check my hypothesis the memory usage becomes very large, and the computations take a long time. Therefore I wondered if there is any easy way to optimalize the gröbner basis computation in sage. I am currently using the .elimination_ideal([]) environment, but it turns out to be very ineffective in the examples I am computing. I figured out that one of the limitations is that the eliminate function runs on only one core of the computer. So I therefore thought that in order to speed up the computations, then one could parallelize the function. However, it turns out that all current environments on sage including @fork, @parallel and parallelism.set() does not help at all in this case, since the process still runs on only one core.</p>
<p>Any good ideas out there? </p>
https://ask.sagemath.org/question/33534/is-there-any-easy-way-to-parallel-grobnerbasis-computations-in-sage/?answer=33539#post-id-33539There is no parallel computation of Groebner basis in Sage. However, `.elimination_ideal([])` uses a algorithm provided by SIngular which is not the fastest available, and you can not change it in this method. You can specify which algorithm in the `.groebner_basis()` method.
A good candidate is the following:
Install `giacpy` from your terminal:
sage -i giacpy
Then, you can get the Groebner Basis from within Sage as follows:
sage: G = I.groebner_basis(algorithm='giac:gbasis')
You can get all possible algorithms by doing
sage: G = I.groebner_basis?
Please tell us if it was faster.
Tue, 24 May 2016 16:07:58 +0200https://ask.sagemath.org/question/33534/is-there-any-easy-way-to-parallel-grobnerbasis-computations-in-sage/?answer=33539#post-id-33539