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

A082692 Partial sums of A082691.

Original entry on oeis.org

1, 3, 4, 6, 9, 10, 12, 13, 15, 18, 22, 23, 25, 26, 28, 31, 32, 34, 35, 37, 40, 44, 49, 50, 52, 53, 55, 58, 59, 61, 62, 64, 67, 71, 72, 74, 75, 77, 80, 81, 83, 84, 86, 89, 93, 98, 104, 105, 107, 108, 110, 113, 114, 116, 117, 119, 122, 126, 127, 129, 130, 132, 135, 136, 138
Offset: 1

Views

Author

Benoit Cloitre, Apr 12 2003

Keywords

Crossrefs

Cf. A082691.

Formula

a(n) = Sum_{k=1..n} A082691(k).

A182660 a(2^(k+1)) = k; 0 everywhere else.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Sam Alexander, Nov 27 2010

Keywords

Comments

A surjection N->N designed to spite a guesser who is trying to guess whether it's a surjection, using the following naive guessing method: Guess that (n0,...,nk) is a subsequence of a surjection iff it contains every natural less than log_2(k+1).
This sequence causes the would-be guesser to change his mind infinitely often.
a(0)=0. Assume a(0),...,a(n) have been defined.
If the above guesser guesses that (a(0),...,a(n)) IS the beginning of a surjective sequence, then let a(n+1)=0. Otherwise let a(n+1) be the least number not in (a(0),...,a(n)).

Crossrefs

Programs

  • Magma
    [ exists(t){ k: k in [1..Ceiling(Log(n+1))] | n eq 2^(k+1) } select t else 0: n in [0..100] ];
    
  • PARI
    A182660(n) = if(n<2,0,my(p = 0, k = isprimepower(n,&p)); if(2==p,k-1,0)); \\ Antti Karttunen, Jul 22 2018

A182659 A canonical permutation designed to thwart a certain naive attempt to guess whether sequences are permutations.

Original entry on oeis.org

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

Views

Author

Sam Alexander, Nov 26 2010

Keywords

Comments

A naive way to guess whether a function f:N->N is a permutation, based on just an initial subsequence (f(0),...,f(n)), is to guess "no" if (f(0),...,f(n)) contains a repeated entry or if there is some i in {0,...,n} such that i is not in {f(0),...,f(n)} and 2 i<=n; and guess "yes" otherwise. a(n) thwarts that method, causing it to change its mind infinitely often as n->infinity.
a(0)=0. Suppose a(0),...,a(n) have been defined.
1. If the above method guesses that (a(0),...,a(n)) is NOT an initial subsequence of a permutation, then unmark any "marked" numbers.
2. If the above method guesses that (a(0),...,a(n)) IS an initial subsequence of a permutation, then "mark" the smallest number not in {a(0),...,a(n)}.
3. Let a(n+1) be the least unmarked number not in {a(0),...,a(n)}.
A030301 can be derived by a similar method, where instead of trying to guess whether sequences are permutations, the naive victim is trying to guess whether sequences contain infinitely many 0s.

Crossrefs

Formula

a(0) = 0; if n = A068156(k+1) = 6*2^k - 3 for some k >= 0 then a(n) = A033484(k) = (n-1)/2; otherwise, a(n) = n+1. - Andrey Zabolotskiy, Feb 27 2025

Extensions

a(22) corrected and further terms added by Andrey Zabolotskiy, Feb 27 2025
Showing 1-3 of 3 results.