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.

Showing 1-3 of 3 results.

A295666 a(n) = Product_{d|n, gcd(d,n/d) is prime} gcd(d,n/d).

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 4, 3, 1, 1, 4, 1, 1, 1, 4, 1, 9, 1, 4, 1, 1, 1, 16, 5, 1, 9, 4, 1, 1, 1, 4, 1, 1, 1, 36, 1, 1, 1, 16, 1, 1, 1, 4, 9, 1, 1, 16, 7, 25, 1, 4, 1, 81, 1, 16, 1, 1, 1, 16, 1, 1, 9, 4, 1, 1, 1, 4, 1, 1, 1, 144, 1, 1, 25, 4, 1, 1, 1, 16, 9, 1, 1, 16, 1, 1, 1, 16, 1, 81, 1, 4, 1, 1, 1, 16, 1, 49, 9, 100, 1, 1, 1, 16, 1
Offset: 1

Views

Author

Antti Karttunen, Nov 26 2017

Keywords

Examples

			For n = 12, with divisors 1, 2, 3, 4, 6, 12, we select from the sequence gcd(1,12/1), gcd(2,12/2), gcd(3,12/3), gcd(4,12/4), gcd(6,12/6), gcd(12,12/12) = 1, 2, 1, 1, 2, 1 only those that are primes, namely the two 2's, and form their product, thus a(12) = 2*2 = 4.
For n = 100, with divisors 1, 2, 4, 5, 10, 20, 25, 50, 100, we select from the sequence gcd(1,100/1), gcd(2,100/2), gcd(4,100/4), gcd(5,100/5), gcd(10,100/10), gcd(20,100/20), gcd(25,100/25), gcd(50,100/50), gcd(100,100/100) = 1, 2, 1, 5, 10, 5, 1, 2, 1, only those that are primes, namely 2, 5, 5 and 2, thus a(100) = 2*5*5*2 = 100.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=Product[GCD[i,n/i]^Boole[PrimeQ[GCD[i,n/i]]],{i,Divisors[n]}]; Array[a,105] (* Stefano Spezia, Feb 20 2024 *)
  • PARI
    A295666(n) = { my(m=1,p); fordiv(n, d, p = gcd(d, n/d); if(isprime(p), m *= p)); m; };

Formula

a(n) = Product_{d|n} gcd(d,n/d)^A010051(gcd(d,n/d)).
a(n) = A295665(A294876(n)).
Other identities. For all n >= 1:
A001221(a(n)) = A056170(n) = A001221(A003557(n)).

A294897 a(n) = Product_{d|n, gcd(d,n/d)>1} prime(A101296(gcd(d,n/d))-1).

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 4, 2, 1, 1, 4, 1, 1, 1, 12, 1, 4, 1, 4, 1, 1, 1, 16, 2, 1, 4, 4, 1, 1, 1, 36, 1, 1, 1, 80, 1, 1, 1, 16, 1, 1, 1, 4, 4, 1, 1, 144, 2, 4, 1, 4, 1, 16, 1, 16, 1, 1, 1, 16, 1, 1, 4, 252, 1, 1, 1, 4, 1, 1, 1, 1600, 1, 1, 4, 4, 1, 1, 1, 144, 12, 1, 1, 16, 1, 1, 1, 16, 1, 16, 1, 4, 1, 1, 1, 1296, 1, 4, 4, 80, 1, 1, 1, 16, 1
Offset: 1

Views

Author

Antti Karttunen, Nov 21 2017

Keywords

Crossrefs

Cf. A005117 (the positions of ones).
Cf. also A292258 (A292259), A293515, A294875 for similar filter sequences.

Programs

  • PARI
    up_to = 16384
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); };  \\ This function from Charles R Greathouse IV, Aug 17 2011
    v101296 = rgs_transform(vector(up_to, n, A046523(n)));
    A101296(n) = v101296[n];
    A294897(n) = { my(m=1); fordiv(n,d,if(gcd(d,n/d)>1, m *= prime(A101296(gcd(d,n/d))-1))); m; };

Formula

a(n) = Product_{d|n} A008578(A101296(gcd(d,n/d))).
For n >= 1, A001222(a(n)) = A048105(n).

A295879 Multiplicative with a(p) = 1, a(p^e) = prime(e-1) if e > 1.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 3, 2, 1, 1, 2, 1, 1, 1, 5, 1, 2, 1, 2, 1, 1, 1, 3, 2, 1, 3, 2, 1, 1, 1, 7, 1, 1, 1, 4, 1, 1, 1, 3, 1, 1, 1, 2, 2, 1, 1, 5, 2, 2, 1, 2, 1, 3, 1, 3, 1, 1, 1, 2, 1, 1, 2, 11, 1, 1, 1, 2, 1, 1, 1, 6, 1, 1, 2, 2, 1, 1, 1, 5, 5, 1, 1, 2, 1, 1, 1, 3, 1, 2, 1, 2, 1, 1, 1, 7, 1, 2, 2, 4, 1, 1, 1, 3, 1, 1, 1, 6, 1, 1, 1, 5, 1, 1, 1, 2, 2, 1, 1, 3, 2, 1, 1, 2, 3, 2, 1, 13
Offset: 1

Views

Author

Antti Karttunen, Nov 29 2017

Keywords

Comments

This sequence can be used as a filter. It matches at least to the following sequences related to the counting of various non-unitary prime divisors:
For all i, j:
a(i) = a(j) => A056170(i) = A056170(j), as A056170(n) = A001222(a(n)).
a(i) = a(j) => A162641(i) = A162641(j).
a(i) = a(j) => A295659(i) = A295659(j).
a(i) = a(j) => A295662(i) = A295662(j).
a(i) = a(j) => A295883(i) = A295883(j), as A295883(n) = A007949(a(n)).
a(i) = a(j) => A295884(i) = A295884(j).
An encoding of the prime signature of A057521(n), the powerful part of n. - Peter Munn, Apr 06 2024

Crossrefs

Differs from A000688 for the first time at n=128, where a(128) = 13, while A000688(128) = 15.

Programs

  • Mathematica
    Array[Apply[Times, FactorInteger[#] /. {p_, e_} /; p > 0 :> Which[p == 1, 1, e == 1, 1, True, Prime[e - 1]]] &, 128] (* Michael De Vlieger, Nov 29 2017 *)
  • PARI
    a(n) = {my(f = factor(n)); prod(i = 1, #f~, if(f[i,2] == 1, 1, prime(f[i,2]-1)));} \\ Amiram Eldar, Nov 18 2022

Formula

a(1) = 1; for n>1, if n = Product prime(i)^e(i), then a(n) = Product A008578(e(i)).
a(n) = A064989(A181819(n)).
a(n) = A181819(A003557(n)). - Antti Karttunen, Apr 03 2022
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = Product_{p prime} (1 + 1/p^2 + Sum_{k>=1} (prime(k+1)-prime(k))/p^(k+2)) = 2.208... . - Amiram Eldar, Nov 18 2022
Showing 1-3 of 3 results.