#18587: cartesian products of growth groups
-------------------------------------+-------------------------------------
Reporter: dkrenn | Owner:
Type: enhancement | Status: needs_work
Priority: major | Milestone: sage-6.9
Component: asymptotic | Resolution:
expansions | Merged in:
Keywords: asymptotics, | Reviewers: Clemens Heuberger
gsoc15 | Work issues:
Authors: Benjamin Hackl, | Commit:
Daniel Krenn | f88d3ead2feadd76bf3fccbd6488f7d0c36c501d
Report Upstream: N/A | Stopgaps:
Branch: u/behackl/asy |
/growth-group-cartesian |
Dependencies: #18223, #18586, |
#18930 |
-------------------------------------+-------------------------------------
Comment (by cheuberg):
Replying to [comment:21 behackl]:
> Replying to [comment:18 cheuberg]:
> > 2. `Variable.__init__`: `ValueError` "is not a valid name": not tested
>
> Removed this particular piece of code; the check is not necessary: the
parser only allows strings that are valid identifiers (see my answer to
3.).
I do not think so: `extract_variable_names` is only called when `repr is
None`, the removed code was only called when `repr is not None`. Indeed,
the following does now work:
{{{
sage: from sage.rings.asymptotic.growth_group import Variable
sage: Variable("(:-)", repr="icecream").var_bases
('(:-)',)
}}}
> > 7. `GrowthGroupFactory.create_key_and_extra_argument`: Again, my
suggestion is to delegate the string parsing to the symbolic ring. Note
that `SR('x^ZZ')` happily accepts `ZZ` as a variable, so I imagine that
postprocessing here would not involve big problems. I do not read this
string parser here before the decision on its eventual fate.
>
> Unfortunately, I think that this should not be parsed by the symbolic
ring: the cartesian product which we model with `*` is not commutative: if
the same variable is used, the growth groups are ordered
lexicographically. By using the symbolic ring, the input order might be
destroyed/ignored.
I see.
The current code makes some effort to recognize `**` in
`create_key_and_extra_args`, but `**` is not recognized in
`create_object`.
> > 9. `CartesianProductFactory`:
> > - the example with "do not have disjoint variables" is somewhat
puzzeling, because the cartesian product of `A` and `B` was allowed.
>
> I understand the confusion. However, I think that the error message is
quite helpful in this case:
> {{{
> sage: cartesian_product([A, E]); G
> Traceback (most recent call last):
> ...
> ValueError: Growth groups (Growth Group x^ZZ, Growth Group x^ZZ * y^ZZ)
do not have pairwise disjoint variables.
> }}}
>
> Mainly, this is because the cartesian product cannot decide which order
to use in this case.
perhaps rephrase error message along the lines of "factors must have equal
or disjoint variables"?
> Also, I think that we should restrict building cartesian products of
growth groups such that a factor may only occur once (currently, `x^ZZ *
x^ZZ` is possible). I'll discuss this with Daniel.
that might be hard.
--
Ticket URL: <http://trac.sagemath.org/ticket/18587#comment:22>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.