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.

A382768 Number of k < n that are coprime to n and neither squarefree nor prime powers.

This page as a plain text file.
%I A382768 #8 Apr 22 2025 09:00:47
%S A382768 0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,2,0,1,0,3,0,3,0,1,0,5,0,5,0,2,0,
%T A382768 3,0,6,0,2,0,7,0,7,0,2,1,9,0,9,0,5,1,12,0,8,1,7,1,14,0,15,1,5,2,10,0,
%U A382768 16,2,8,0,17,0,18,2,5,3,16,0,20,1,10,3,21,0
%N A382768 Number of k < n that are coprime to n and neither squarefree nor prime powers.
%C A382768 Let s = A126706, the set of numbers that are neither squarefree nor prime powers.
%C A382768 Let q(k) be the number of terms in A126706 that do not exceed k. For example, q(20) = 3, since s(1..3) = {12, 18, 20}.
%C A382768 a(n) = 0 for n < A382248(n). Only 72 numbers n are such that a(n) = 0, with n = 2310 the largest n such that a(n) = 0.
%C A382768 a(A002110(k)) = 0 for k < 6.
%H A382768 Vincenzo Librandi, <a href="/A382768/b382768.txt">Table of n, a(n) for n = 1..10000</a>
%t A382768 nn = 120; q = 1; Table[Set[{c, i}, {0, 1}]; If[Nor[SquareFreeQ[n], PrimePowerQ[n]], t[q] = n; q++]; While[i < q, If[CoprimeQ[t[i], n], c++]; i++]; c, {n, nn}]
%o A382768 (Magma) nn := 120; q := 1; t := []; res := []; for n in [1..nn] do if not IsSquarefree(n) and not IsPrimePower(n) then Append(~t, n); q +:= 1; end if; c := 0; for i in [1..#t] do if GCD(t[i], n) eq 1 then c +:= 1; end if; end for; Append(~res, c); end for; res; // _Vincenzo Librandi_, Apr 22 2025
%Y A382768 Cf. A002110, A073311, A126706, A139555, A382248.
%K A382768 nonn,easy
%O A382768 1,19
%A A382768 _Michael De Vlieger_, Apr 04 2025