login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Number of squares formed from a square composed of p^2 unit squares where p is n-th prime.
0

%I #27 Sep 08 2022 08:46:14

%S 5,14,55,140,506,819,1785,2470,4324,8555,10416,17575,23821,27434,

%T 35720,51039,70210,77531,102510,121836,132349,167480,194054,238965,

%U 308945,348551,369564,414090,437635,487369,690880,757966,866525,904890,1113775,1159076

%N Number of squares formed from a square composed of p^2 unit squares where p is n-th prime.

%C Inspired by geometric interpretation of A001248.

%C Obviously, a(n) is a prime number, only for n = 1.

%C Subsequence of A000330.

%C Obviously, there is only one solution for a and b to the equation p*p = a*b where p is prime, if a > 1 and b > 1. So there can be only one rectangle that is composed of p^2 unit squares, if a > 1 and b > 1. That rectangle is the p X p square. Its uniqueness is a motivation for this sequence.

%F a(n) = prime(n) * (prime(n)+1) * (2*prime(n)+1) / 6.

%F a(n) = A000330(A000040(n)).

%e For a square composed of 4 unit squares, there are 5 squares.

%t Table[Prime[n] (Prime[n] + 1) (2 Prime[n] + 1)/6, {n, 50}] (* _Vincenzo Librandi_, Sep 17 2015 *)

%t (#(#+1)(2#+1))/6&/@Prime[Range[40]] (* _Harvey P. Dale_, Sep 05 2022 *)

%o (PARI) a(n) = my(p=prime(n)); p * (p+1) * (2*p+1) / 6;

%o vector(40, n, a(n))

%o (Magma) [NthPrime(n)*(NthPrime(n)+1)*(2*NthPrime(n)+1)/6: n in [1..40]]; // _Vincenzo Librandi_, Sep 17 2015

%Y Cf. A000330, A001248, A000217, A000537.

%K nonn,easy

%O 1,1

%A _Altug Alkan_, Sep 16 2015