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.

A374911 a(n) = a(2^n mod n) + a(3^n mod n), with a(0) = 1.

Original entry on oeis.org

1, 2, 3, 4, 3, 7, 7, 7, 3, 4, 7, 7, 7, 7, 7, 10, 3, 7, 11, 7, 5, 10, 7, 7, 7, 18, 7, 8, 21, 7, 7, 7, 3, 11, 7, 18, 25, 7, 7, 11, 5, 7, 17, 7, 10, 18, 7, 7, 14, 14, 21, 11, 10, 7, 29, 14, 7, 11, 7, 7, 13, 7, 7, 11, 3, 17, 7, 7, 10, 11, 21, 7, 7, 7, 7, 21, 10, 32, 11, 7, 5, 6, 7, 7, 14, 10, 7, 11, 19
Offset: 0

Views

Author

Bryle Morga, Jul 23 2024

Keywords

Comments

Conjectured to contain all positive integers. Here are the indexes where each of the first few positive integers appear:
1: 0
2: 1
3: 2, 4, 8, 16, 32, ... (2^k, k > 0)
4: 3, 9, ...
5: 20, 40, 80, 272, 320, 328, ...
6: 81, 66469, 144937, ...
7: 5, 6, 7, 10, 11, 12, 13,... (all primes appear except 2 and 3)
8: 27, 301, 729, 1099, 2107, 2187, 85085, 1594323, ...
Most solutions to a(n) = 5 seem to be divisible by 5 and all of them seem to be even. Why?
Are 3 and 9 the only solutions to a(n) = 4?

Crossrefs

Programs

  • Mathematica
    a[0]=1; a[n_]:=a[PowerMod[2,n,n]]+a[PowerMod[3,n,n]]; Array[a,89,0] (* Stefano Spezia, Jul 23 2024 *)
  • PARI
    a(n) = if (n==0, 1, a(lift(Mod(2,n)^n)) + a(lift(Mod(3,n)^n))); \\ Michel Marcus, Jul 25 2024
  • Python
    def a(n):
      return 1 if n == 0 else a(pow(2, n, n)) + a(pow(3, n, n))
    

Formula

a(p) = 7 for primes p except 2 and 3.
a(2^n) = 3 for n > 0.