Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Maxima with Pynac/Singular in Expression.factor() #23835

Closed
rwst opened this issue Sep 12, 2017 · 20 comments
Closed

Replace Maxima with Pynac/Singular in Expression.factor() #23835

rwst opened this issue Sep 12, 2017 · 20 comments

Comments

@rwst
Copy link

rwst commented Sep 12, 2017

The default for symbolic factorization should be changed. Maxima as default should be replaced with a call to Pynac's factor() implementation, which itself uses Singular at the moment. Maxima should be made available via ex.factor(algorithm=...).

As an example of performance gain here one of the Fateman benchmarks:

sage: var('a b c k s y z')
(a, b, c, k, s, y, z)
sage: f = (1+x+y+z)^20+1
sage: g = (f*(f+1)).expand()
sage: %time _=g.factor()

This takes 11 seconds on 8.1.beta5 and 3.3 seconds with Pynac factor (identical time using polynomial ring).

Depends on #23950

CC: @tscrim

Component: symbolics

Author: Ralf Stephan

Branch: 19cff3a

Reviewer: Travis Scrimshaw

Issue created by migration from https://trac.sagemath.org/ticket/23835

@rwst rwst added this to the sage-8.1 milestone Sep 12, 2017
@rwst
Copy link
Author

rwst commented Sep 14, 2017

Dependencies: #23861

@rwst
Copy link
Author

rwst commented Sep 18, 2017

@rwst
Copy link
Author

rwst commented Sep 18, 2017

Changed dependencies from #23861 to pynac-0.7.12

@rwst
Copy link
Author

rwst commented Sep 18, 2017

Commit: 5157371

@rwst
Copy link
Author

rwst commented Sep 18, 2017

Author: Ralf Stephan

@rwst
Copy link
Author

rwst commented Sep 18, 2017

New commits:

515737123835: Replace Maxima with Pynac/Singular in Expression.factor()

@rwst

This comment has been minimized.

@rwst
Copy link
Author

rwst commented Oct 1, 2017

Changed dependencies from pynac-0.7.12 to #23950

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Nov 9, 2017

Changed commit from 5157371 to e9484ce

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Nov 9, 2017

Branch pushed to git repo; I updated commit sha1. New commits:

6a00170Merge branch 'develop' into t/23835/replace_maxima_with_pynac_singular_in_expression_factor__
e9484ce23835: fix doctest

@rwst rwst modified the milestones: sage-8.1, sage-8.2 Mar 3, 2018
@tscrim
Copy link
Collaborator

tscrim commented Aug 5, 2018

comment:8

If you rebase this to 8.4.beta0, I will review it.

@tscrim
Copy link
Collaborator

tscrim commented Aug 5, 2018

Reviewer: Travis Scrimshaw

@tscrim tscrim modified the milestones: sage-8.2, sage-8.4 Aug 5, 2018
@tscrim
Copy link
Collaborator

tscrim commented Aug 23, 2018

comment:9

Ping?

@rwst
Copy link
Author

rwst commented Aug 23, 2018

comment:10

Sorry, due to other work I'm restricting my activities to maintaining Pynac and its upgrade tickets.

@tscrim
Copy link
Collaborator

tscrim commented Aug 24, 2018

comment:11

No problem. It ended up being a trivial rebase. So I am treating this ticket as a needs_review.

While I do not see as big of a speed difference (9.5s to 3.2s), it still is quite an improvement. So positive review.


New commits:

19cff3aMerge branch 'u/rws/replace_maxima_with_pynac_singular_in_expression_factor__' of git://trac.sagemath.org/sage into u/tscrim/expression_factor-23835

@tscrim
Copy link
Collaborator

tscrim commented Aug 24, 2018

@tscrim
Copy link
Collaborator

tscrim commented Aug 24, 2018

Changed commit from e9484ce to 19cff3a

@vbraun
Copy link
Member

vbraun commented Aug 26, 2018

Changed branch from u/tscrim/expression_factor-23835 to 19cff3a

@egourgoulhon
Copy link
Member

Changed commit from 19cff3a to none

@egourgoulhon
Copy link
Member

comment:13

See #27304 for a follow up (bug in factorization of exponentials).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants