OFFSET
1,13
LINKS
Simon Strandgaard, Plot of 1000 terms
EXAMPLE
a(1) = 2 mod floor( 2 / 1) = 2 mod 2 = 0,
a(2) = 3 mod floor( 3 / 2) = 3 mod 1 = 0,
a(3) = 5 mod floor( 5 / 3) = 5 mod 1 = 0,
a(4) = 7 mod floor( 7 / 4) = 7 mod 1 = 0,
a(5) = 11 mod floor(11 / 5) = 11 mod 2 = 1.
MATHEMATICA
A347342[n_] := Mod[Prime[n] , Floor[Prime[n]/n]]; Table[A347342[n], {n, 1, 86}] (* Robert P. P. McKone, Aug 27 2021 *)
PROG
(PARI) a(n) = prime(n) % floor(prime(n) / n);
(Ruby) require 'prime'
values = []
Prime.first(30).each_with_index do |prime, i|
values << prime % (prime/(i+1))
end
p values
CROSSREFS
KEYWORD
nonn
AUTHOR
Simon Strandgaard, Aug 27 2021
STATUS
editing