Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#19068 closed enhancement (fixed)

AsymptoticRing: inversion

Reported by: behackl Owned by:
Priority: major Milestone: sage-6.9
Component: asymptotic expansions Keywords: gsoc15, asymptotics
Cc: dkrenn Merged in:
Authors: Benjamin Hackl Reviewers: Daniel Krenn
Report Upstream: N/A Work issues:
Branch: c7023dd (Commits) Commit:
Dependencies: #17716 Stopgaps:

Description

This ticket implements the inversion (and division) of asymptotic expressions (elements of the AsymptoticRing, implemented in #17716).

This relies heavily on the expansion via geometric series. If the expansion of such a series does not stop (e.g. in the case 1/(1-x)), the series has to be truncated with an O-Term.

Change History (20)

comment:1 Changed 4 years ago by behackl

  • Branch set to u/behackl/asy/inversion
  • Commit set to d72a173f0bee5a0831b05bd3e93f0f619791aeff

Last 10 new commits:

6456300minor rewording in docstring
4e7b080Merge branch 'u/dkrenn/asy/asymptoticExpression' into asy/asymptoticExpression and fixed some merge conflicts
bea6f0dfixed negative powers of O-Terms
5d1d3c0new property default_prec implemented
ab9ae6fdivision implemented
095b987inversion and truncation implemented
d258eb9two types of equality for asymptotic expressions implemented;
f326e4ffixed endless recursion in __eq__
8eb21a6used correct type of equality in truncate
d72a173fixed doctests

comment:2 Changed 4 years ago by git

  • Commit changed from d72a173f0bee5a0831b05bd3e93f0f619791aeff to 5113a73905fffbec49f50a25f5da770beae0c7f5

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

7b8c1a0fixed a conversion issue for terms with coefficient
83f74d3Merge branch 'asy/asymptoticTerm' into asy/asymptoticExpression
5113a73Merge branch 'asy/asymptoticExpression' into asy/inversion

comment:3 Changed 4 years ago by git

  • Commit changed from 5113a73905fffbec49f50a25f5da770beae0c7f5 to 97f15e6f5b8728996a33e818671153c938fa974a

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

fec5796_is_same_term_ moved to TermWithCoefficient
b8ccae1documentation adapted
0346e60refactored: is_same_term --> is_same
56e3816added doctests for is_same
03c2833doctests for _div_ and _invert_ improved
97f15e6mentioned inversion in the module description

comment:4 Changed 4 years ago by dkrenn

  • Branch changed from u/behackl/asy/inversion to u/dkrenn/asy/inversion

comment:5 Changed 4 years ago by git

  • Commit changed from 97f15e6f5b8728996a33e818671153c938fa974a to 51cfce64eb1d1c128985f99b2727c5a79ac49b4b

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

caef9eaterm: is_same --> __eq__
5618385rewrite has_same_summands to use iterators efficiently
51cfce6adapt doc

comment:6 Changed 4 years ago by dkrenn

  • Authors set to Benjamin Hackl
  • Reviewers set to Daniel Krenn
  • Status changed from new to needs_review

3 reviewer commits. Please cross check. Fine otherwise. From my side a conditional positive review (once #17716 is positive this can be set to positive as well).

comment:7 Changed 4 years ago by git

  • Commit changed from 51cfce64eb1d1c128985f99b2727c5a79ac49b4b to 8894fce6d9a060a36b204255cd369938dab7ffdf

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

1c81c12language oddities fixed
032d8b8Merge branch 'asy/growthGroup' into asy/growthGroup-factory
3a05be7Merge tag '6.9.beta5' into t/17600/asy/growthGroup
58f931dadd asymptotic_expansions index
9d6f2daMerge branch 't/17600/asy/growthGroup' into t/18930/asy/growthGroup-factory
6da5adeMerge branch 't/18930/asy/growthGroup-factory' into t/17715/asy/asymptoticTerm
2c1c39dMerge branch 't/17715/asy/asymptoticTerm' into t/17716/asy/asymptoticExpression
8894fceMerge branch 't/17716/asy/asymptoticExpression' into t/19068/asy/inversion

comment:8 Changed 4 years ago by dkrenn

Merged 6.9.beta5

comment:9 Changed 4 years ago by dkrenn

  • Component changed from symbolics to asymptotic expansions

comment:10 Changed 4 years ago by behackl

  • Branch changed from u/dkrenn/asy/inversion to u/behackl/asy/inversion
  • Commit changed from 8894fce6d9a060a36b204255cd369938dab7ffdf to dc38b287ad487186d43c1bff8d45509868b08e12

Merged positively reviewed dependencies and fixed some merge conflicts.


Last 10 new commits:

b31fac8rewrite a couple of one-line descriptions
17e921fremove sorted_set_by_tuple
7af4b6bremove reverse keyword from shells
a49a20dadd comment in code to make it clear what happens
89b8209change left/right to self/other
1d52f6cadd a note to the set operations methods
3b3b2fbobject --> SageObject
572a95dMerge branch 'asy/mutable-poset' into asy/asymptoticExpression
5f54aecexplicitly forbid coercion from MutablePoset into the AsymptoticRing
dc38b28Merge branch 'asy/asymptoticExpression' into asy/inversion

comment:11 Changed 4 years ago by behackl

@Daniel: thank you for your review, I cross-checked your reviewer commits; LGTM. As soon as the dependencies are all positive (and after I've merged them into this branch) I'll set this to positive_review.

Benjamin

comment:12 Changed 4 years ago by dkrenn

  • Status changed from needs_review to needs_work

Merge conflict with changed dependency.

comment:13 Changed 4 years ago by cheuberg

Please add a TODO: Once L-terms are implemented, this inversion here will give incorrect results.

comment:14 Changed 4 years ago by git

  • Commit changed from dc38b287ad487186d43c1bff8d45509868b08e12 to 4edaa39b778366e3edd7e7ca9585338525289b78

Branch pushed to git repo; I updated commit sha1. Last 10 new commits:

dc00f95improve documentation of _element_constructor_
abb08ffimprove _element_constructor_
78b9e96Trac #17716: additional doctest
055e35bTrac #17716: Fix ReSt error
e8e2501make entry in reference/index
f0b759aMerge branch 'asy/asymptoticExpression' into asy/inversion
b37740fremove code duplicate
bfc460afix removed keyword 'default_prec'
fc9bcf2add result to doctest
4edaa39slightly improve __pow__

comment:15 Changed 4 years ago by git

  • Commit changed from 4edaa39b778366e3edd7e7ca9585338525289b78 to c7023dd4f301e0712e69b827ccfa10c7cd2f3b73

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

c7023ddtodo-block with remark w.r.t. L-terms added

comment:16 follow-up: Changed 4 years ago by behackl

  • Status changed from needs_work to needs_review

Daniel, do you want to cross-check the merge and the adaptions?

comment:17 in reply to: ↑ 16 Changed 4 years ago by dkrenn

  • Status changed from needs_review to positive_review

Replying to behackl:

Daniel, do you want to cross-check the merge and the adaptions?

Cross-checked...changes look good.

comment:18 Changed 4 years ago by vbraun

  • Branch changed from u/behackl/asy/inversion to c7023dd4f301e0712e69b827ccfa10c7cd2f3b73
  • Resolution set to fixed
  • Status changed from positive_review to closed

comment:19 follow-up: Changed 4 years ago by jdemeyer

  • Commit c7023dd4f301e0712e69b827ccfa10c7cd2f3b73 deleted

Why reinvent the coercion model? You don't need __div__ and _div_, the class MultiplicativeGroupElement already implements that for you...

I will fix this in #18578.

comment:20 in reply to: ↑ 19 Changed 4 years ago by dkrenn

Replying to jdemeyer:

Why reinvent the coercion model? You don't need __div__ and _div_, the class MultiplicativeGroupElement already implements that for you...

Seems to be a forgotten __div__; we got rid of them in the other files of this folder, but it seems we've forgotten it in the term monoids.

I will fix this in #18578.

Thank you.

Note: See TracTickets for help on using tickets.