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!)
A369515 Triangle of hexagons read by row, with right diagonal having in-order odd-indexed primes, left diagonal having 2 followed by the in-order even-indexed primes, and column elements are the least multiple of the prime at the top of the column not already in the sequence, with 0 and 1 prepended. 0
0, 1, 2, 3, 5, 7, 4, 11, 13, 6, 10, 17, 19, 14, 8, 22, 23, 29, 26, 9, 15, 34, 31, 37, 38, 21, 12, 33, 46, 41, 43, 58, 39, 18, 20, 51, 62, 47, 53, 74, 57, 28, 16, 44, 69, 82, 59, 61, 86, 87, 52, 24, 25, 68, 93, 94, 67, 71, 106, 111, 76, 35, 30, 55, 92, 123, 118 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
The sequence is a permutation of the nonnegative integers.
LINKS
EXAMPLE
a(0)=0, a(1)=1, followed by triangle read by rows:
|2|
|3| | | |5 |
|7 | | | |4| | | |11|
|13| | | |6| | | |10| | | |17|
|19| | | |14| | | |8| | | |22| | | |23|
Row 5, element 3 = 8, because 2*3=6 has already appeared, but 2*4=8 has not.
PROG
(Python)
from sympy.ntheory.generate import prime
from math import ceil
def get_column_tops(n):
return [1 + abs((n-1)-2*m) for m in range(1, n-1)]
def get_indices(rowNum):
left=(rowNum*(rowNum-1))//2
right=left+rowNum-1
return (left, right)
def get_least(m, seq):
mult=2
d=m*mult
while d in seq:
mult+=1
d=m*mult
return d
seq, rnum = ([], 1)
while len(seq)<56:
seq.append(prime(rnum+max(0, rnum-2)))
cols = get_column_tops(rnum)
for k in range(len(cols)):
ndcs=get_indices(cols[k])
if k<ceil(len(cols)/2):
m=seq[ndcs[0]]
seq.append(get_least(m, seq))
else:
m=seq[ndcs[1]]
seq.append(get_least(m, seq))
if rnum > 1:
seq.append(prime(2*rnum-1))
rnum+=1
seq=[0, 1]+seq
print(seq)
CROSSREFS
Cf. A143182.
Sequence in context: A302024 A273665 A212646 * A103866 A268711 A191439
KEYWORD
nonn,tabl
AUTHOR
J. Stauduhar, Jan 25 2024
STATUS
approved

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 July 16 14:30 EDT 2024. Contains 374349 sequences. (Running on oeis4.)