On Sun, 2 Sep 2018, 15:15 Simon King, <simon.k...@uni-jena.de> wrote:

>
> Since this post summarises replies to various posts in this thread and to
> an off-list message, I am making this a reply to the top of the thread.
>

It probably should get subject line "sorry state of basic open-source
commutative altebra" :-)


> Objective: As a *small* part of some group cohomology computations, I need
> to compute the first Hilbert series of certain homogeneous ideals in
> graded-commutative rings, with respect to given degree weights of the
> ring generators.
>
> Problem: The data are in Singular, thus, Singular is the natural
> candidate to do the job. Unfortunately, some of my rings have too many
> variables, which means that Singular's "hilb(...,1)" command suffers
> from an int overflow.
>

It would be good to submit a Singular bug report with an example at
https://github.com/Singular/Sources

It's silly to see an overflow in such a case.

Do you understand where exactly you are hitting intvec limitations:
https://www.singular.uni-kl.de/Manual/4-0-3/sing_455.htm#SEC494

Potential ways out: I am listing potential approaches to achieve the
> objective. In all cases I tell what is good or bad in that approach, in
> some cases I need more support or answers.
>
> 1. Create an implementation in Sage, that does the ideal computations in
> Singular-via-pexpect and does the bigint computations in Sage.
>    Good: It works even in big examples.
>    Bad:  In the cases in which Singular works, Singular is a lot faster.
>

Bad - more code to maintain... :-)

2. Create an implementation in Singular that doesn't use intvec (which
> has a 32 bit limitation) but a different data structure, or get the
> Singular developers to do so.
>    Bad:  I didn't try to implement it myself; Singular devs didn't
>    answer yet.
>

we should try - it could be that the fix is very easy. In particular that
32-bit limitations are from almost obsolete 32-bit processors, IMHO.

Using 'long' instead would remedy a lot...

3. Use frobby.
>    Good: It works in small examples.
>    Bad:  On some big example, it is slower than 1. and fails due to
>          memory problems. And one would need a conversion from multigraded
>          to univariate Hilbert series.
>    ==> Frobby is no serious option.
>

yep, frobby is not maintained, too...

4. Use LattE/normaliz.
>    Bad: I have no idea how.
> 5. Use Macaulay2
>    Bad: (a) The experimental spkg is broken, it won't install.
>

experimental package is dead, IMHO. Creating special gc-aware versions of
several Sage packages and in addition adding more dependincies needed by M2
is a lot of hard work (if specific Linux distos have trouble packaging it
properly, this rings a bell...)


        (b) The installation instructions for Ubuntu on the project
>             pages are rather verbose and require adding obscure
>             repositories.
>         (c) Installation from sources (release-1.12 from github):
>             i. Although I installed all dependencies listed in the
>                INSTALL file, "make" fails because additionally givaro
>                is required. And 'export MAKE="make -j3"' makes Macaulay2
>                believe that gnu make is not installed.
>             ii. I tried installation in a Sage shell, as givaro is
>                in Sage. However, "make" fails as follows:
> /home/king/Projekte/Macaulay2/M2/M2/usr-host/include/fflas-ffpack/fflas/fflas_ftrsm_src.inl:279:27:
> error: ‘openblas_set_num_threads’ was not declared in this scope
>    openblas_set_num_threads(__FFLASFFPACK_OPENBLAS_NUM_THREADS);
>                            ^
> cc1plus: warning: unrecognized command line option ‘-Wno-mismatched-tags’
> ../../include/config.Makefile:226: recipe for target 'interface.o' failed
> make[2]: *** [interface.o] Error 1
> make[2]: Leaving directory
> '/home/king/Projekte/Macaulay2/M2/M2/Macaulay2/d'
> Makefile:20: recipe for target 'all-in-d' failed
> make[1]: *** [all-in-d] Error 2
>    ==> Currently Macaulay2 is no option.
> 6. Use CoCoA(Lib).
>    Good: "sage -i cocoalib" works. CoCoA is known for a focus on Hilbert
>          driven computations, thus, is supposed to be good for the job.
>    Bad: (a) Apparently the optional package only provides the CoCoA
>             library (plus headers, of course), but no Cython bindings.
>         (b) The cocoa documentation is not installed in the proper
>             place, but in SAGE_LOCAL/include/CoCoA/doc. And this is the
>             full documentation of the hilbert() function (I am not joking):
>             """
>             hey!!! write something more!
>
>             I'm just using the C code I wrote for CoCoA-4. It will be
>             entirely rewritten in C++
>
>             The only usable function is
>
>                RingElem HilbertNumeratorMod(PolyRing HSRing, ideal I);
>
>             but it works ONLY if I is a monomial ideal. HSRing is the
>             ring where the Hilbert Series Numerator should live.
>             """
>    ==> CoCoALib seriously lacks documentation and has no Sage bindings, and
>    thus currently it is no option.
>

CoCoAlib is essentially a two-person project.
I know John Abbott, one of the two, reasonably well, could we get him
involved?

>
> QUESTIONS:
> - Are people trying to create cython bindings for CoCoALib?
> - How do I use LattE or normaliz?


Perhaps Matthias Koeppe knows?
I cc to him.

Say:
>    sage: R.<x,y,z,w>=QQ[]
>    sage: I = R*[x^3,x^2*y,x*z]
>   And now how can I compute the first Hilbert series, with given degrees
>   for x,y,z?
> - How to make Macaulay2?
>

The core of M2 is essentially a two-person project. They are very
approachable, but often busy. Try their github...
(I have mixed experience with building M2. IMHO they make it harder by not
using automake...)

Cheers,
Dima



> Best regards,
> Simon
>
> --
> You received this message because you are subscribed to the Google Groups
> "sage-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-devel+unsubscr...@googlegroups.com.
> To post to this group, send email to sage-devel@googlegroups.com.
> Visit this group at https://groups.google.com/group/sage-devel.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to