cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A375087 Numbers added to cumulative correction term in order for prime numbers to resemble a recursive sequence.

This page as a plain text file.
%I A375087 #19 Aug 17 2024 23:19:24
%S A375087 0,1,0,4,2,4,2,0,8,2,4,8,2,0,4,10,2,4,8,0,4,4,2,10,10,2,4,2,-8,14,12,
%T A375087 8,-2,10,6,2,8,4,4,10,-2,10,8,4,-6,2,20,14,2,0,8,-2,6,10,6,10,2,4,8,
%U A375087 -4,-2,20,16,2,-8,12,10,14,8,0,2,8,8,8,4,2,10,4,2,16,2,10
%N A375087 Numbers added to cumulative correction term in order for prime numbers to resemble a recursive sequence.
%C A375087 At n=1, prime(n+2) = prime(n+1) + prime(n) but thereafter such a form must be reduced by a "correction" amount prime(n+2) = prime(n+1) + prime(n) - A096379(n), and the present sequence is how that correction changes.
%F A375087 a(n) = 2*prime(n+1) - prime(n+2) - prime(n-1), for n>=2.
%F A375087 a(n) = A096379(n) - A096379(n-1), for n>=2.
%F A375087 prime(n+2) = prime(n+1) + prime(n) - Sum_{i=1..n} a(i)
%F A375087 a(n) = prime(n+1) + prime(n) - prime(n+2) - Sum_{i=0..n-1} a(i).
%e A375087 For n = 1: a(1) = p_2 + p_1 - p_3 - (Sum_{i <= 0} a(i)) = p_2 + p_1 - p_3 ==> a(1) = 3 + 2 - 5 = 0 ==> a(1) = 0.
%e A375087 For n = 2: a(2) = p_3 + p_2 - p_4 - (Sum_{i <= 1} a(i)) = p_3 + p_2 - p_4 - a(1) ==> a(2) = 5 + 3 - 7 - 0 = 1 ==> a(2) = 1.
%e A375087 For n = 3: a(3) = p_4 + p_3 - p_5 - (Sum_{i <= 2} a(i)) = p_4 + p_3 - p_5 - (a(1) + a(2)) ==> a(3) = 7 + 5 - 11 - (0 + 1) = 0 ==> a(3) = 0.
%o A375087 (PARI) lista(nn) = my(va = vector(nn)); for (n=1, nn, va[n] = prime(n+1) + prime(n) - prime(n+2) - sum(i=1, n-1, va[i]);); va; \\ _Michel Marcus_, Jul 30 2024
%Y A375087 Cf. A096379 (partial sums), A066495 (indices of 0's).
%K A375087 sign,easy
%O A375087 1,4
%A A375087 _Kaleb Williams_, Jul 29 2024