OFFSET
1,2
COMMENTS
Prime(n)^2 divides a(n) for n>2.
LINKS
Robert Israel, Table of n, a(n) for n = 1..342
R. Mestrovic, Wolstenholme's theorem: Its Generalizations and Extensions in the last hundred and fifty years (1862-2011), arXiv:1111.3057 [math.NT], 2011.
Eric Weisstein's World of Mathematics, Wolstenholme's Theorem.
FORMULA
MAPLE
f3:=proc(n) local p;
p:=ithprime(n);
numer(add(1/i, i=1..p-1));
end proc;
[seq(f3(n), n=1..20)];
MATHEMATICA
Numerator[Table[Sum[1/k, {k, 1, Prime[n]-1}], {n, 1, 20}]]
Table[HarmonicNumber[p], {p, Prime[Range[20]]-1}]//Numerator (* Harvey P. Dale, May 18 2023 *)
PROG
(PARI) a(n) = my(p=prime(n)); numerator(sum(k=1, p-1, 1/k)); \\ Michel Marcus, Dec 25 2018
CROSSREFS
KEYWORD
frac,nonn
AUTHOR
Alexander Adamchuk, Jul 07 2006
STATUS
approved