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.

A037168 a(n) = 2*prime(n) - 2.

Original entry on oeis.org

2, 4, 8, 12, 20, 24, 32, 36, 44, 56, 60, 72, 80, 84, 92, 104, 116, 120, 132, 140, 144, 156, 164, 176, 192, 200, 204, 212, 216, 224, 252, 260, 272, 276, 296, 300, 312, 324, 332, 344, 356, 360, 380, 384, 392, 396, 420, 444, 452, 456
Offset: 1

Views

Author

Armand Turpel (armandt(AT)unforgettable.com)

Keywords

Comments

Original definition: Prime(n)+ Sum(prime(n-z) mod prime(n-z-1)); z=0,1...n-2 ; with offset 2.
Since prime(n+1) < 2*prime(n) for all n, the "mod" in the sum is equivalent to "-", making it telescopic and equal to prime(n)-2. - M. F. Hasler, Jun 29 2013

Examples

			a(3) = 8 since the third prime is 5 and 2 * 5 - 2 = 8.
		

Crossrefs

Programs

Formula

a(n) = 2 * prime(n) - 2 = 2 * phi(prime(n)). - Alonso del Arte, Jun 30 2013
a(n) = 2 * A006093(n). - Ray Chandler, Jun 30 2013
a(n) = A000010(A000040(n)) - A023900(A000040(n)). - Torlach Rush, Mar 11 2018

Extensions

Definition simplified and extended to n=1, following a suggestion from Alonso del Arte, by M. F. Hasler, Jun 29 2013