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.

A350777 Numbers k where phi(k) divides k - 3.

This page as a plain text file.
%I A350777 #30 Jun 27 2025 21:48:57
%S A350777 1,2,3,9,195,5187,1141967133868035,3658018932844533311864835
%N A350777 Numbers k where phi(k) divides k - 3.
%C A350777 Numbers in this sequence larger than 2 have to be odd, since phi(n) is even for n > 2, so n - 3 cannot be odd. Therefore n itself must be odd.
%C A350777 Terms having (k-3)/phi(k) = 2 are shared with A226105. - _Max Alekseyev_, Oct 26 2023
%e A350777 phi(195) = 96, 195 - 3 = 192, and 96 divides 192.
%t A350777 Select[Range[6000], Divisible[#-3, EulerPhi[#]] &] (* _Amiram Eldar_, Jan 19 2022 *)
%o A350777 (PARI) isok(k) = !((k-3) % eulerphi(k)); \\ _Michel Marcus_, Jan 19 2022
%o A350777 (Python)
%o A350777 from sympy import totient
%o A350777 print("1, 2", end=", ")
%o A350777 for k in range (3, 10**8, 2):
%o A350777     if (k-3)%totient(k)==0:
%o A350777         print(k, end=", ", flush=True) # _Martin Ehrenstein_, Mar 26 2022
%Y A350777 Cf. A000010, A007694, A226105.
%K A350777 nonn,more
%O A350777 1,2
%A A350777 _Albert Böschow_ and _Dennis Gruhlke_, Jan 15 2022
%E A350777 a(7)-a(8) from _Max Alekseyev_, Nov 05 2023