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.

A258127 Smallest k such that Sum_{i=0..k} binomial(n,i) is prime, or a(n)=0 if there is no such k.

Original entry on oeis.org

1, 1, 2, 1, 4, 1, 2, 2, 0, 1, 2, 1, 4, 4, 6, 1, 16, 1, 2, 2, 4, 1, 2, 6, 8, 16, 2, 1, 0, 1, 4, 6, 0, 0, 2, 1, 0, 0, 0, 1, 0, 1, 2, 2, 0, 1, 2, 10, 0, 48, 2, 1, 36, 20, 6, 2, 8, 1, 10, 1, 16, 13, 2, 2, 0, 1, 0, 2, 0, 1, 2, 1, 0, 0, 2, 2, 0, 1, 8, 74, 64, 1, 16
Offset: 1

Views

Author

Vladimir Shevelev, May 21 2015

Keywords

Comments

a(n)=0 for n=9,29,33,34,37,38,39,41,45,49,...;
records a(n) are 1,2,4,6,16,48,74,...
at positions 1,3,5,15,17,50,80,...

Crossrefs

Programs

  • PARI
    a(n) = {my(k = 0); while(! isprime(sum(i=0, k, binomial(n,i))), k++; if ((k>n) && !isprime(binomial(n,k)), return (0);)); k;} \\ Michel Marcus, May 23 2015

Formula

a(n) <= n-1.

Extensions

More terms from Peter J. C. Moses, May 21 2015

A258193 Define a<+>b = odd part(odd part(a) + odd part(b)), where odd part(n) = A000265(n); a(n) is the smallest prime of the form <+>_{0<=i<=k} binomial (n,i), or a(n)=0 if there is no such a prime (see comment).

Original entry on oeis.org

0, 0, 0, 0, 3, 3, 11, 0, 5, 3, 3, 17, 7, 23, 53, 29, 13, 5, 5, 3, 11, 3, 3, 823, 13, 7, 7, 457, 109, 109, 233, 2267, 17, 59, 151, 5, 19, 5, 5, 3, 113, 11, 11, 3, 23, 3, 3, 71, 43, 13, 13, 7, 179, 7, 7, 193, 29, 2137, 863, 443, 31, 5498157739, 977, 163
Offset: 1

Views

Author

Vladimir Shevelev, May 23 2015

Keywords

Comments

f(n)=<+>_{0<=i<=n} c(i) is defined as the following: f(0)=c(0), f(n)=f(n-1)<+>c(n).
a(n)=0 for 1,2,3,4,8,82,107,...(cf. A258194)

Crossrefs

Programs

  • Haskell
    import Data.Function (on)
    a258193 n = head $ (filter ((== 1) . a010051'') $
                        scanl1 (<+>) (a034868_row n)) ++ [0]
                where (<+>) = (a000265 .) . on (+) a000265
    -- Reinhard Zumkeller, Jun 20 2015
  • Mathematica
    vSum[a_,b_]:=#[#[a]+#[b]]&[#/2^IntegerExponent[#,2]&];
    Table[
    First[Select[FoldList[vSum,First[#],Rest[#]]&[Map[Binomial[n,#]&,Range[0,n]]],PrimeQ]/.{}->{0}],{n,100}] (*Peter J. C. Moses, May 23 2015*)

Extensions

More terms from Peter J. C. Moses, May 23 2015

A258483 Numbers n such that partial sums of the n-th row of Pascal's triangle (A007318) are all nonprime.

Original entry on oeis.org

0, 9, 29, 33, 34, 37, 38, 39, 41, 45, 49, 65, 67, 69, 73, 74, 77, 85, 86, 92, 97, 98, 101, 105, 113, 114, 115, 117, 118, 121, 129, 133, 134, 137, 139, 141, 145, 146, 151, 154, 155, 158, 160, 161, 164, 165, 170, 173, 177, 182, 185, 186, 193, 194, 195, 199, 202, 205, 206, 209, 213, 214, 225, 227, 229, 230, 234, 241, 247, 257, 258, 259, 261, 263, 265, 266, 269, 272, 273, 277, 281
Offset: 0

Views

Author

Vladimir Shevelev, May 31 2015

Keywords

Comments

It appears that a(n) ~ c*n, as n goes to infinity, where c is constant < 2.17. For heuristic argument, see Robert Israel link.

Crossrefs

Programs

  • Maple
    T:= <1>:
    res:= 0:
    for n from 1 to 1000 do
      T:= <1, T[1..-2] + T[2..-1], 2^n>;
      if not ormap(isprime,T) then res:= res, n fi
    od:
    res; # Robert Israel, Jun 04 2015
  • PARI
    isok(n) = {my(s = 0); for (k=0, n, s += binomial(n, k); if (isprime(s), return (0))); return (1);} \\ Michel Marcus, May 31 2015
Showing 1-3 of 3 results.