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.

A284263 a(n) = A252459(2*A000040(n)), a(0) = 0 by convention.

This page as a plain text file.
%I A284263 #14 Mar 24 2017 22:00:03
%S A284263 0,0,0,1,2,2,2,2,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,
%T A284263 5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,8,8,
%U A284263 8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9,9
%N A284263 a(n) = A252459(2*A000040(n)), a(0) = 0 by convention.
%H A284263 Antti Karttunen, <a href="/A284263/b284263.txt">Table of n, a(n) for n = 0..11000</a>
%F A284263 a(0) = 0, for n >= 1, a(n) = A252459(2*A000040(n)).
%F A284263 a(n) = A252459(A002110(n)).
%t A284263 a[n_] := If[n<1, 0, Block[{k=1}, While[Prime[n + k  - 1] > Prime[k]^2, k++]; k - 1]]; Table[a[n], {n, 0, 130}] (*  _Indranil Ghosh_, Mar 24 2017 *)
%o A284263 (PARI) A284263(n) = { my(k=1); if(0==n, 0, while(prime(n+k-1) > (prime(k)^2), k = k+1);(k-1)); };
%o A284263 (Scheme) (define (A284263 n) (if (zero? n) n (A252459 (* 2 (A000040 n)))))
%o A284263 (Python)
%o A284263 from sympy import prime
%o A284263 def a(n):
%o A284263     if n<1: return 0
%o A284263     k=1
%o A284263     while prime(n + k - 1)>prime(k)**2:k+=1
%o A284263     return k - 1 # _Indranil Ghosh_, Mar 24 2017
%Y A284263 Cf. A000040, A002110, A251719, A252459, A284262.
%K A284263 nonn
%O A284263 0,5
%A A284263 _Antti Karttunen_, Mar 24 2017