#13299: Fix slice and __getitem__ methods of padics
--------------------------------+-------------------------------------------
Reporter: saraedum | Owner: roed
Type: defect | Status: needs_review
Priority: minor | Milestone: sage-5.3
Component: padics | Resolution:
Keywords: | Work issues:
Report Upstream: N/A | Reviewers:
Authors: Julian Rueth | Merged in:
Dependencies: | Stopgaps:
--------------------------------+-------------------------------------------
Comment (by saraedum):
Thanks for having a look at this.
Replying to [comment:5 robharron]:
> When I tried to apply this on top of version 5.2 nothing happened. Now,
I've never tried to apply anyone else's patch, so maybe I'm just
incompetent.
I only have 5.1 installed right now. I'll try to apply the patch again, as
soon as I upgrade to 5.3.
> For LocalGenericElement:[[BR]]
> -line 55 should say "nonnegative integers `l`"[[BR]]
> -line 89 should say "if `i` exceeds `j`"[[BR]]
I updated the patch with these two changes.
> -I think it would be nice if there was some relative version of slicing.
Maybe by adding a True/False parameter like "relative". Then, j would
represent a length rather than an absolute cutoff. This would allow a
slice that keep a certain number of "significant digits".
It would not be hard to implement something like this. Probably it should
not be called slicing but use a different method to not confuse people who
are used to python's slicing. If you would like to see such a feature, you
should probably open a new ticket and link it here.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/13299#comment:6>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.