cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A339746 Positive integers of the form 2^i*3^j*k, gcd(k,6)=1, and i == j (mod 3).

This page as a plain text file.
%I A339746 #61 May 15 2025 11:25:39
%S A339746 1,5,6,7,8,11,13,17,19,23,25,27,29,30,31,35,36,37,40,41,42,43,47,48,
%T A339746 49,53,55,56,59,61,64,65,66,67,71,73,77,78,79,83,85,88,89,91,95,97,
%U A339746 101,102,103,104,107,109,113,114,115,119,121,125,127,131,133,135
%N A339746 Positive integers of the form 2^i*3^j*k, gcd(k,6)=1, and i == j (mod 3).
%C A339746 From _Peter Munn_, Mar 16 2021: (Start)
%C A339746 The positive integers in the multiplicative subgroup of the positive rationals generated by 8, 6, and A215848 (primes greater than 3).
%C A339746 This subgroup, denoted H, has two cosets: 2H = (1/3)H and 3H = (1/2)H. It follows that the sequence is one part of a 3-part partition of the positive integers with the property that each part's terms are half the even terms of one of the other parts and also one third of the multiples of 3 in the remaining part.
%C A339746 (End)
%C A339746 Positions of multiples of 3 in A276085 (and in A276075). Because A276085 is completely additive, this is closed under multiplication: if m and n are in the sequence then so is m*n. - _Antti Karttunen_, May 27 2024
%C A339746 The coset sequences mentioned in _Peter Munn_'s comment above are A373261 and A373262. - _Antti Karttunen_, Jun 04 2024
%H A339746 Robert Israel, <a href="/A339746/b339746.txt">Table of n, a(n) for n = 1..10000</a>
%F A339746 a(n) ~ (91/43)*n.
%p A339746 N:= 1000: # for terms <= N
%p A339746 R:= {}:
%p A339746 for k1 from 0 to floor(N/6) do
%p A339746   for k0 in [1,5] do
%p A339746     k:= k0 + 6*k1;
%p A339746     for j from 0 while 3^j*k <= N do
%p A339746       for i from (j mod 3) by 3 do
%p A339746         x:= 2^i * 3^j * k;
%p A339746         if x > N then break fi;
%p A339746         R:= R union {x}
%p A339746 od od od od:
%p A339746 sort(convert(R,list)); # _Robert Israel_, Apr 08 2021
%t A339746 Select[Range[130], Mod[IntegerExponent[#, 2] - IntegerExponent[#, 3], 3] == 0 &]
%o A339746 (PARI) isA339746 = A372573; \\ _Antti Karttunen_, Jun 04 2024
%o A339746 (Python)
%o A339746 from sympy import factorint
%o A339746 def ok(n):
%o A339746   f = factorint(n, limit=4)
%o A339746   i, j = 0 if 2 not in f else f[2], 0 if 3 not in f else f[3]
%o A339746   return (i-j)%3 == 0
%o A339746 def aupto(limit): return [m for m in range(1, limit+1) if ok(m)]
%o A339746 print(aupto(200)) # _Michael S. Branicky_, Mar 26 2021
%o A339746 (Python)
%o A339746 from itertools import count
%o A339746 def A339746(n):
%o A339746     def bisection(f,kmin=0,kmax=1):
%o A339746         while f(kmax) > kmax: kmax <<= 1
%o A339746         kmin = kmax >> 1
%o A339746         while kmax-kmin > 1:
%o A339746             kmid = kmax+kmin>>1
%o A339746             if f(kmid) <= kmid:
%o A339746                 kmax = kmid
%o A339746             else:
%o A339746                 kmin = kmid
%o A339746         return kmax
%o A339746     def f(x):
%o A339746         c = n+x
%o A339746         for i in range(x.bit_length()+1):
%o A339746             i2 = 1<<i
%o A339746             for j in count(i%3,3):
%o A339746                 k = i2*3**j
%o A339746                 if k>x:
%o A339746                     break
%o A339746                 m = x//k
%o A339746                 c -= (m-1)//6+(m-5)//6+2
%o A339746         return c
%o A339746     return bisection(f,n,n) # _Chai Wah Wu_, Feb 12 2025
%Y A339746 Sequences of positive integers in a multiplicative subgroup of positive rationals generated by a set S and A215848: S={}: A007310, S={6}: A064615, S={3,4}: A003159, S={2,9}: A007417, S={4,6}: A036668, S={3,8}: A191257, S={4,9}: A339690, S={6,8}: this sequence.
%Y A339746 Positions of 0's in A373153, positions of multiples of 3 in A276085 and in A372576.
%Y A339746 Cf. A372573 (characteristic function), A373261, A373262.
%Y A339746 Subsequences: A064615, A373144, A373373, A373484, A373837, A374042, A374044, A374120, A377872.
%Y A339746 Sequences giving positions of multiples of k in A276085, for k=2, 3, 4, 5, 8, 27, 3125: A003159, this sequence, A369002, A373140, A373138, A377872, A377878.
%Y A339746 Cf. also A332820, A373992, A383288.
%K A339746 nonn
%O A339746 1,2
%A A339746 _Griffin N. Macris_, Dec 15 2020