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.

A157813 Denominators of fractions arranged in "antidiagonal boustrophedon" ordering with equivalent fractions removed: (1/1, 2/1, 1/2, 1/3, 3/1, 4/1, 3/2, 2/3, 1/4, 1/5, 5/1, 6/1, 5/2, ...).

This page as a plain text file.
%I A157813 #24 Oct 10 2023 16:20:34
%S A157813 1,1,2,3,1,1,2,3,4,5,1,1,2,3,4,5,6,7,5,3,1,1,2,4,5,7,8,9,7,3,1,1,2,3,
%T A157813 4,5,6,7,8,9,10,11,7,5,1,1,2,3,4,5,6,7,8,9,10,11,12,13,11,9,5,3,1,1,2,
%U A157813 4,7,8,11,13,14,15,13,11,9,7,5,3,1,1,2,3,4
%N A157813 Denominators of fractions arranged in "antidiagonal boustrophedon" ordering with equivalent fractions removed: (1/1, 2/1, 1/2, 1/3, 3/1, 4/1, 3/2, 2/3, 1/4, 1/5, 5/1, 6/1, 5/2, ...).
%H A157813 Robert Israel, <a href="/A157813/b157813.txt">Table of n, a(n) for n = 1..10000</a>
%p A157813 R:= NULL: count:= 0:
%p A157813 for m from 2 while count < 100 do
%p A157813   S:= select(t -> igcd(t,m-t)=1, [$1..m-1]);
%p A157813   count:= count+nops(S);
%p A157813   if m::odd then R:= R, op(S) else R:= R, seq(m-t,t=S) fi;
%p A157813 od:
%p A157813 R; # _Robert Israel_, Oct 09 2023
%o A157813 (Python)
%o A157813 from math import gcd
%o A157813 for s in range(2, 100, 2):
%o A157813   for i in range(1, s):
%o A157813     if gcd(i, s - i) != 1: continue
%o A157813     print(s - i)
%o A157813   for i in range(s, 0, -1):
%o A157813     if gcd(i, s + 1 - i) != 1: continue
%o A157813     print(s + 1 - i)
%o A157813 # _Hiroaki Yamanouchi_, Oct 06 2014
%Y A157813 Cf. A157807 (numerators), A038567.
%Y A157813 With Cantor's ordering: A020652, A020653, A352911.
%K A157813 nonn,frac
%O A157813 1,3
%A A157813 _Ron R. King_, Mar 07 2009
%E A157813 a(58)-a(83) from _Hiroaki Yamanouchi_, Oct 06 2014
%E A157813 Name corrected by _Andrey Zabolotskiy_, Oct 10 2023