Longest Lucas seq. from start to "n"
Maximilian Hasler
maximilian.hasler at gmail.com
Thu Oct 18 16:02:39 CEST 2007
I submitted the following before receiving the e-mails from Max,
So the %C could be modified to incorporate
... v(1) = A019446(n) =ceil(n/tau) or A060143(n) = floor(n/tau)
but "round" cannot be used to select the correct value.
and references to A019446,A060143.
Btw, in A019446 the code
MATHEMATICA a[n_] := 1+Floor[n/GoldenRatio]
is a bit confusing (altough correct since for irrationals, ceil = 1+floor)
---------- Forwarded message ----------
From: The On-Line Encyclopedia of Integer Sequences <oeis at research.att.com>
Date: Oct 18, 2007 9:35 AM
Subject: SEQ+# A134299 FROM Maximilian F. Hasler
The following is a copy of the email message that was sent to njas
containing the sequence you submitted.
All greater than and less than signs have been replaced by their html
equivalents. They will be changed back when the message is processed.
This copy is just for your records. No reply is expected.
Subject: PRE-NUMBERED NEW SEQUENCE A134299 FROM Maximilian F. Hasler
%I A134299
%S A134299 4, 5, 6, 5, 7, 6, 5, 8, 6, 7, 6, 6, 9, 6, 7, 8, 6, 7, 6, 7,
10, 6, 7, 8, 7, 9, 6,
7, 8, 7, 7, 8, 7, 11, 7, 7, 8, 7, 9, 8, 7, 10, 7, 7, 8, 7, 9, 8, 7, 8,
7, 9, 8, 7,
12, 8, 7, 8, 7, 9, 8, 7, 10, 8, 9, 8, 7, 11, 8, 7, 8, 8, 9, 8, 7, 10,
8, 9, 8, 8,
9, 8, 7, 10, 8, 9, 8, 8, 13, 8, 9, 8, 8, 9, 8, 8, 10, 8, 9, 8
%N A134299 Maximal length of a sequence such that v(0)=n, v(k+2) =
v(k)-v(k+1), v(k) >= 0
%C A134299 This is also the maximal index at which n can occur in a
Fibonacci sequence u(k+2)=u(k)+u(k+1) of nonnegative numbers.
A sequence of this length is obtained for v(0)=n,
v(1)=round(2n/(sqrt(5)+1))=A101803(n), except for some special cases:
For n= 12, 30, 35, 43, 51, 72, 80, 88, 93, 96,...
the maximal length is one more than the length obtained for this value of v(1).
%D A134299 Eric Angelini, Max Alekseyev, M.H.: "Longest Lucas seq.
from start to n", on "Sequence Fans" mailing list
<seqfan at ext.jussieu.fr>, Oct.18, 2007
%e A134299 a(2007)=11 since there is no such sequence longer than v
= (2007, 1240, 767, 473, 294, 179, 115, 64, 51, 13, 38)
%o A134299 (PARI) A134299( goal, mi=0, mx=0, new=0 ) = { for(
j=mi,goal, a=[goal,new=j];
while( mi<=new=a[#a-1]-new, a=concat(a,new)); if( #a>mx, mx=#a)); mx }
%Y A134299 A101803
%O A134299 1
%K A134299 ,nonn,
%A A134299 Maximilian F. Hasler (maximilian.hasler at gmail.com), Oct 18 2007
RH
RA 192.20.225.32
RU
RI
More information about the SeqFan
mailing list