Svoboda | Graniru | BBC Russia | Golosameriki | Facebook
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
Search: a370408 -id:a370408
Displaying 1-2 of 2 results found. page 1
     Sort: relevance | references | number | modified | created      Format: long | short | data
A371060 Lexicographically earliest sequence of distinct terms such that every triplet of successive digits (seen as side lengths) can form a triangle. +10
2
1, 2, 21, 22, 3, 4, 5, 6, 7, 8, 9, 28, 72, 65, 24, 32, 23, 31, 33, 13, 34, 25, 42, 43, 35, 36, 44, 14, 41, 441, 442, 45, 26, 52, 54, 46, 37, 53, 55, 15, 51, 551, 552, 56, 27, 62, 66, 16, 61, 661, 662, 67, 38, 63, 57, 39, 73, 64, 47, 48, 58, 49, 68, 59, 69, 74, 75, 76, 77, 17, 71, 771, 772 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
In a triangle, the sum of any two side lengths is greater than that of the third, so that x + y > z.
LINKS
Eric Angelini and Giorgos Kalogeropoulos, Triangles with digits, Personal blog, March 2024.
EXAMPLE
The first triplet of digits (1, 2, 2) forms an isosceles triangle with basis 1 and sides 2 and 2;
the second triplet (2, 2, 1) forms another isosceles triangle with basis 1 and sides 2 and 2;
the fifth triplet (2, 2, 3) forms another isosceles triangle with basis 3 and sides 2 and 2;
the sixth triplet (2, 3, 4) forms a scalene triangle with sides 2, 3 and 4; etc.
MATHEMATICA
g[1]=1; g[2]=2; g[n_]:=g[n]=(k=1; While[MemberQ[ar=Array[g, n-1], k]|| !And@@(({a, b, c}=#; And@@{a+b>c, b+c>a, a+c>b})&/@Partition[Flatten[IntegerDigits/@Join[ar, {k}]], 3, 1]), k++]; k); Array[g, 80]
CROSSREFS
Cf. A370408.
KEYWORD
base,nonn
AUTHOR
STATUS
approved
A370822 Lexicographically earliest sequence of positive integers such that all equal terms appear at mutually coprime indices. +10
1
1, 1, 1, 2, 1, 3, 1, 4, 2, 5, 1, 6, 1, 7, 4, 8, 1, 9, 1, 10, 5, 11, 1, 12, 2, 13, 7, 14, 1, 15, 1, 16, 8, 17, 3, 18, 1, 19, 10, 20, 1, 21, 1, 22, 11, 23, 1, 24, 2, 25, 13, 26, 1, 27, 6, 28, 14, 29, 1, 30, 1, 31, 16, 32, 7, 33, 1, 34, 17, 35, 1, 36, 1, 37, 19 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,4
COMMENTS
See A279119 for the same sequence with numbers including 0.
See A055396 for a similar sequence where all equal terms share a factor > 1.
LINKS
FORMULA
a(n) = 1 + A279119(n). - Rémy Sigrist, Mar 04 2024
EXAMPLE
a(4)=2 because if we had a(4)=1, then i=2 and i=4, which are not coprime indices, would have the same value 1. So a(4)=2, which is a first occurrence.
a(9)=2 because if we had a(9)=1, i=3 and i=9, would have the same value despite not being coprime indices. a(9) can be 2 because the only other index with a 2 is a(4)=2 and 4 is coprime to 9.
a(15)=4 because 4 is the smallest value such that every previous index at which a 4 occurs is coprime to i=15. In this case, 4 has only occurred at i=8 and 8 is coprime to 15.
PROG
(Python)
from math import gcd, lcm
from itertools import combinations as C, count, islice
def agen(): # generator of terms
yield from [1, 1, 1]
lcms = {1: 6}
for n in count(4):
an = next(an for an in count(1) if an not in lcms or gcd(lcms[an], n) == 1)
yield an
if an not in lcms: lcms[an] = n
else: lcms[an] = lcm(lcms[an], n)
print(list(islice(agen(), 75))) # Michael S. Branicky, Mar 02 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Neal Gersh Tolunsky, Mar 02 2024
EXTENSIONS
a(22) and beyond from Michael S. Branicky, Mar 02 2024
STATUS
approved
page 1

Search completed in 0.005 seconds

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 11 23:47 EDT 2024. Contains 375842 sequences. (Running on oeis4.)