[go: up one dir, main page]

login
A267101
2 followed by permutation of odd primes, where each n-th prime of the form 4k+1 (A002144) has been replaced with the n-th prime of the form 4k+3 (A002145) and vice versa.
8
2, 5, 3, 13, 17, 7, 11, 29, 37, 19, 41, 23, 31, 53, 61, 43, 73, 47, 89, 97, 59, 101, 109, 67, 71, 79, 113, 137, 83, 103, 149, 157, 107, 173, 127, 181, 131, 193, 197, 139, 229, 151, 233, 163, 167, 241, 257, 269, 277, 179, 191, 281, 199, 293, 211, 313, 223, 317, 227, 239, 337, 251, 349, 353, 263, 271, 373, 283, 389
OFFSET
1,1
COMMENTS
After 2, for each n >= 1, swap the places of primes A002144(n) and A002145(n) in A000040.
LINKS
FORMULA
a(1) = 2; after which, if prime(n) modulo 4 = 1, a(n) = A002145(A267097(n)), otherwise a(n) = A002144(A267098(n)).
a(n) = A000040(A267100(n)).
a(n) = A267099(A000040(n)).
EXAMPLE
For n=2, for which A000040(2) = 3, the first prime of the form 4k+3, we select the first prime of the form 4k+1, which is 5, thus a(2) = 5.
For n=3, for which A000040(3) = 5, the first prime of the form 4k+1, we select the first prime of the form 4k+3, which is 3, thus a(3) = 3.
For n=4, for which A000040(4) = 7, the second prime of the form 4k+3, we select the second prime of the form 4k+1, which is 13, thus a(4) = 13.
For n=5, for which A000040(5) = 11, the third prime of the form 4k+3, we select the third prime of the form 4k+1, which is 17, thus a(5) = 17.
PROG
(Scheme)
(define (A267101 n) (cond ((= 1 n) 2) ((= 1 (modulo (A000040 n) 4)) (A002145 (A267097 n))) (else (A002144 (A267098 n)))))
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Feb 01 2016
STATUS
approved