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.

A345432 For 1<=x<=n, 1<=y<=n, write gcd(x,y) = u*x+v*y with u,v minimal; a(n) = sum of the values of |u|.

This page as a plain text file.
%I A345432 #10 Jun 25 2021 00:31:42
%S A345432 0,1,4,8,17,24,42,58,82,104,149,177,240,286,340,404,512,579,714,799,
%T A345432 910,1031,1229,1341,1539,1711,1918,2093,2408,2574,2934,3190,3478,3779,
%U A345432 4112,4362,4875,5254,5662,5999,6629,6969,7662,8116,8593,9155,9983,10431,11223,11806
%N A345432 For 1<=x<=n, 1<=y<=n, write gcd(x,y) = u*x+v*y with u,v minimal; a(n) = sum of the values of |u|.
%C A345432 Minimal means minimize u^2+v^2. We follow Maple, PARI, etc., in setting u=0 and v=1 when x=y.
%o A345432 (Python)
%o A345432 from sympy.core.numbers import igcdex
%o A345432 def A345432(n): return sum(abs(u) for u, v, w in (igcdex(x,y) for x in range(1,n+1) for y in range(1,n+1))) # _Chai Wah Wu_, Jun 22 2021
%Y A345432 Cf. A345415-A345434.
%K A345432 nonn
%O A345432 1,3
%A A345432 _N. J. A. Sloane_, Jun 22 2021