#15820: Implement sequences of bounded integers
--------------------------------------------+------------------------
Reporter: SimonKing | Owner:
Type: enhancement | Status: new
Priority: major | Milestone: sage-6.2
Component: algebra | Resolution:
Keywords: sequence bounded integer | Merged in:
Authors: | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: | Stopgaps:
--------------------------------------------+------------------------
Comment (by SimonKing):
Hi Nathann,
Replying to [comment:30 ncohen]:
> Hmmmm.. Can't they all be deduced from the type of implementation
(compressed long, for instance) and the number of bits per entry then ?
Sure. And you want to do this same computation `10^7` times?
> > Isn't duplication of code supposed to smell?
>
> Well, if it is a template the code is only implemented once. And it will
generate several data structures at compile time indeed, but each of them
will have a hardcoded constant, and you only implement one.
Yes. Probably my problem is that I don't think "C++", but I think
"Cython". And there it is a bit clumsy (I think templating is mimicked in
Cython by including .pxi files, isn't it?).
> That's what I had in mind, but you make decisions here, pick what you
like.
>
> It's a bit how bitsets are implemented.
Right, that's what I have looked at, and think makes sense here. Up to the
constants.
> > Then it would be better to revert this ticket to its original purpose:
There would be...
> > 1. ... cdef functions operating on `mpz_t` resp. on `unsigned long*`,
> > 2. ... a Cython class `Path` using `mpz_t` resp. `unsigned long*` as a
cdef attribute, using the afore mentioned functions to implement
concatenation and iteration,
> > 3. ... a subsequent ticket, implementing an F5 style algorithm to
compute standard bases, operating not with `Path` but with `mpz_t*` resp
`unsigned long**` (which will be the case anyway).
>
> Well, I like this plan. What do you think ? Does it displease you in any
way ?
No, it is one possibility.
--
Ticket URL: <http://trac.sagemath.org/ticket/15820#comment:31>
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.