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.

A081943 a(1) = 1, a(n)= smallest number not occurring earlier such that a(n-1)*a(n) -1 is a prime. re-arrangement of natural numbers such that the product of adjacent terms is one more than a prime.

This page as a plain text file.
%I A081943 #18 Mar 06 2016 04:01:54
%S A081943 1,3,2,4,5,6,7,12,9,8,10,11,18,13,14,16,15,24,20,19,30,17,22,21,28,23,
%T A081943 36,27,26,33,40,32,31,42,25,50,34,38,39,48,43,60,35,46,45,44,37,54,41,
%U A081943 52,57,56,55,68,49,62,64,53,70,29,66,63,76,47,82,69,58,51,72,61
%N A081943 a(1) = 1, a(n)= smallest number not occurring earlier such that a(n-1)*a(n) -1 is a prime. re-arrangement of natural numbers such that the product of adjacent terms is one more than a prime.
%H A081943 Ivan Neretin, <a href="/A081943/b081943.txt">Table of n, a(n) for n = 1..1000</a>
%t A081943 a[1]=1; a[n_]:=a[n]=(For[c=Sort[Table[a[k],{k,n-1}]]; d=Append[c,Last[c]+1]; m=First[Complement[Range[Last[d]],c]], MemberQ[c,m]||!PrimeQ[m*a[n-1]-1],m++ ]; m); Table[a[k],{k,70}] (* _Farideh Firoozbakht_, Apr 14 2004 *)
%Y A081943 Cf. A073666, A081942.
%K A081943 nonn
%O A081943 1,2
%A A081943 _Amarnath Murthy_, Apr 02 2003
%E A081943 More terms from _Farideh Firoozbakht_, Apr 14 2004