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.

A238530 Position of first occurrence of n in A238529 (Recursive depth of n modulo sopfr(n)).

Original entry on oeis.org

2, 8, 22, 166, 778, 4962, 29922, 179682, 688078, 7060198, 42361338, 674524645
Offset: 1

Views

Author

J. Stauduhar, Feb 28 2014

Keywords

Examples

			The depth of 22 is 3 because 22->9->3, that is, 22 mod (11 + 2) = 9, 9 mod (3 + 3) = 3, and 3 mod (3) = 0, and 22 is the smallest number to have a depth of 3.
a(10) = 7060198, because 7060198->3530097->392185->78417->8665->1713->565->93->25->5
		

Programs

  • Python
    def primfacs(n):
        i = 2
        primfacs = []
        while i * i <= n:
            while n % i == 0:
                primfacs.append(i)
                n = n / i
            i = i + 1
        if n > 1:
            primfacs.append(n)
        return primfacs
    def sopfr(n):
        plist = list(primfacs(n))
        l = len(plist)
        s = 0
        while l > 0:
            s += plist[l - 1]
            l -= 1
        return s
    def sd(n):
        d = 1
        s = n % sopfr(n)
        if s > 1:
            d += sd(s)
        return d
    n=2
    max=1000
    rec = 0
    lst = []
    while n <= max:
        r = sd(n)
        if r > rec:
            lst.append(n)
            rec = r
        n += 1
    print(lst)

Extensions

a(12) from Michel Marcus, Mar 26 2014

A238714 Final divisor of A238529(n).

Original entry on oeis.org

2, 3, 4, 5, 5, 7, 2, 3, 3, 11, 5, 13, 5, 7, 8, 17, 2, 19, 2, 10, 3, 23, 5, 5, 11, 9, 5, 29, 10, 31, 2, 5, 7, 11, 5, 37, 17, 7, 7, 41, 5, 43, 5, 11, 10, 47, 4, 7, 2, 11, 17, 53, 3, 7, 4, 13, 9, 59, 12, 61, 29, 11, 4, 11, 2, 67, 5, 17, 14, 71, 12, 73, 11, 3, 7, 5, 5
Offset: 2

Views

Author

J. Stauduhar, Mar 03 2014

Keywords

Comments

Conjecture: Every integer greater than 1, except 6, is an element of the sequence.

Examples

			a(8) = 2, because 8 mod sopfr(8) = 8 mod 6 = 2, and 2 mod sopfr(2) = 2 mod 2 = 0, and 2 is the last divisor used.
a(21) = 10, because 21 mod sopfr(21) = 21 mod 10 = 1, and 10 is the last divisor used.
		

Crossrefs

Cf. A238529.

Programs

  • Python
    def primfacs(n):
       i = 2
       primfac = []
       while i * i <= n:
           while n % i == 0:
               primfac.append(i)
               n //= i
           i += 1
       if n > 1:
           primfac.append(n)
       return primfac
    def sopfr(n):
       plist = primfacs(n)
       l = len(plist)
       s = 0
       while l > 0:
           s += plist[l - 1]
           l -= 1
       return s
    n = 2
    max = 1000
    lst = []
    while n <= max:
       rem = n
       while rem > 1:
           last = sopfr(rem)
           rem = rem % last
       lst.append(last)
       n += 1
    print(lst)

A238525 n modulo sopfr(n), where sopfr(n) is the sum of the prime factors of n, with multiplicity.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 2, 3, 3, 0, 5, 0, 5, 7, 0, 0, 2, 0, 2, 1, 9, 0, 6, 5, 11, 0, 6, 0, 0, 0, 2, 5, 15, 11, 6, 0, 17, 7, 7, 0, 6, 0, 14, 1, 21, 0, 4, 7, 2, 11, 1, 0, 10, 7, 4, 13, 27, 0, 0, 0, 29, 11, 4, 11, 2, 0, 5, 17, 0, 0, 0, 0, 35, 10, 7, 5, 6, 0, 2, 9, 39
Offset: 2

Views

Author

J. Stauduhar, Feb 28 2014

Keywords

Comments

a(A036844(n)) = 0. - Reinhard Zumkeller, Jul 21 2014

Examples

			a(6) = 1, because 6 mod sopfr(6) = 6 mod 5 = 1.
		

Crossrefs

Programs

  • Haskell
    a238525 n = mod n $ a001414 n  -- Reinhard Zumkeller, Jul 21 2014
  • Mathematica
    Table[Mod[n, Apply[Dot, Transpose[FactorInteger[n]]]], {n, 105}] (* Wouter Meeussen, Mar 01 2014 *)
    mms[n_]:=Mod[n,Total[Flatten[Table[#[[1]],#[[2]]]&/@FactorInteger[ n]]]]; Array[mms,90,2] (* Harvey P. Dale, May 25 2016 *)

Formula

a(n) = n mod A001414(n).

A238621 Position of first occurrence of n in A238525.

Original entry on oeis.org

1, 6, 8, 9, 48, 12, 24, 15, 120, 22, 54, 26, 90, 57, 44, 34, 156, 38, 114, 85, 228, 46, 232, 87, 348, 93, 138, 58, 318, 62, 372, 111, 333, 265, 354, 74, 366, 129, 296, 82, 369, 86, 402, 667, 387, 94, 328, 159, 438, 244, 530, 106, 423, 177, 474, 183, 1416, 118, 498, 122, 742, 201, 590, 415, 534, 134, 610, 219
Offset: 0

Views

Author

Robert G. Wilson v, Mar 01 2014

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := Mod[n, Dot @@ Transpose@ FactorInteger@ n]; t = Table[0, {1000}]; k = 1; While[k < 100001, a = f[k]; If[a < 1001 && t[[a]] == 0, t[[a]] = k; Print[{a, k}]]; k++]; t
Showing 1-4 of 4 results.