I wanted to draw a little extra attention to https://github.com/sagemath/sage/issues/40147 in case there are people on this mailing list with knowledge of how Singular works and/or how Sage interfaces with it who don't monitor the GitHub issues closely, as I'm not sure if this performance issue is the fault of Sage or of Singular.

Two fairly important computations for function fields appear to be bottlenecked by the _maximal_order_basis function in the FunctionField_integral class. These computations are computing the genus, and finding the places at infinity. The specific line in the _maximal_order_basis that causes the performance issue is when it calls the normalize function in Singular. I've experimented with some monkey patching to make the _maximal_order_basis faster since I'm in a case where I know a basis for the maximal order of my function fields, and modifying theĀ _maximal_order_basis function to immediately return the correct value (since I happen to know it in my case) is enough to greatly speed up the process of finding the infinite places of the function field, so this is definitely the culprit. Computing the genus is still somewhat slow, but it does appear to be sped up significantly by having a faster _maximal_order_basis function.

For comparison, Magma is able to compute the genus and the places at infinity of function fields of comparable size to the ones I've tried to compute in Sage much faster. Sage takes several seconds to minutes for small examples and doesn't finish after letting it run for several hours on larger examples. Magma does the small examples virtually instantly, and the larger examples in a couple seconds.

Does anyone know if this is a bug in Singular, or perhaps is Sage asking Singular to do an unnecessarily complicated computation?

--
Vincent Macri (he/him)

--
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 view this discussion visit 
https://groups.google.com/d/msgid/sage-devel/9e87d3c6-e4d0-42ea-9470-07798341901b%40ucalgary.ca.

Reply via email to