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-4 of 4 results.

A011264 In the prime factorization of n, increment even powers and decrement odd powers (multiplicative).

Original entry on oeis.org

1, 1, 1, 8, 1, 1, 1, 4, 27, 1, 1, 8, 1, 1, 1, 32, 1, 27, 1, 8, 1, 1, 1, 4, 125, 1, 9, 8, 1, 1, 1, 16, 1, 1, 1, 216, 1, 1, 1, 4, 1, 1, 1, 8, 27, 1, 1, 32, 343, 125, 1, 8, 1, 9, 1, 4, 1, 1, 1, 8, 1, 1, 27, 128, 1, 1, 1, 8, 1, 1, 1, 108, 1, 1, 125, 8, 1, 1, 1, 32, 243, 1, 1, 8, 1, 1, 1, 4, 1, 27, 1, 8, 1, 1
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Haskell
    a011264 n = product $ zipWith (^)
                          (a027748_row n) (map a004442 $ a124010_row n)
    -- Reinhard Zumkeller, Jun 23 2013
    
  • Mathematica
    f[n_, k_] := n^(If[EvenQ[k], k + 1, k - 1]); Table[Times @@ f @@@ FactorInteger[n], {n, 94}] (* Jayanta Basu, Aug 14 2013 *)
  • PARI
    a(n) = {my(f = factor(n)); prod(i = 1, #f~, f[i,1]^if(f[i,2]%2, f[i,2]-1, f[i,2]+1));} \\ Amiram Eldar, Jan 07 2023

Formula

a(n) = Product_{k=1..A001221(n)} (A027748(n,k)^A004442(A124010(n,k))). - Reinhard Zumkeller, Jun 23 2013
From Amiram Eldar, Jan 07 2023: (Start)
a(n) = n^2/A011262(n).
a(n) = n*A007947(n)/A007913(n)^2.
a(n) = n*A336643(n)/A007913(n).
a(n) = A356191(n)/A007913(n). (End)
Dirichlet g.f.: zeta(2*s-2) * Product_{p prime} (1 + 1/p^s + 1/p^(2*s-3) - 1/p^(2*s-2)). - Amiram Eldar, Sep 21 2023
From Vaclav Kotesovec, May 06 2025: (Start)
Dirichlet g.f.: zeta(2*s-3) * Product_{p prime} (1 + (p-1)*p^(3-2*s) + p^(1-s) - (p-1)*(p^s + p^3)/(p^(2*s) - p^2)).
Sum_{k=1..n} a(k) ~ n^2/4. (End)

A328621 Multiplicative with a(p^e) = p^(2e mod p).

Original entry on oeis.org

1, 1, 9, 1, 25, 9, 49, 1, 3, 25, 121, 9, 169, 49, 225, 1, 289, 3, 361, 25, 441, 121, 529, 9, 625, 169, 1, 49, 841, 225, 961, 1, 1089, 289, 1225, 3, 1369, 361, 1521, 25, 1681, 441, 1849, 121, 75, 529, 2209, 9, 2401, 625, 2601, 169, 2809, 1, 3025, 49, 3249, 841, 3481, 225, 3721, 961, 147, 1, 4225, 1089, 4489, 289, 4761, 1225, 5041, 3, 5329
Offset: 1

Views

Author

Antti Karttunen, Oct 23 2019

Keywords

Crossrefs

Cf. A011262, A327938, A328618 (a bijective variant).

Programs

  • PARI
    A328621(n) = { my(f = factor(n)); for(k=1, #f~, f[k,2] = ((2*f[k,2])%f[k,1])); factorback(f); };

A227324 Result of changing both the prime indices and the exponents in the prime factorization of n: increment odd values, decrement even values.

Original entry on oeis.org

1, 9, 4, 3, 49, 36, 25, 81, 2, 441, 169, 12, 121, 225, 196, 27, 361, 18, 289, 147, 100, 1521, 841, 324, 7, 1089, 16, 75, 529, 1764, 1369, 729, 676, 3249, 1225, 6, 961, 2601, 484, 3969, 1849, 900, 1681, 507, 98, 7569, 2809, 108, 5, 63, 1444, 363, 2209, 144
Offset: 1

Views

Author

Alex Ratushnyak, Jul 07 2013

Keywords

Comments

A self-inverse permutation on the positive integers: a(a(n)) = n.

Examples

			n = 2^3 => a(n) = 3^4 = 81.
n = 3^2 => a(n) = 2^1 = 2.
		

Crossrefs

Programs

  • Maple
    a:= n-> mul(ithprime(i[1])^i[2], i=map(x->map(y->y-1+2*irem(y, 2),
            [numtheory[pi](x[1]), x[2]]), ifactors(n)[2])):
    seq(a(n), n=1..100);  # Alois P. Heinz, Jul 17 2013
  • Mathematica
    a[n_] := If[n == 1, 1, Product[{p, e} = pe; Prime[BitXor[PrimePi[p] - 1, 1] + 1]^(BitXor[e - 1, 1] + 1), {pe, FactorInteger[n]}]];
    Array[a, 100] (* Jean-François Alcover, May 31 2019, after Andrew Howroyd *)
  • PARI
    a(n)={my(f=factor(n)); prod(i=1, #f~, my(p=f[i,1], e=f[i,2]); prime( bitxor( primepi(p)-1, 1)+1)^(bitxor(e-1, 1)+1))} \\ Andrew Howroyd, Jul 23 2018
    
  • Python
    primes = [2]*2
    primes[1] = 3
    def addPrime(k):
      for p in primes:
        if k%p==0:  return
        if p*p > k:  break
      primes.append(k)
    for n in range(5, 1000000, 6):
      addPrime(n)
      addPrime(n+2)
    for n in range(1,99):
      p = 1
      j = n
      i = 0
      while j>1:
        e = 0
        while j % primes[i] == 0:
          j /= primes[i]
          e+=1
        if e:
          e = ((e-1)^1) + 1
          p*= primes[i^1]**e
        i += 1
      print(str(p), end=', ')

Formula

Sum_{k=1..n} a(k) ~ c * n^3, where c = (1/3) * Product_{p prime} ((p-1)*(p^6 + q(p) +(p^3-1)*q(p)^2))/(p^7 - p*q(p)^2) = 0.3120270364..., where q(p) = nextprime(p) = A151800(p) if p has an odd index, and q(p) = prevprime(p) = A151799(p) otherwise. - Amiram Eldar, Sep 17 2023

Extensions

Keyword:mult added by Andrew Howroyd, Jul 23 2018

A366423 Multiplicative with a(p^e) = p^(e+1-p) if p|e, and p^(e+1) otherwise.

Original entry on oeis.org

1, 4, 9, 2, 25, 36, 49, 16, 27, 100, 121, 18, 169, 196, 225, 8, 289, 108, 361, 50, 441, 484, 529, 144, 125, 676, 3, 98, 841, 900, 961, 64, 1089, 1156, 1225, 54, 1369, 1444, 1521, 400, 1681, 1764, 1849, 242, 675, 2116, 2209, 72, 343, 500, 2601, 338, 2809, 12, 3025
Offset: 1

Views

Author

Amiram Eldar, Nov 17 2023

Keywords

Comments

A permutation of the positive integers. 1 is the only fixed point.
a(n) is a powerful number (A001694) if and only if n is not in A100717.

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := p^(e + 1 + If[Mod[e, p] == 0, -p, 0]); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100]
  • PARI
    a(n) = {my(f = factor(n)); prod(i = 1, #f~, f[i,1]^(f[i,2] + 1 + if(!(f[i,2]%f[i,1]), -f[i,1])));}

Formula

a(2^e) = 2^A103889(e).
a(3^e) = 3^A130508(e).
A007947(a(n)) = A007947(n).
a(A051674(n)) = A000040(n).
a(n) is squarefree (A005117) if and only if n is in A048102.
a(A048102(n)) = A007947(A048102(n)).
a(n) == 0 (mod n) if and only if n is not in A342090.
a(n) | n if and only if n is in A072873.
Sum_{k=1..n} a(k) ~ c * n^3 / 3, where c = Product_{p prime} (1 - 1/p + 1/(1 + p) - (p-1)/(p^p * (1 + p^p))) = 0.660264348361... .
Showing 1-4 of 4 results.