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

A094340 a(n) = n-th partial sum of A094339 divided by A094339(n+1).

Original entry on oeis.org

2, 1, 1, 3, 2, 2, 4, 9, 5, 4, 3, 5, 5, 9, 5, 4, 8, 15, 8, 12, 27, 52, 7, 4, 2, 5, 3, 6, 106, 14, 5, 9, 5, 4, 6, 107, 180, 21, 362, 121, 183, 176, 69, 59, 150, 28, 151, 232, 19, 10, 2, 11, 9, 233, 360, 247, 304, 155, 244, 195, 98, 231, 174, 196, 50, 591, 296, 198, 51, 199, 160, 115
Offset: 1

Views

Author

Amarnath Murthy, May 17 2004

Keywords

Comments

Conjecture: Every natural number occurs in this sequence.

Crossrefs

Programs

  • Maple
    A094339 := proc(nmax) local a,n,sprev,i; a := [2] ; while nops(a) < nmax do sprev := add(i,i=a) ; n := 1 ; while sprev mod n <> 0 or n in a do n := n+1 ; od ; a := [op(a),n] ; od ; RETURN(a) ; end: A094340 := proc(a094339,n) add( op(i,a094339),i=1..n)/op(n+1,a094339) ; end: a094339 := A094339(100) ; for n from 1 to nops(a094339)-1 do printf("%d, ", A094340(a094339,n)) ; od ; # R. J. Mathar, Apr 30 2007

Extensions

Corrected and extended by R. J. Mathar, Apr 30 2007

A094341 Index of the occurrence of n in A094339.

Original entry on oeis.org

2, 1, 3, 5, 9, 4, 23, 6, 8, 10, 40, 7, 22, 30, 11, 15, 67, 19, 49, 13, 38, 42, 43, 14, 12, 56, 21, 46, 48, 18, 58, 16, 41, 68, 37, 20, 89, 57, 60, 55, 76, 63, 151, 78, 107, 96, 98, 17, 61, 65, 69, 71, 24, 103, 87, 64, 80, 74, 44, 83, 59, 92, 101, 94, 72, 91, 185, 142, 104, 45
Offset: 1

Views

Author

Amarnath Murthy, May 17 2004

Keywords

Crossrefs

Programs

  • Maple
    A094339 := proc(nmax) local a,n,sprev,i; a := [2] ; while nops(a) < nmax do sprev := add(i,i=a) ; n := 1 ; while sprev mod n <> 0 or n in a do n := n+1 ; od ; a := [op(a),n] ; od ; RETURN(a) ; end: a094339 := A094339(300) : n := 1 : while member(n,a094339,'w') do printf("%d, ",w) ; n := n+1 ; od : # R. J. Mathar, Apr 30 2007
  • Mathematica
    nmax = 70; s = {2};
    Do[AppendTo[s, Min[Select[Divisors[Total[s]], !MemberQ[s, #] &]]], {t, 2, 3 nmax}];
    a[n_] := FirstPosition[s, n][[1]];
    Table[a[n], {n, 1, nmax}] (* Jean-François Alcover, Oct 24 2023, after Ivan Neretin in A094339 *)

Extensions

Corrected and extended by R. J. Mathar, Apr 30 2007

A109890 a(1)=1; for n>1, a(n) is the smallest number not already present which is a divisor or a multiple of a(1)+...+a(n-1).

Original entry on oeis.org

1, 2, 3, 6, 4, 8, 12, 9, 5, 10, 15, 25, 20, 24, 16, 32, 48, 30, 18, 36, 27, 13, 7, 53, 106, 265, 159, 318, 212, 14, 107, 321, 214, 428, 642, 535, 35, 21, 181, 11, 33, 22, 23, 59, 70, 28, 151, 29, 19, 233, 466, 2563, 699, 932, 40, 26, 38, 31, 61, 39, 49, 98, 42
Offset: 1

Views

Author

Amarnath Murthy, Jul 13 2005

Keywords

Comments

Conjectured to be a rearrangement of the natural numbers.
For n>2, a(n) <= a(1)+...+a(n-1). Proof: a(1)+...+a(n-1) >= max { a(i), i=1..n-1}, so a(1)+...+a(n-1) is always a candidate for a(n). QED. So the definition may be changed to: a(1)=1, a(2)=2; for n>2, a(n) is the smallest number not already present which is a divisor of a(1)+...+a(n-1). - N. J. A. Sloane, Nov 05 2005
Except for first two terms, same as A094339. - David Wasserman, Jan 06 2009
A253443(n) = smallest missing number within the first n terms. - Reinhard Zumkeller, Jan 01 2015

Examples

			Let s(n) = A109735(n) = sum(a(1..n)):
.                   | divisors of s(n),
.                   | in brackets when occurring in a(1..n)
.   n | a(n) | s(n) | A027750(s(n),1..A000005(s(n)))
.  ---+------+------+---------------------------------------------------
.   1 |    1 |    1 | (1)
.   2 |    2 |    3 | (1)  3
.   3 |    3 |    6 | (1 2 3)  6
.   4 |    6 |   12 | (1 2 3)  4  (6)  12
.   5 |    4 |   16 | (1 2 4)  8 16
.   6 |    8 |   24 | (1 2 3 4 6 8)  12 24
.   7 |   12 |   36 | (1 2 3 4 6)  9  (12)  18 36
.   8 |    9 |   45 | (1 3)  5  (9)  15 45
.   9 |    5 |   50 | (1 2 5)  10 25 50
.  10 |   10 |   60 | (1 2 3 4 5 6 10 12)  15 20 30 60
.  11 |   15 |   75 | (1 3 5 15)  25 75
.  12 |   25 |  100 | (1 2 4 5 10)  20  (25)  50 100
.  13 |   20 |  120 | (1 2 3 4 5 6 8 10 12 15 20)  24 30 40 60 120
.  14 |   24 |  144 | (1 2 3 4 6 8 9 12)  16 18  (24)  36 48 72 144
.  15 |   16 |  160 | (1 2 4 5 8 10 16 20)  32 40 80 160
.  16 |   32 |  192 | (1 2 3 4 6 8 12 16 24 32)  48 64 96 192
.  17 |   48 |  240 | (.. 8 10 12 15 16 20 24)  30 40  (48)  60 80 120 240
.  18 |   30 |  270 | (1 2 3 5 6 9 10 15)  18 27  (30)  45 54 90 135 270
.  19 |   18 |  288 | (.. 6 8 9 12 16 18 24 32)  36  (48)  72 96 144 288
.  20 |   36 |  324 | (1 2 3 4 6 9 12 18)  27  (36)  54 81 108 162 324
.  21 |   27 |  351 | (1 3 9)  13  (27)  39 117 351
.  22 |   13 |  364 | (1 2 4)  7  (13)  14 26 28 52 91 182 364
.  23 |    7 |  371 | (1 7)  53 371
.  24 |   53 |  424 | (1 2 4 8 53)  106 212 424
.  25 |  106 |  530 | (1 2 5 10 53 106)  265 530  .
- _Reinhard Zumkeller_, Jan 05 2015
		

Crossrefs

Programs

  • Haskell
    import Data.List (insert)
    a109890 n = a109890_list !! (n-1)
    a109890_list = 1 : 2 : 3 : f (4, []) 6 where
       f (m,ys) z = g $ dropWhile (< m) $ a027750_row' z where
         g (d:ds) | elem d ys = g ds
                  | otherwise = d : f (ins [m, m + 1 ..] (insert d ys)) (z + d)
         ins (u:us) vs'@(v:vs) = if u < v then (u, vs') else ins us vs
    -- Reinhard Zumkeller, Jan 02 2015
    
  • Maple
    M:=2000; a:=array(1..M): a[1]:=1: a[2]:=2: as:=convert(a,set): b:=3: for n from 3 to M do t2:=divisors(b) minus as; t4:=sort(convert(t2,list))[1]; a[n]:=t4; b:=b+t4; as:={op(as),t4}; od: aa:=[seq(a[n],n=1..M)]:
  • Mathematica
    a[1] = 1; a[2] = 2; a[n_] := a[n] = Block[{t = Table[a[i], {i, n - 1}]}, s = Plus @@ t; d = Divisors[s]; l = Complement[d, t]; If[l != {}, k = First[l], k = s; While[Position[t, k] == {}, k += s]; k]]; Table[ a[n], {n, 40}] (* Robert G. Wilson v, Aug 12 2005 *)
  • Python
    from sympy import divisors
    A109890_list, s, y, b = [1, 2], 3, 3, set()
    for _ in range(1,10**3):
        for i in divisors(s):
            if i >= y and i not in b:
                A109890_list.append(i)
                s += i
                b.add(i)
                while y in b:
                    b.remove(y)
                    y += 1
                break # Chai Wah Wu, Jan 05 2015

Extensions

More terms from Erich Friedman, Aug 08 2005

A111241 a(n) = A109735(n)/A109890(n+1).

Original entry on oeis.org

1, 1, 3, 2, 2, 4, 9, 5, 4, 3, 5, 5, 9, 5, 4, 8, 15, 8, 12, 27, 52, 7, 4, 2, 5, 3, 6, 106, 14, 5, 9, 5, 4, 6, 107, 180, 21, 362, 121, 183, 176, 69, 59, 150, 28, 151, 232, 19, 10, 2, 11, 9, 233, 360, 247, 304, 155, 244, 195, 98, 231, 174, 196, 50, 591, 296, 198, 51, 199
Offset: 2

Views

Author

N. J. A. Sloane, Oct 30 2005

Keywords

Comments

This is always an integer for n>=2.
a(n) = 1 for n in A111315. When this happens A109890(n+1) makes a large jump. The corresponding values of A109890(n+1) are in A111316 (cf. A111242).

Examples

			A109735(4)=12, A109890(5)=4, so a(4) = 12/4 = 3.
		

Crossrefs

Programs

  • Mathematica
    nn = 71; c[_] := False;
    Array[Set[{a[#], c[#]}, {#, True}] &, 2]; s = a[1] + a[2];
    Reap[Do[k = SelectFirst[Divisors[s], ! c[#] &];
        c[k] = True; Sow[s/k];
    s += k, {n, 3, nn}] ][[-1, 1]] (* Michael De Vlieger, Apr 26 2024 *)

Formula

a(n) = A094340(n) for all n > 1. - David Wasserman, Jan 06 2009

A109736 Where n appears in A109890.

Original entry on oeis.org

1, 2, 3, 5, 9, 4, 23, 6, 8, 10, 40, 7, 22, 30, 11, 15, 67, 19, 49, 13, 38, 42, 43, 14, 12, 56, 21, 46, 48, 18, 58, 16, 41, 68, 37, 20, 89, 57, 60, 55, 76, 63, 151, 78, 107, 96, 98, 17, 61, 65, 69, 71, 24, 103, 87, 64, 80, 74, 44, 83, 59, 92, 101, 94, 72, 91, 185, 142, 104, 45
Offset: 1

Views

Author

N. J. A. Sloane and Nadia Heninger, Aug 11 2005

Keywords

Comments

a(10^n): 1, 10, 128, 1430, ... - Robert G. Wilson v, Aug 12 2005
a(n) = A094341(n) for 3 <= n <= 70. - Georg Fischer, Nov 02 2018
According to the remarks in A109890, A094339 and A109890 are essentially the same, just swapping the first 2 terms, so this here is a(n)=A094341(n) for n>=3. - R. J. Mathar, Jul 02 2025

Crossrefs

Programs

  • Haskell
    import Data.List (elemIndex); import Data.Maybe (fromJust)
    a109736 = (+ 1) . fromJust . (`elemIndex` a109890_list)
    -- Reinhard Zumkeller, Jan 01 2015
  • Mathematica
    a[1] = 1; a[2] = 2; a[n_] := a[n] = Block[{t = Table[a[i], {i, n - 1}]}, s = Plus @@ t; d = Divisors[s]; l = Complement[d, t]; If[l != {}, k = First[l], k = s; While[Position[t, k] == {}, k += s]; k]]; t = Table[a[n], {n, 250}]; Table[k = 1; While[ t[[k]] != n, k++ ]; k, {n, 70}] (* Robert G. Wilson v, Aug 12 2005 *)

Extensions

More terms from Robert G. Wilson v, Aug 12 2005
Showing 1-5 of 5 results.