login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A329277 a(n) is the fixed point reached by iterating Euler's gradus function A275314 starting at n. 0
1, 2, 3, 3, 5, 3, 7, 3, 5, 3, 11, 5, 13, 3, 7, 5, 17, 3, 19, 7, 5, 5, 23, 3, 5, 3, 7, 5, 29, 3, 31, 3, 13, 3, 11, 7, 37, 7, 7, 3, 41, 3, 43, 13, 5, 3, 47, 7, 13, 3, 19, 7, 53, 3, 7, 3, 5, 3, 59, 5, 61, 3, 11, 7, 17, 3, 67, 19, 5, 5, 71, 3, 73, 7, 11, 5, 17, 5, 79 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

LINKS

Table of n, a(n) for n=1..79.

MATHEMATICA

gradus[n_] := 1 + Plus @@ ((First[#] - 1) * Last[#] & /@ FactorInteger[n]); a[n_] := FixedPoint[gradus, n]; Array[a, 100] (* Amiram Eldar, Nov 11 2019 *)

PROG

(Python 3)

from gmpy2 import is_prime

from sympy import factorint

def gradus(n):

    sum  = 0

    factors = factorint(n)

    for p, a in factors.items():

        sum += (p - 1)*a

    return sum + 1

if __name__ == "__main__":

    glist = []

    for x in range(1, 80):

        glist.append(gradus(x))

    while True:

        for p in glist:

            a = 0

            if not is_prime(p):

                glist = [gradus(x) for x in glist]

                a = 1

        if a == 0:

            break

    print(', '.join([str(x) for x in glist]))

(PARI) g(n) = my (f=factor(n)); 1+sum(k=1, #f~, f[k, 2]*(f[k, 1]-1))

a(n) = while (n!=n=g(n), ); n \\ Rémy Sigrist, Dec 03 2019

CROSSREFS

Cf. A275314, A329071.

Sequence in context: A214127 A111607 A327124 * A117531 A275940 A105555

Adjacent sequences:  A329274 A329275 A329276 * A329278 A329279 A329280

KEYWORD

nonn

AUTHOR

Daniel Hoyt, Nov 11 2019

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified February 29 09:35 EST 2020. Contains 332355 sequences. (Running on oeis4.)