OFFSET
1,1
COMMENTS
The sequence of least primes == 2*a(n-1) mod a(n-2), starting with a(1) = 2 and a(2) = 3, is 2, 3, 2, 7, 2, 11, 2, 37, 2, 41, 2, 127, 2, 131, ..., the interleaving of 2 and A362005.
LINKS
Robert Israel, Table of n, a(n) for n = 1..391
EXAMPLE
a(4) = 13 because 13 is the first prime == 2*3 (mod 7).
MAPLE
A[1]:= 2: A[2]:= 3:
for i from 3 to 30 do
for k from 2*A[i-2] mod A[i-1] by A[i-1] do
if isprime(k) then A[i]:= k; break fi
od
od:
seq(A[i], i=1..30);
CROSSREFS
KEYWORD
nonn
AUTHOR
Robert Israel, Apr 02 2023
STATUS
approved