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.

A289320 a(n) = A289310(n)^2 + A289311(n)^2.

Original entry on oeis.org

1, 5, 10, 25, 26, 50, 50, 125, 100, 130, 122, 250, 170, 250, 260, 625, 290, 500, 362, 650, 500, 610, 530, 1250, 676, 850, 1000, 1250, 842, 1300, 962, 3125, 1220, 1450, 1300, 2500, 1370, 1810, 1700, 3250, 1682, 2500, 1850, 3050, 2600, 2650, 2210, 6250, 2500
Offset: 1

Views

Author

Rémy Sigrist, Jul 02 2017

Keywords

Comments

This sequence is totally multiplicative.
a(n) > n^2 for any n > 1.
If n is a square, then a(n) is a square.
If a(n) and a(m) are squares, then a(n*m) is a square.
a(n) is also a square for nonsquares n = 42, 168, 246, 287, 378, 672, 984, 1050, 1148, 1434, 1512, 1673, 2058, 2214, 2583, 2688, ...

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := (p^2 + 1)^e; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 50] (* Amiram Eldar, Nov 13 2022 *)
  • PARI
    a(n) = my (f=factor(n)); return (prod(i=1, #f~, (1 + f[i,1]^2) ^ f[i,2]))
    
  • Python
    from sympy import factorint
    from operator import mul
    from functools import reduce
    def a(n): return 1 if n==1 else reduce(mul, [(1 + p**2)**k for p, k in factorint(n).items()])
    print([a(n) for n in range(1, 101)]) # Indranil Ghosh, Aug 03 2017

Formula

Totally multiplicative, with a(p^k) = (1 + p^2)^k for any prime p and k > 0.
Sum_{k=1..n} a(k) ~ c * n^3, where c = 2/(Pi^2 * Product_{p prime} (1 - 1/p^2 - 1/p^3 - 1/p^4)) = 0.4778963213... . - Amiram Eldar, Nov 13 2022
Sum_{n>=1} 1/a(n) = 15/Pi^2 (A082020). - Amiram Eldar, Dec 15 2022

A289311 Let f be the multiplicative function satisfying f(p^k) = (1 + p*I)^k for any prime p and k > 0 (where I^2 = -1); a(n) = the imaginary part of f(n).

Original entry on oeis.org

0, 2, 3, 4, 5, 5, 7, -2, 6, 7, 11, -5, 13, 9, 8, -24, 17, -10, 19, -11, 10, 13, 23, -35, 10, 15, -18, -17, 29, -20, 31, -38, 14, 19, 12, -50, 37, 21, 16, -57, 41, -30, 43, -29, -34, 25, 47, -45, 14, -38, 20, -35, 53, -70, 16, -79, 22, 31, 59, -80, 61, 33, -50
Offset: 1

Views

Author

Rémy Sigrist, Jul 02 2017

Keywords

Comments

See A289310 for the real part of f and additional comments.
See A289320 for the square of the norm of f.
a(p) = p for any prime p.
The numbers 4 and 2700 are composite fixed points.
If a(n) = 0, then a(n^k) = 0 for any k > 0.
a(n) = 0 iff Sum_{i=1..k} ( arctan(p_i) * e_i ) = Pi * j for some integer j (where Product_{i=1..k} p_i^e_i is the prime factorization of n).
a(n) = 0 for n = 1, 378, 1296, 142884, 489888, 639846, 1679616, 1873638, ...
As a(378) = 0 and 378 = 2 * 3^3 * 7, we have arctan(2) + arctan(3)*3 + arctan(7) = j * Pi (with j = 2).

Examples

			f(12) = f(2^2 * 3) = (1 + 2*I)^2 * (1 + 3*I) = -15 - 5*I, hence a(12) = -5.
		

Crossrefs

Programs

  • Mathematica
    Array[Im[Times @@ Map[(1 + #1 I)^#2 & @@ # &, FactorInteger@ #]] - Boole[# == 1] &, 63] (* Michael De Vlieger, Jul 03 2017 *)
  • PARI
    a(n) = my (f=factor(n)); imag (prod(i=1, #f~, (1 + f[i,1]*I) ^ f[i,2]))

A351464 Let f be multiplicative with f(prime(k)^e) = k + e*i for any k, e > 0 (where i denotes the imaginary unit); a(n) is the real part of f(n). See A351465 for the imaginary part.

Original entry on oeis.org

1, 1, 2, 1, 3, 1, 4, 1, 2, 2, 5, 0, 6, 3, 5, 1, 7, 0, 8, 1, 7, 4, 9, -1, 3, 5, 2, 2, 10, 0, 11, 1, 9, 6, 11, -2, 12, 7, 11, 0, 13, 1, 14, 3, 4, 8, 15, -2, 4, 1, 13, 4, 16, -1, 14, 1, 15, 9, 17, -5, 18, 10, 6, 1, 17, 2, 19, 5, 17, 4, 20, -4, 21, 11, 4, 6, 19, 3
Offset: 1

Views

Author

Rémy Sigrist, Feb 11 2022

Keywords

Comments

Apparently, each integer (from Z) appears in this sequence.

Examples

			For n = 42:
- 42 = 2 * 3 * 7 = prime(1)^1 * prime(2)^1 * prime(4)^1,
- f(42) = (1+i) * (2+i) * (4+i) = 1 + 13*i,
- and a(42) = 1.
		

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; uses numtheory;
          mul(pi(i[1])+i[2]*I, i=ifactors(n)[2])
        end:
    a:= n-> Re(b(n)):
    seq(a(n), n=1..78);  # Alois P. Heinz, Feb 15 2022
  • Mathematica
    f[p_, e_] := PrimePi[p] + e*I; a[1] = 1; a[n_] := Re[Times @@ f @@@ FactorInteger[n]]; Array[a, 100] (* Amiram Eldar, Feb 15 2022 *)
  • PARI
    a(n) = { my (f=factor(n), p=f[,1]~, e=f[,2]~); real(prod (k=1, #p, primepi(p[k]) + I*e[k])) }
Showing 1-3 of 3 results.