#16137: lazy_list from various input data
-------------------------------------+-------------------------------------
Reporter: MatthieuDien | Owner:
Type: enhancement | Status: new
Priority: major | Milestone: sage-6.4
Component: misc | Resolution:
Keywords: LazyPowerSeries, | Merged in:
lazy_list, days57 | Reviewers:
Authors: Vincent | Work issues:
Delecroix, Matthieu Dien | Commit:
Report Upstream: N/A | 530b21b1a97012b1adfc244dad57250922f4f46c
Branch: | Stopgaps:
public/lazy_list_from_various_input_data|
Dependencies: |
-------------------------------------+-------------------------------------
Comment (by MatthieuDien):
Hi there,
I found the bug that avoid me to connect on Sage trac (I used my phone's
connection).
So, I copy the message which I sent by email.
@Martin
The diference bewteen lazy_list and iterator is not only the caching.
There is also the way to compute an element : if you want the nth element
of an iterator you have to compute the (n-1) previous ones, for lazy_list
(currently the implementation does not do this but it should in close
future) the goal is to compute elements only if it obligatory.
For example, you don't want to compute all the coeffcients of a serie if
at the end, you will only use the odd (or even) part.
Concerning recursive definition, we have to allow it but the
implementation must not be recursive because recursion is extremly
expensive in Python.
@Vincent
To implement this, I need to overload the `_fit` method and pass it in
"`cdef` mode". I just have a question : why, in the iterator's class, do
you use `update_cache_up_to` and not `_fit` ?
And finally, to answer to Martin about "what is `_normalize_slice` ?",
`_normalize_slice` means nothing it is just a piece of code that I wanted
to factorize. In fact I should factorize directly `__getitem__` by adding
a method which have to create a slice (last line of code `__getitem__`).
--
Ticket URL: <http://trac.sagemath.org/ticket/16137#comment:45>
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.