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.

User: Will Nicholes

Will Nicholes's wiki page.

Will Nicholes has authored 46 sequences. Here are the ten most recent ones:

A377947 Unfriendly EKG sequence: a(1) = 1; a(2) = 3; for n > 2, a(n) = least number not already used which shares a factor with a(n-1) and is less than half or more than twice a(n-1).

Original entry on oeis.org

1, 3, 9, 21, 6, 2, 8, 18, 4, 10, 22, 46, 12, 26, 54, 14, 30, 5, 15, 33, 11, 44, 16, 34, 70, 7, 28, 58, 20, 42, 86, 24, 50, 102, 17, 51, 105, 25, 55, 115, 23, 69, 27, 57, 19, 76, 32, 66, 134, 36, 74, 150, 35, 75, 153, 39, 13, 52, 106, 38, 78, 158, 40, 82, 166, 48, 98, 198, 45, 93, 31, 124
Offset: 1

Author

Will Nicholes, Nov 11 2024

Keywords

Examples

			a(3) = 9 since it is the least unused number that shares a factor with a(2) = 3 and is less than 3/2 or greater than 3*2.
		

Crossrefs

Cf. A064413.

Programs

  • Python
    from math import gcd
    from itertools import count, islice
    def c(k, an): return gcd(k, an) > 1 and not an <= 2*k <= 4*an
    def agen(): # generator of terms
        yield 1
        aset, an, m = {1}, 3, 2
        while True:
            yield an
            aset.add(an)
            an = next(k for k in count(m) if k not in aset and c(k, an))
            while m in aset: m += 1
    print(list(islice(agen(), 72))) # Michael S. Branicky, Nov 21 2024

Formula

a(n) = least number not already used such that gcd(a(n), a(n-1)) > 1 and ((a(n) < a(n-1) / 2) or (a(n) > a(n-1) * 2)).

A360697 The sum of the squares of the digits of n, repeated until reaching a single-digit number.

Original entry on oeis.org

0, 1, 4, 9, 4, 4, 4, 1, 4, 4, 1, 2, 5, 1, 4, 4, 4, 4, 4, 1, 4, 5, 8, 1, 4, 4, 4, 4, 1, 4, 9, 1, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 4, 4, 4, 4, 1, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 1, 4, 1, 4, 4, 4, 4, 4, 4, 4, 2, 1, 4, 4, 1, 4, 4, 4, 1, 2, 4, 4, 4, 1, 4, 4, 1, 4, 4, 1, 4, 4, 1
Offset: 0

Author

Will Nicholes, Feb 16 2023

Keywords

Comments

Square the digits of n, then sum the squares. Repeat the process until the sum is less than 10.

Examples

			For n=28, the sum of the squares of the digits gives 4+64 = 68. Repeating the process gives 36+64 = 100; repeating once more gives 1+0+0 = 1. Therefore a(28) is 1.
a(n) = 4 for 72 of the first 100 n (0 to 99 inclusive.)
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Plus @@ (IntegerDigits[n]^2); a[n_] := NestWhile[f, f[n], # > 9 &]; Array[a, 100, 0] (* Amiram Eldar, Feb 17 2023 *)

A216411 Number of bases in which n begins with a "1".

Original entry on oeis.org

1, 2, 3, 4, 4, 5, 5, 7, 7, 8, 8, 9, 9, 10, 11, 12, 11, 12, 12, 13, 13, 14, 14, 16, 16, 18, 18, 19, 19, 20, 19, 20, 20, 21, 22, 23, 23, 24, 24, 25, 25, 26, 26, 27, 27, 28, 28, 30, 29, 30, 30, 31, 30, 31, 31, 32, 32, 33, 33, 34, 34, 35, 37, 38, 38, 39, 39, 40, 40
Offset: 2

Author

Will Nicholes, Sep 07 2012

Keywords

Comments

1 begins with "1" in all bases, 2 begins with "1" only in binary ("10" in base 2), 3 begins with "1" in two bases ("11" in base 2, "10" in base 3), etc.

Programs

  • Mathematica
    Table[Length[Select[Range[2, n], IntegerDigits[n, #][[1]] == 1 &]], {n, 2, 100}] (* T. D. Noe, Sep 07 2012 *)
  • PARI
    a(n)=my(t=1,s,i);for(i=1,log(n)\log(2)+1,s+=floor((n+.5)^(1/i))-floor(((n+.2)/2)^(1/i)));s \\ Charles R Greathouse IV, Sep 07 2012

Formula

a(n) = n/2 + O(sqrt(n)). - Charles R Greathouse IV, Sep 07 2012

A179371 a(1) = 1; a(n) = smallest positive integer not already used which has a prime signature different from both a(n-1) and a(n-1)+1.

Original entry on oeis.org

1, 4, 6, 8, 2, 9, 3, 10, 12, 14, 5, 16, 15, 7, 18, 21, 11, 22, 20, 13, 24, 17, 25, 19, 26, 23, 27, 29, 28, 30, 32, 31, 33, 36, 34, 37, 40, 35, 41, 38, 42, 39, 43, 46, 44, 47, 45, 48, 50, 49, 51, 53, 52, 54, 59, 55, 60, 56, 61, 63, 57, 64, 66, 58, 68, 67, 62, 70, 65, 71, 69, 72
Offset: 1

Author

Will Nicholes, Jul 11 2010

Keywords

Examples

			To compute a(2), we see a(1) is 1; we look for the smallest unused positive integer that does not have the same prime signature as either 1 or 2. The first such number is 4.
		

Crossrefs

A179372 a(1) = 1; a(n) = smallest positive integer not already used which has a prime signature different from a(n-1), a(n-1)+1 and a(n-1)-1.

Original entry on oeis.org

1, 4, 6, 8, 10, 12, 9, 2, 14, 16, 18, 15, 3, 20, 24, 21, 5, 27, 7, 25, 11, 30, 22, 28, 26, 13, 32, 36, 40, 42, 33, 17, 34, 19, 35, 23, 44, 38, 45, 29, 39, 31, 46, 48, 50, 37, 49, 41, 51, 43, 54, 52, 56, 47, 60, 55, 53, 57, 59, 63, 61, 64, 66, 68, 70, 72, 58, 75, 67, 62, 78, 76
Offset: 1

Author

Will Nicholes, Jul 11 2010

Keywords

Comments

A permutation of the positive integers.

Examples

			To compute a(8), we see a(7) is 9; we look for the smallest unused positive integer that does not have the same prime signature as either 8, 9 or 10. The first such number is 2.
		

Crossrefs

A179390 Modulus for Fibonacci-type sequence described by A015134.

Original entry on oeis.org

1, 2, 2, 3, 3, 4, 4, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15
Offset: 1

Author

Will Nicholes, Jul 12 2010

Keywords

Comments

First terms of A015134 are 1, 2, 2 and 4, meaning that there are 1, 2, 2 and 4 Fibonacci-type sequences modulo 1, 2, 3 and 4 respectively. These are:
mod 1: 0
mod 2: 0
mod 2: 0,1,1
mod 3: 0
mod 3: 0,1,1,2,0,2,2,1
mod 4: 0
mod 4: 0,1,1,2,3,1
mod 4: 0,2,2
mod 4: 0,3,3,2,1,3

Crossrefs

A179391 First term in Fibonacci-type sequence described by A015134.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 2, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2
Offset: 1

Author

Will Nicholes, Jul 12 2010

Keywords

Comments

First terms of A015134 are 1, 2, 2 and 4, meaning that there are 1, 2, 2 and 4 Fibonacci-type sequences modulo 1, 2, 3 and 4 respectively. These are:
mod 1: 0
mod 2: 0
mod 2: 0,1,1
mod 3: 0
mod 3: 0,1,1,2,0,2,2,1
mod 4: 0
mod 4: 0,1,1,2,3,1
mod 4: 0,2,2
mod 4: 0,3,3,2,1,3

Crossrefs

A179392 Second term in Fibonacci-type sequence described by A015134.

Original entry on oeis.org

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

Author

Will Nicholes, Jul 12 2010

Keywords

Comments

First terms of A015134 are 1, 2, 2 and 4, meaning that there are 1, 2, 2 and 4 Fibonacci-type sequences modulo 1, 2, 3 and 4 respectively. These are:
mod 1: 0
mod 2: 0
mod 2: 0,1,1
mod 3: 0
mod 3: 0,1,1,2,0,2,2,1
mod 4: 0
mod 4: 0,1,1,2,3,1
mod 4: 0,2,2
mod 4: 0,3,3,2,1,3

Crossrefs

A179393 Period of the Fibonacci-type sequence described by A015134.

Original entry on oeis.org

1, 1, 3, 1, 8, 1, 6, 3, 6, 1, 20, 4, 1, 24, 8, 3, 1, 16, 16, 16, 1, 12, 6, 12, 3, 6, 12, 12, 1, 24, 24, 8, 24, 1, 60, 20, 3, 12, 4, 1, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 5, 10, 5, 1, 24, 24, 6, 8, 3, 24, 6, 24, 24, 1, 28, 28, 28, 28, 28, 28, 1, 48, 16, 48, 16, 48, 16, 3, 1, 40, 40, 20
Offset: 1

Author

Will Nicholes, Jul 12 2010

Keywords

Comments

First terms of A015134 are 1, 2, 2 and 4, meaning that there are 1, 2, 2 and 4 Fibonacci-type sequences modulo 1, 2, 3 and 4 respectively. These are:
mod 1: 0
mod 2: 0
mod 2: 0,1,1
mod 3: 0
mod 3: 0,1,1,2,0,2,2,1
mod 4: 0
mod 4: 0,1,1,2,3,1
mod 4: 0,2,2
mod 4: 0,3,3,2,1,3
The first sequence for each modulus is the period-1 sequence of 0,0,0... This has the helpful side effect of causing 1 to act as a delimiter between modulus entries: the first 1 indicates the start of modulo-1 sequences, the second 1 indicates the start of modulo-2 sequences, etc.
For each group of sequences (the group start indicated by a 1), the sum of the periods in that group equal the square of the modulus. 1 = 1, (1+3) = 4, (1+8) = 9, (1+6+3+6) = 16, etc.

Crossrefs

A178724 Nonnegative integers whose English name has at least one letter in common with the English name of all other integers.

Original entry on oeis.org

13, 15, 25, 31, 33, 35, 37, 38, 39, 45, 47, 48, 49, 51, 53, 55, 57, 58, 59, 61, 63, 65, 71, 72, 73, 74, 75, 81, 82, 83, 84, 85, 91, 92, 93, 94, 95, 105, 106, 108, 109, 113, 115, 116, 117, 118, 119, 125, 126, 127, 128
Offset: 1

Author

Will Nicholes, Jun 07 2010

Keywords

Examples

			The first entry is 13; one or more of the letters in the word "thirteen" appear in the English name of every integer. 14 is not in the list because "fourteen" has no letters in common with "six."