Re: [sage-devel] Re: A possible defect in hypergraph generator of Graph module

2020-04-21 Thread Dima Pasechnik
On Wed, Apr 22, 2020 at 10:59 AM John H Palmieri wrote: > > > > On Tuesday, April 21, 2020 at 5:26:00 PM UTC-7, Dima Pasechnik wrote: >> >> On Wed, Apr 22, 2020 at 2:56 AM k2wagle wrote: >> > >> > Tried this just now, getting the same error. Open a ticket please. >> >> This error is already in Sa

Re: [sage-devel] Re: A possible defect in hypergraph generator of Graph module

2020-04-21 Thread Dima Pasechnik
On Wed, Apr 22, 2020 at 11:00 AM John H Palmieri wrote: > > > > On Tuesday, April 21, 2020 at 7:59:18 PM UTC-7, John H Palmieri wrote: >> >> >> >> On Tuesday, April 21, 2020 at 5:26:00 PM UTC-7, Dima Pasechnik wrote: >>> >>> On Wed, Apr 22, 2020 at 2:56 AM k2wagle wrote: >>> > >>> > Tried this ju

Re: [sage-devel] Re: A possible defect in hypergraph generator of Graph module

2020-04-21 Thread John H Palmieri
On Tuesday, April 21, 2020 at 7:59:18 PM UTC-7, John H Palmieri wrote: > > > > On Tuesday, April 21, 2020 at 5:26:00 PM UTC-7, Dima Pasechnik wrote: >> >> On Wed, Apr 22, 2020 at 2:56 AM k2wagle wrote: >> > >> > Tried this just now, getting the same error. Open a ticket please. >> >> This err

Re: [sage-devel] Re: A possible defect in hypergraph generator of Graph module

2020-04-21 Thread John H Palmieri
On Tuesday, April 21, 2020 at 5:26:00 PM UTC-7, Dima Pasechnik wrote: > > On Wed, Apr 22, 2020 at 2:56 AM k2wagle > > wrote: > > > > Tried this just now, getting the same error. Open a ticket please. > > This error is already in Sage 9.0 - and this is an example from the > manual! > > It's

Re: [sage-devel] Re: A possible defect in hypergraph generator of Graph module

2020-04-21 Thread Dima Pasechnik
On Wed, Apr 22, 2020 at 2:56 AM k2wagle wrote: > > Tried this just now, getting the same error. Open a ticket please. This error is already in Sage 9.0 - and this is an example from the manual! It's quite alarming that our doctests let it through, as it never showed in doctests, and indeed if I

[sage-devel] Re: A possible defect in hypergraph generator of Graph module

2020-04-21 Thread k2wagle
Tried this just now, getting the same error. Open a ticket please. On Tuesday, 21 April 2020 23:56:45 UTC+5:30, Vipul Gupta wrote: > > On running the example given here > > in > the documentation of `Unifo

[sage-devel] A possible defect in hypergraph generator of Graph module

2020-04-21 Thread Vipul Gupta
On running the example given here in the documentation of `UniformRandomUniform` method. It is raising the following error. sage: H = hypergraphs.UniformRandomUniform(52, 3, 17) --

[sage-devel] Re: Efficient algorithm to express symmetric polynomial in terms of elementary ones

2020-04-21 Thread Markus Wageringel
The bottleneck in `from_polynomial` is the check to test whether the input is actually a symmetric polynomial. If you disable the check, the computation is moderately fast, although not quite as fast as Vincent's code. Sym.e().from_polynomial(P(seq_taylor), check=False) -- You received this

Re: [sage-devel] Re: Efficient algorithm to express symmetric polynomial in terms of elementary ones

2020-04-21 Thread Michael Jung
This is awesome! Thank you very much, that was really helpful. Soon, I will open another thread about polarization. Best Michael Am 21.04.2020 um 12:26 schrieb Vincent Delecroix: The crucial difference is that I don't use .from_polynomial (which is kind of broken). Given a univariate polynomia

Re: [sage-devel] Re: Efficient algorithm to express symmetric polynomial in terms of elementary ones

2020-04-21 Thread Vincent Delecroix
The crucial difference is that I don't use .from_polynomial (which is kind of broken). Given a univariate polynomial f it is easy to compute directly the symmetric function f(x1) f(x2) ... f(xn) in the monomial basis (this is what my function prod_in_monomial does). Then the conversion "monomia

Re: [sage-devel] Re: Efficient algorithm to express symmetric polynomial in terms of elementary ones

2020-04-21 Thread Michael Jung
Wow, thanks Vincent. This is awesome! Could you shortly explain what the crucial difference is here? On this occasion, may I ask you a slightly off-topic question? Is there an effective way to compute the polarization of homogeneous polynomials in Sage? Best Michael Am Dienstag, 21. April 20

Re: [sage-devel] Re: Efficient algorithm to express symmetric polynomial in terms of elementary ones

2020-04-21 Thread Vincent Delecroix
Hi Michael, Indeed, Sym.e().from_polynomial(P(seq_taylor)) is taking ages! Using the function from the attached you can compute todd(12) is computed in 18ms :-) sage: todd(12) e[] + 1/2*e[1] + 1/12*e[1, 1] - 1/720*e[1, 1, 1, 1] + 1/30240*e[1, 1, 1, 1, 1, 1] + 1/12*e[2] + 1/24*e[2, 1] + 1/180*e[

[sage-devel] Re: Efficient algorithm to express symmetric polynomial in terms of elementary ones

2020-04-21 Thread Michael Jung
Hi Travis, yes, that is exactly what I want to do. I want to compute multiplicative sequences from arbitrary formal power series, which has use in geometry. However, in that paper, they compare two different approaches. And even the general (slower) approach (elimination) seems to be faster than