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.

A206827 Number of solutions (n,k) of s(k) == s(n) (mod n), where 1 <= k < n and s(k) = k*(k+1)*(2*k+1)/6.

This page as a plain text file.
%I A206827 #20 Jun 04 2023 08:40:34
%S A206827 1,1,1,2,2,2,1,1,3,2,2,2,3,3,1,2,1,2,3,3,3,2,1,2,3,1,3,2,3,2,1,3,3,8,
%T A206827 1,2,3,3,3,2,4,2,3,3,3,2,2,2,3,3,3,2,2,8,3,3,3,2,2,2,3,3,1,8,3,2,3,3,
%U A206827 9,2,1,2,3,3,3,8,2,2,3,1,3,2,4,8,3,3,3,2,5,8,3,3,3,8,2,2,3,3,3
%N A206827 Number of solutions (n,k) of s(k) == s(n) (mod n), where 1 <= k < n and s(k) = k*(k+1)*(2*k+1)/6.
%C A206827 For a guide to related sequences, see A206588.
%C A206827 If n is a prime > 3, a(n) = 2. - _Robert Israel_, Jun 04 2023
%H A206827 Robert Israel, <a href="/A206827/b206827.txt">Table of n, a(n) for n = 2..10000</a>
%e A206827 5 divides exactly two of the numbers s(n)-s(k) for k=1,2,3,4, so a(5)=2.
%p A206827 f:= n -> numboccur(S[n] mod n, S[1..n-1] mod n):
%p A206827 S:= [seq(k*(k+1)*(2*k+1)/6, k=1..100)]:
%p A206827 map(f,[$2..100]); # _Robert Israel_, Jun 04 2023
%t A206827 s[k_] := k (k + 1) (2 k + 1)/6;
%t A206827 f[n_, k_] := If[Mod[s[n] - s[k], n] == 0, 1, 0];
%t A206827 t[n_] := Flatten[Table[f[n, k], {k, 1, n - 1}]]
%t A206827 a[n_] := Count[Flatten[t[n]], 1]
%t A206827 Table[a[n], {n, 2, 120}]  (* A206827 *)
%Y A206827 Cf. A206588.
%K A206827 nonn
%O A206827 2,4
%A A206827 _Clark Kimberling_, Feb 15 2012