Talk:Summarize and say sequence: Difference between revisions

m
Thundergnat moved page Talk:Self-referential sequence to Talk:Summarize and say sequence: Better descriptive name
m (Thundergnat moved page Talk:Self-referential sequence to Talk:Summarize and say sequence: Better descriptive name)
 
(9 intermediate revisions by 4 users not shown)
Line 1:
==Explanation request==
For the first sequence. I thought it was the second sequence until they diverge and I then newknew I was following the wrong method of generation. --[[User:Paddy3118|Paddy3118]] 21:34, 21 August 2011 (UTC)
: The first sequence is just an example, not central to the task. In that one you generate the next term by reading out loud, if you will, the digits. 0 is one zero (10), next there is (reading the term) one one, one zero (1110) then three ones, one zero (3110) See [http://oeis.org/A001155 A001155]. I just mentioned it because it is probably the most commonly cited self-referential sequence in my experience. It is just a coincidence that they are the same for the first five elements when seeded with 0. It may be worth have generation of that sequence as part of the task (or a separate task) but I thought the second sequence was more interesting. As an aside, for the second sequence, I think there may be only one sequence that takes more than 21 steps to converge. A string of 900 9s will converge in 22 steps. There may be others but I haven't, and can't practically do an exhaustive search. --[[User:Thundergnat|Thundergnat]] 00:40, 22 August 2011 (UTC)
:: There certainly will be longer sequences. Take a number with 900 digit 9s, its next step is 9009, so length is +1. That number itself ends with 9, so you can construct another number with a gadzillion digits of 9s which is again length +1, and this can go on ad infinitum. --[[User:Ledrug|Ledrug]] 03:35, 22 August 2011 (UTC)
::: Erm. Obvious as soon as you pointed it out. Sigh. --[[User:Thundergnat|Thundergnat]] 10:52, 22 August 2011 (UTC)
 
:Okay. Is the difference that in the first sequence you say what you see whilst travellingtraveling left-to-right through the digits, whilst in the second you are summarizing how many of each digit there are from highest digit to lowest? (Maybe any description could aid comprehension by also describing the derivation of that member of the sequence where they start to differ)? --[[User:Paddy3118|Paddy3118]] 07:38, 22 August 2011 (UTC)
 
:: Perhaps an easier way to think of it is to take the term, say 13123110, sort the digits high to low: 33211110, then read it off as in the look-and-say sequence (which is what the first sequence is basically): 2 3s, 1 2, 4 1s, 1 0 or 23124110. In look-and-say, you don't sort the digits first. Here, you do.--[[User:Thundergnat|Thundergnat]] 10:52, 22 August 2011 (UTC)
 
::: Instead of look-and-say, it's more like count-and-say. I didn't sort the digits at all (in the REXX program). -- [[User:Gerard Schildberger|Gerard Schildberger]] 08:49, 3 May 2012 (UTC)
 
== Huh? ==
Line 28 ⟶ 30:
::: OEIS says "this kind of counting sequence", so maybe "digit counting sequence"? If name has to be "*verb*-and say", the verb is better as "Count" IMO since sorting is not essential. --[[User:Ledrug|Ledrug]] 00:42, 24 August 2011 (UTC)
::::+1 --[[User:Paddy3118|Paddy3118]] 04:55, 25 August 2011 (UTC)
 
::: For the task name, the word   '''sort'''   (as in sorting) isn't necessary to the task,   '''counting'''   is (or is implied by ''looking'').   The '''REXX''' example doesn't do a sort.   -- [[User:Gerard Schildberger|Gerard Schildberger]] ([[User talk:Gerard Schildberger|talk]]) 23:08, 18 August 2018 (UTC)
 
:Sequences which derive a value from the previous value have a nice, well-established name: they are called ''recurrences''. The particular recurrences being discussed here are based on calculations that work with the base ten representation of integers. This kind of manipulation is ''typographical'': essentially it works with the printed representation, which leads us to ''typographical recurrence''. Knuth's term ''semi-numerical'' could apply here: the calculation performs counting over the base 10 typography of the previous term, and counts then turn into typography in the next term. This suggests ''semi-numerical recurrence''.[[User:Kazinator|Kazinator]] ([[User talk:Kazinator|talk]]) 16:50, 20 July 2014 (UTC)
 
==Caching==
The perl example has a note about the calcolationcalculation to a million takes a long time. For the Python solution, I took note of the comment on [http://oeis.org/A036058 the OEIS page]
:''"This kind of counting sequence is always periodic with period 1, 2 or 3"'''
And set up a ring buffer of the last three terms as a cache and also did not compute the series for starting values that had permuted digits of a starting number that had come before.<br>
Line 53 ⟶ 59:
 
So when do we promote it? Is there a implementations-threshold? Do we need to be happy with the name?
 
== 32 bit C? ==
 
Is the C version working on 32 bit systems too?
: Bug fixed. Maybe it was caused by puts("") inside a for().
 
== Seemingly Ungrammatical Sentence ==
 
''"Find all the positive integer seed values under 1000000, for the above convergent self-referential sequence, that takes the largest number of iterations before converging."''
 
I cannot make complete sense out of this. What is the complement of the clause "takes the largest number ..."? Since the verb "takes" is singular, the complement must be some singular noun clause, so "seed values" cannot be it.
 
Is the task to sort the seed values in descending order, by the length of the initial non-repeating segment that they generate, and list all the seed values which tie for first place?[[User:Kazinator|Kazinator]] ([[User talk:Kazinator|talk]]) 16:46, 20 July 2014 (UTC)
10,327

edits