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.

A091625 Number of consecutive primes less than 10^n such that their sum is a perfect power (A091624).

This page as a plain text file.
%I A091625 #2 Mar 30 2012 17:30:59
%S A091625 1,5,8,17,34,87,203,510,1331
%N A091625 Number of consecutive primes less than 10^n such that their sum is a perfect power (A091624).
%t A091625 NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; PrimeExponents[n_] := Flatten[ Table[ #[[2]], {1}] & /@ FactorInteger[n]]; c = 0; p = q = 2; Do[ While[p < 10^n, q = NextPrim[p]; If[ Apply[ GCD, PrimeExponents[p + q]] > 1, c++ ]; p = q]; Print[c], {n, 1, 8}]
%Y A091625 Cf. A001597, A091624.
%K A091625 nonn
%O A091625 1,2
%A A091625 _Robert G. Wilson v_, Jan 24 2004