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

A308195 a(n) = smallest m such that A308194(m) = n, or -1 if no such m exists.

Original entry on oeis.org

5, 6, 8, 7, 10, 11, 23, 29, 101, 137, 757, 1621, 3238, 15537, 44851, 155269, 784522, 2495326, 7485969, 51719803, 119775247, 2017072213, 5629349191, 40094417851
Offset: 0

Views

Author

N. J. A. Sloane, Jun 14 2019

Keywords

Comments

It seems plausible that m exists for all n >= 0.
If a(n) = 2k, then a(n+1) <= k^2. If a(n) = 2k+1, then a(n+1) <= k*(k+1). Thus m exists for all n >= 0. - Chai Wah Wu, Jun 15 2019
Conjecture: all terms, except for a(2), are either primes (A000040) or squarefree semiprimes (A006881). - Chai Wah Wu, Jun 18 2019
From Chai Wah Wu, Jun 22 2019: (Start)
If n != 1, then a(n+1) <= (a(n)-prevprime(a(n)))*prevprime(a(n)) where prevprime is A151799.
Proof: Let m = (a(n)-prevprime(a(n)))*prevprime(a(n)). By Chebyshev's theorem (Bertrand's postulate), a(n)-prevprime(a(n)) <= prevprime(a(n)) and thus A063655(m) = (a(n)-prevprime(a(n))) + prevprime(a(n)) = a(n). The only exception is when a(n) = 6. In this case m = 5, and A308194(5) = 0 even though A063655(5) = 6.
For n = 0, 2, 3, 11 and 17, this upper bound on a(n+1) is achieved, i.e., a(n+1) = (a(n)-prevprime(a(n)))*prevprime(a(n)).
Conjecture: a(n+1) = (a(n)-prevprime(a(n)))*prevprime(a(n)) infinitely often.
(End)

Crossrefs

Programs

  • C
    See Links section.

Extensions

a(14)-a(20) from Rémy Sigrist, Jun 14 2019
a(21) from Chai Wah Wu, Jun 17 2019
a(22) from Chai Wah Wu, Jun 24 2019
a(23) from Giovanni Resta, Jun 25 2019

A308190 Number of steps to reach 5 when iterating x -> A111234(x) starting at x=n.

Original entry on oeis.org

0, 1, 3, 2, 2, 4, 4, 3, 4, 3, 3, 5, 6, 5, 5, 4, 5, 5, 5, 4, 5, 4, 4, 6, 8, 7, 7, 6, 4, 6, 4, 5, 7, 6, 6, 6, 7, 6, 6, 5, 6, 6, 6, 5, 4, 5, 5, 7, 10, 9, 6, 8, 6, 8, 8, 7, 6, 5, 5, 7, 6, 5, 7, 6, 5, 8, 8, 7, 8, 7, 7, 7, 6, 8, 8, 7, 8, 7, 7, 6, 6, 7, 7, 7, 8, 7, 5, 6, 7, 5, 5, 6, 7, 6, 6, 8, 12
Offset: 5

Views

Author

N. J. A. Sloane, Jun 14 2019

Keywords

Comments

It is easy to show that every number n >= 5 eventually reaches 5. This was conjectured by Ali Sada. For A111234 sends a composite n > 5 to a smaller number, and sends a prime > 5 to a smaller number in two steps. Furthermore no number >= 5 can reach a number less than 5. So all numbers >= 5 eventually reach 5.

References

Crossrefs

Programs

  • Mathematica
    a[n_] := Module[{c = 0, x = n, y}, While[x != 5, y = Min[FactorInteger[x][[All, 1]]]; x = y + Quotient[x, y]; c++]; c];
    Table[a[n], {n, 5, 100}] (* Jean-François Alcover, Jun 15 2019, from Python *)
  • Python
    from sympy import factorint
    def A308190(n):
        c, x = 0, n
        while x != 5:
            y = min(factorint(x))
            x = y + x//y
            c += 1
        return c # Chai Wah Wu, Jun 14 2019
Showing 1-2 of 2 results.