|
|
A119447
|
|
Leading diagonal of triangle A119446.
|
|
3
|
|
|
2, 2, 3, 3, 3, 3, 3, 3, 3, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 13, 13, 7, 7, 7, 7, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
a(181) = 27 is the first term greater than 19. This is because prime(181)/181 > 6 for the first time. In general this sequence is determined by prime(n)/n: the pattern for each row of the triangle is that it ends with prime(n), preceded by multiples of k = prime(n)/n down to k^2, then the largest multiple of k-1 less than k^2 and the largest multiple of k-2 less than that and so on. This sequence gives the multiple of 1. See A000960 for the sequence that gives the ending value for each starting k.
|
|
LINKS
|
|
|
FORMULA
|
|
|
MATHEMATICA
|
t[1, n_]:= Prime[n];
t[m_, n_]/; 1<m<=n:= t[m, n]= (n-m+1)*Floor[(t[m-1, n]-1)/(n-m+1)];
t[_, _]=0;
|
|
PROG
|
(Magma)
if k eq 1 then return NthPrime(n);
else return (n-k+1)*Floor((t(n, k-1) -1)/(n-k+1));
end if;
end function;
(SageMath)
if (k==1): return nth_prime(n)
else: return (n-k+1)*((t(n, k-1) -1)//(n-k+1))
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|