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, ...).

Original entry on oeis.org

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, 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, 4, 7, 8, 11, 13, 14, 15, 13, 11, 9, 7, 5, 3, 1, 1, 2, 3, 4
Offset: 1

Views

Author

Ron R. King, Mar 07 2009

Keywords

Crossrefs

Cf. A157807 (numerators), A038567.
With Cantor's ordering: A020652, A020653, A352911.

Programs

  • Maple
    R:= NULL: count:= 0:
    for m from 2 while count < 100 do
      S:= select(t -> igcd(t,m-t)=1, [$1..m-1]);
      count:= count+nops(S);
      if m::odd then R:= R, op(S) else R:= R, seq(m-t,t=S) fi;
    od:
    R; # Robert Israel, Oct 09 2023
  • Python
    from math import gcd
    for s in range(2, 100, 2):
      for i in range(1, s):
        if gcd(i, s - i) != 1: continue
        print(s - i)
      for i in range(s, 0, -1):
        if gcd(i, s + 1 - i) != 1: continue
        print(s + 1 - i)
    # Hiroaki Yamanouchi, Oct 06 2014

Extensions

a(58)-a(83) from Hiroaki Yamanouchi, Oct 06 2014
Name corrected by Andrey Zabolotskiy, Oct 10 2023