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.

A298903 Determinant of n X n matrix whose elements are m(i,j) = prime(i+j)-prime(i).

Original entry on oeis.org

1, 1, -2, 4, 48, 192, -1216, 4672, 120704, 115712, -1717760, -4103168, 10545152, 8527872, -520617984, -8178925568, 97259454464, -1335459315712, -19462172966912, -360902649708544, -1350652745744384, 74944810429972480, -12488535009247887360, -107854339949694287872, 84090212651516146221056
Offset: 0

Views

Author

Andres Cicuttin, Jan 28 2018

Keywords

Examples

			For n=1:
         |prime(2) - prime(1)| = |3 - 2| = |1| = 1,
then a(1) = 1.
For n=2:
         |prime(2)-prime(1) prime(3)-prime(1)| = |3-2 5-2| = |1 3|= -2,
         |prime(3)-prime(2) prime(4)-prime(2)|   |5-3 7-3|   |2 4|
then a(2) = -2.
		

Crossrefs

Programs

  • Maple
    with(LinearAlgebra):
    a:= n-> Determinant(Matrix(n, (i,j)-> ithprime(i+j)-ithprime(i))):
    seq(a(n), n=0..25);  # Alois P. Heinz, Jan 28 2018
  • Mathematica
    b[n_]:=Table[(Prime[i+j]-Prime[i]),{i,1,n},{j,1,n}];
    Table[Det[b[n]],{n,1,24}]
  • PARI
    a(n) = matdet(matrix(n, n, i, j, prime(i+j)-prime(i))); \\ Michel Marcus, Jan 28 2018