OFFSET
1,2
COMMENTS
Or number of integers of the form m^2+1 between two consecutive twin k^2+1 primes.
a(n)==7 mod 10 for n>1.
Conjecture 1: the sequence is infinite.
Conjecture 2: for n>1, the sequence sorted in ascending order with distinct values generates the set B = {b(k)} = {7, 17, 27, 37, …} = {7 + 10k}, k = 0,1,2,… and {a(n)}/qZ = B/qZ with q = 2^m, m = 1, 2,… is a multiplicative group.
This has been verified for n up to 10^8.
A remarkable simple way to perceive properties of invariability in this sequence (or other particular sequences) is the use of finite groups of integers modulo q. This study can provide interesting interpretations for some regularities which describe properties in other mathematical spaces.
However, this concept is based on a conjecture if it is impossible to prove the infinity character of a sequence. This requires, for the calculations, a large number of elements in the sequence.
The groups of integers modulo 2^m are:
q = 2 => B/2Z = {1}, the trivial group.
q = 4 => B/4Z = {1,3}, the cyclic group of order 2 with two elements.
q = 8 => B/8Z = {1,3,5,7}, the group of order 4 with generating set {3,7} => the Klein four-group of order 2. The square of each element of B/8Z is 1. The group is not cyclic.
q = 16 => B/16Z = {1,3,5,7,9,11,13,15}, the group of order 8 with generating set {3,15}. The powers of 3 {1,3,9,11} are a subgroup of order 4, as are the powers of 5, {1,5,9,13}. The group B/16Z is not cyclic.
For higher powers q = 2^k, k>2, B/(2^k)Z = {1,3,5,…,2^k-1}, with generating set {3, 2^k-1}. The group B/(2^k)Z is not cyclic.
The order of the group is given by Euler’s totient function (A000010): this is the product of the orders of the cyclic groups in the direct product (see the links).
LINKS
Michel Lagneau, Table of n, a(n) for n = 1..10000
Eric Weisstein's World of Mathematics, Finite Group
Wikipedia, Finite group
Wikipedia, Multiplicative group of integers modulo n
EXAMPLE
a(1)=0 because there exists 0 number of the form m^2+1 between the two consecutive pairs of primes(2^2+1, 4^2+1) and (4^2+1, 6^2+1);
a(2) = 7 because there exists 7 numbers of the form m^2+1 between the two consecutive pairs of primes(4^2+1, 6^2+1) and (14^2+1, 16^2+1): 50, 65, 82, 101, 122, 145 and 170.
MAPLE
nn:=10000:T:=array(1..200):kk:=0:
for n from 4 by 2 to nn do:
p1:=n^2+1:p2:=(n+2)^2+1:
if isprime(p1) and isprime(p2)
then
kk:=kk+1:T[kk]:=n:
else
fi:
od:
for m from 1 to kk-1 do:
q:=T[m+1]-T[m]-3:printf(`%d, `, q):
od:
MATHEMATICA
lst={}; Do[If[PrimeQ[n^2+1], AppendTo[lst, n]], {n, 1, 10000}]; Module[{tr=Transpose[Select[Partition[lst, 2, 1], #[[2]]-#[[1]]==2&]], fir, las}, fir=Rest[tr[[1]]]; las=Most[tr[[2]]]; Flatten[Abs[Differences/@Thread[{fir, las}]]]-1/.{-1->0}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Michel Lagneau, Feb 15 2016
STATUS
approved