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.

A362933 a(n) = (A132188(n) - A362931(n))/2.

This page as a plain text file.
%I A362933 #23 Aug 29 2023 10:11:40
%S A362933 0,0,0,1,1,-1,-1,0,2,2,2,1,1,1,-1,2,2,2,2,1,1,1,1,0,4,4,6,5,5,1,1,4,4,
%T A362933 4,2,5,5,5,5,4,4,0,0,1,-1,-1,-1,0,6,10,10,11,11,11,11,10,10,10,10,5,5,
%U A362933 5,5,12,12,8,8,9,9,7,7,8,8,8,10,11,9,7,7,8
%N A362933 a(n) = (A132188(n) - A362931(n))/2.
%C A362933 a(n) = one-half of (number of pairs (i,j) in [1..n] X [1..n] with integral geometric mean sqrt(i*j)) - (number of pairs (i,j) in [1..n] X [1..n] with integral harmonic mean 2*i*j/(i+j)).
%H A362933 Alois P. Heinz, <a href="/A362933/b362933.txt">Table of n, a(n) for n = 1..65536</a>
%F A362933 a(n) = A362932(n)/2.
%p A362933 a:= proc(n) option remember; `if`(n=0, 0, add(
%p A362933       `if`(irem(2*i*n, i+n)=0, -1, 0)+
%p A362933       `if`(issqr(i*n), 1, 0), i=1..n-1)+a(n-1))
%p A362933     end:
%p A362933 seq(a(n), n=1..80);  # _Alois P. Heinz_, Aug 28 2023
%o A362933 (Python)
%o A362933 from sympy.ntheory.primetest import is_square
%o A362933 def A362933(n): return sum((1 if T else -1) for x in range(1,n+1) for y in range(1,x) if (T:=is_square(x*y))^(not (x*y<<1)%(x+y))) # _Chai Wah Wu_, Aug 29 2023
%Y A362933 Cf. A132188, A362931, A362932.
%K A362933 sign,look
%O A362933 1,9
%A A362933 _N. J. A. Sloane_, Aug 28 2023