login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A289838 a(n) = A289815(n) * A289816(n). 2

%I

%S 1,2,2,3,6,6,3,6,6,4,10,10,12,30,30,12,30,30,4,10,10,12,30,30,12,30,

%T 30,5,14,14,15,42,42,15,42,42,20,70,70,60,210,210,60,210,210,20,70,70,

%U 60,210,210,60,210,210,5,14,14,15,42,42,15,42,42,20,70,70

%N a(n) = A289815(n) * A289816(n).

%C Each number k > 0 appears 2^omega(k) times (where omega = A001221).

%C a(A004488(n)) = a(n) for any n >= 0.

%C The number of distinct prime factors of a(n) equals the number of nonzero digits in the ternary representation of n.

%H Rémy Sigrist, <a href="/A289838/b289838.txt">Table of n, a(n) for n = 0..10000</a>

%e a(42) = A289815(42) * A289816(42) = 20 * 3 = 60.

%o (PARI) a(n) = my (v=1); \

%o for (o=2, oo, \

%o if (n==0, return (v)); \

%o if (gcd(v, o)==1 && omega(o)==1, \

%o if (n % 3, v *= o); \

%o n \= 3; \

%o ); \

%o );

%o (Python)

%o from sympy import floor, gcd, primefactors

%o def omega(n): return 0 if n==1 else len(primefactors(n))

%o def a(n):

%o v, o = 1, 2

%o while True:

%o if n==0: return v

%o if gcd(v, o)==1 and omega(o)==1:

%o if n%3: v*=o

%o n=floor(n/3)

%o o+=1

%o print map(a, xrange(101)) # _Indranil Ghosh_, Aug 02 2017

%Y Cf. A001221, A004488, A289815, A289816.

%K nonn,base

%O 0,2

%A _Rémy Sigrist_, Jul 13 2017

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 26 11:46 EDT 2019. Contains 322472 sequences. (Running on oeis4.)