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.

A282700 Primes missing from A086527.

Original entry on oeis.org

2, 197, 199, 317, 467, 563, 599, 653, 811, 829, 863, 977, 1019, 1039, 1093, 1097, 1103, 1327, 1373, 1429, 1433, 1607, 1609, 1613, 1669, 1877, 1879, 2089, 2141, 2143, 2347, 2543, 2551, 2797, 3023, 3181, 3257, 3259, 3307, 3313, 3319, 3469, 3617, 3677, 3779, 3919, 4003, 4007, 4013, 4019, 4021
Offset: 1

Views

Author

N. J. A. Sloane, Feb 25 2017

Keywords

Crossrefs

A086528 Smallest prime which occurs exactly n times in the sequence A086527.

Original entry on oeis.org

2, 3, 11, 53, 29, 97, 211, 127, 223, 547, 797, 2203, 2999, 1657, 1367, 1361, 5623, 3989, 18859, 9587, 19373, 14143, 19681, 15727, 25523, 19661, 43853, 34127, 31477, 34123, 31469, 124067, 188137, 153247, 58889, 107441, 212791, 221021, 188107, 206749
Offset: 1

Views

Author

Amarnath Murthy, Jul 31 2003

Keywords

Comments

Conjecture: The sequence is infinite.

Crossrefs

Extensions

Corrected and extended by David Wasserman, Mar 14 2005

A055265 a(n) is the smallest positive integer not already in the sequence such that a(n)+a(n-1) is prime, starting with a(1)=1.

Original entry on oeis.org

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

Views

Author

Henry Bottomley, May 09 2000

Keywords

Comments

The sequence is well-defined (the terms must alternate in parity, and by Dirichlet's theorem a(n+1) always exists). - N. J. A. Sloane, Mar 07 2017
Does every positive integer eventually occur? - Dmitry Kamenetsky, May 27 2009. Reply from Robert G. Wilson v, May 27 2009: The answer is almost certainly yes, on probabilistic grounds.
It appears that this is the limit of the rows of A051237. That those rows do approach a limit seems certain, and given that that limit exists, that this sequence is the limit seems even more likely, but no proof is known for either conjecture. - Robert G. Wilson v, Mar 11 2011, edited by Franklin T. Adams-Watters, Mar 17 2011
The sequence is also a particular case of "among the pairwise sums of any M consecutive terms, N are prime", with M = 2, N = 1. For other M, N see A055266 & A253074 (M = 2, N = 0), A329333, A329405 - A329416, A329449 - A329456, A329563 - A329581, and the OEIS Wiki page. - M. F. Hasler, Feb 11 2020

Examples

			a(5) = 7 because 1, 2, 3 and 4 have already been used and neither 4 + 5 = 9 nor 4 + 6 = 10 are prime while 4 + 7 = 11 is prime.
		

Crossrefs

Inverse permutation: A117922; fixed points: A117925; A117923=a(a(n)). - Reinhard Zumkeller, Apr 03 2006
Cf. A086527 (the primes a(n)+a(n-1)).
Cf. A070942 (n's such that a(1..n) is a permutation of (1..n)). - Zak Seidov, Oct 19 2011
See also A076990, A243625.
See A282695 for deviation from identity sequence.
A073659 is a version where the partial sums must be primes.

Programs

  • Haskell
    import Data.List (delete)
    a055265 n = a055265_list !! (n-1)
    a055265_list = 1 : f 1 [2..] where
       f x vs = g vs where
         g (w:ws) = if a010051 (x + w) == 1
                       then w : f w (delete w vs) else g ws
    -- Reinhard Zumkeller, Feb 14 2013
    
  • Maple
    A055265 := proc(n)
        local a,i,known ;
        option remember;
        if n =1 then
            1;
        else
            for a from 1 do
                known := false;
                for i from 1 to n-1 do
                    if procname(i) = a then
                        known := true;
                        break;
                    end if;
                end do:
                if not known and isprime(procname(n-1)+a) then
                    return a;
                end if;
            end do:
        end if;
    end proc:
    seq(A055265(n),n=1..100) ; # R. J. Mathar, Feb 25 2017
  • Mathematica
    f[s_List] := Block[{k = 1, a = s[[ -1]]}, While[ MemberQ[s, k] || ! PrimeQ[a + k], k++ ]; Append[s, k]]; Nest[f, {1}, 71] (* Robert G. Wilson v, May 27 2009 *)
    q=2000; a={1}; z=Range[2,2*q]; While[Length[z]>q-1, k=1; While[!PrimeQ[z[[k]]+Last[a]], k++]; AppendTo[a,z[[k]]]; z=Delete[z,k]]; Print[a] (*200 times faster*) (* Vladimir Joseph Stephan Orlovsky, May 03 2011 *)
  • PARI
    v=[1];n=1;while(n<50,if(isprime(v[#v]+n)&&!vecsearch(vecsort(v),n), v=concat(v,n);n=0);n++);v \\ Derek Orr, Jun 01 2015
    
  • PARI
    U=-a=1; vector(100,k, k=valuation(1+U+=1<M. F. Hasler, Feb 11 2020

Formula

a(2n-1) = A128280(2n-1) - 1, a(2n) = A128280(2n) + 1, for all n >= 1. - M. F. Hasler, Feb 11 2020

Extensions

Corrected by Hans Havermann, Sep 24 2002

A086526 Beginning with 2, the smallest even number not included earlier such that the arithmetic mean of a pair of successive terms is a prime.

Original entry on oeis.org

2, 4, 6, 8, 14, 12, 10, 16, 18, 20, 26, 32, 30, 28, 34, 24, 22, 36, 38, 44, 42, 40, 46, 48, 58, 60, 62, 56, 50, 68, 54, 52, 66, 76, 70, 64, 78, 80, 86, 72, 74, 84, 82, 96, 98, 104, 90, 88, 106, 100, 94, 108, 110, 92, 102, 112, 114, 140, 122, 132, 130, 124, 138, 116, 146, 128
Offset: 1

Views

Author

Amarnath Murthy, Jul 31 2003

Keywords

Comments

A rearrangement of even numbers.

Crossrefs

Cf. A086527.

Formula

a(n) = 2 * A055265(n).

Extensions

More terms from David Wasserman, Mar 14 2005

A361445 Sums of consecutive terms of A361444.

Original entry on oeis.org

3, 5, 7, 11, 13, 11, 13, 17, 31, 163, 229, 199, 313, 257, 277, 233, 223, 311, 331, 353, 373, 353, 167, 197, 373, 433, 463, 349, 359, 433, 443, 463, 433, 443, 787, 919, 727, 757, 787, 797, 397, 347, 727, 457, 467, 757, 727, 787, 857, 1009, 1019, 857
Offset: 1

Views

Author

Jodi Spitz, Mar 12 2023

Keywords

Crossrefs

Showing 1-5 of 5 results.