A182654 Floor-sum sequence of r, with r=sqrt(2) and a(1)=1, a(2)=2.
1, 2, 4, 7, 8, 11, 12, 14, 15, 16, 18, 19, 21, 22, 24, 25, 26, 28, 29, 31, 32, 33, 35, 36, 38, 39, 41, 42, 43, 45, 46, 48, 49, 50, 52, 53, 55, 56, 57, 59, 60, 62, 63, 65, 66, 67, 69, 70, 72, 73, 74, 76, 77, 79, 80, 82, 83, 84, 86, 87, 89, 90, 91, 93, 94, 96, 97, 98, 100
Offset: 1
Keywords
A182655 Floor-sum sequence of r, with r=(3+sqrt(5))/2 and a(1)=1, a(2)=2.
1, 2, 7, 20, 23, 54, 57, 62, 65, 70, 78, 112, 143, 146, 151, 154, 159, 164, 167, 172, 175, 180, 185, 188, 193, 201, 206, 209, 214, 222, 230, 235, 243, 256, 264, 290, 295, 298, 303, 311, 319, 324, 332, 345, 353, 366
Offset: 1
Keywords
Comments
Let S be the set generated by these rules: (1) if m and n are in S and m
Let B be the Beatty sequence of r. Then a floor-sum sequence of r is a subsequence of B if and only if a(1) and a(2) are terms of B.
Examples
7 is in the sequence because floor(r*a(1)+r*a(2))=floor(r+2r)=7 57 is in the sequence because floor(r*a(2)+r*a(4))=floor(r*22)=57 61 is not in the sequence because 23*r=60.21... and 24*r=62.83... so there are no integers x,y with floor(r*(x+y))=61 60 is not in the sequence because floor(r*(x+y))=60 requires x+y=23, and no pair of elements of the sequence sum to 23
A182656 Floor-sum sequence of r, with r=sqrt(3), and a(1)=1, a(2)=2.
1, 2, 5, 10, 12, 19, 20, 22, 24, 25, 29, 34, 36, 38, 39, 41, 43, 45, 46, 50, 51, 53, 55, 58, 60, 62, 64, 65, 67, 69, 71, 72, 74, 76, 77, 79, 81, 83, 84, 86, 88, 90, 91, 93, 95, 96, 98, 100, 102, 103, 105, 107, 109, 110, 112, 114, 116, 117
Offset: 1
Keywords
Comments
Let S be the set generated by these rules: (1) if m and n are in S and m
Let B be the Beatty sequence of r. Then a floor-sum sequence of r is a subsequence of B if and only if a(1) and a(2) are terms of B.
Examples
a(3)=floor(r+2r)=5.
A182669 Floor-sum sequence of r, with r = golden ratio = (1+sqrt(5))/2 and a(1)=1, a(2)=3.
1, 3, 6, 11, 14, 19, 22, 24, 27, 32, 35, 37, 40, 43, 45, 48, 53, 56, 58, 61, 64, 66, 69, 71, 74, 77, 79, 82, 87, 90, 92, 95, 98, 100, 103, 105, 108, 111, 113, 116, 119, 121, 124, 126, 129, 132, 134, 137, 139, 142, 145, 147, 150, 153, 155, 158, 160, 163, 166, 168, 171, 173, 174, 176, 179, 181, 184
Offset: 1
Keywords
Comments
Examples
a(3)=floor(r+3r)=6.
Links
- Iain Fox, Table of n, a(n) for n = 1..3000
Programs
-
PARI
lista(nn) = my(S=[1, 3], r=(1+sqrt(5))/2, new, k); while(1, new=[]; for(m=1, #S, for(n=m+1, #S, k=floor(r*(S[m]+S[n])); if(k<=nn, new=setunion(new,[k])))); if(S==setunion(S,new), return(S)); S=setunion(S,new)) \\ Iain Fox, Apr 25 2019
-
QBasic
r=(1+5^(1/2))/2: s(1)=1: s(2)=3: s(5)=6 For h=2 to 200: c(h)=h+c(h-1): next h For h=1 to 100: c=c(h): d=0 For i=1 to h+1: d=d+1: s(c+d)=int(s(i)+s(h+2)*r) Next i Next h For i=1 to 1000: for j=i+1 to 1001 if s(i)>=s(j) then swap s(i),s(j) next j,i For i=1 to 120: if s(i+1)<>s(i) then print s(i); next i
Extensions
139 (generated by m=22, n=64) added by R. J. Mathar, Nov 28 2010
A182670 Floor-sum sequence of r, where r = golden ratio = (1+sqrt(5))/2 and a(1)=2, a(2)=3.
2, 3, 8, 16, 17, 29, 30, 32, 38, 40, 50, 51, 53, 55, 56, 59, 61, 64, 66, 67, 69, 72, 74, 76, 77, 79, 84, 85, 87, 88, 90, 92, 93, 95, 98, 100, 101, 103, 106, 108, 110, 111, 113, 114, 116, 118, 119, 121, 122, 124, 126, 127, 129, 131, 132, 134, 135, 137, 139, 140
Offset: 1
Keywords
Comments
Examples
a(3) = floor(2r+3r) = 8.
Links
- Iain Fox, Table of n, a(n) for n = 1..3000
Programs
-
Maple
A182670 := proc(amax) a := {2,3} ; r := (1+sqrt(5))/2 ; while true do anew := {} ; for i in a do for j in a do if i <> j then S := floor(r*(i+j)) ; if is(S <= amax) then anew := anew union { S }; end if; end if; end do: end do: if a union anew = a then return sort(a) ; end if; a := a union anew ; end do: end proc: A182670(140) ;
-
PARI
lista(nn) = my(S=[2, 3], r=(1+sqrt(5))/2, new, k); while(1, new=[]; for(m=1, #S, for(n=m+1, #S, k=floor(r*(S[m]+S[n])); if(k<=nn, new=setunion(new, [k])))); if(S==setunion(S, new), return(S)); S=setunion(S, new)) \\ Iain Fox, Apr 25 2019
Comments
Crossrefs
Programs
Maple