login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A037162 Well-order the rational numbers; take denominators. 4
1, 1, 1, 1, 2, 2, 1, 1, 3, 3, 1, 1, 2, 3, 4, 4, 3, 2, 1, 1, 5, 5, 1, 1, 2, 3, 4, 5, 6, 6, 5, 4, 3, 2, 1, 1, 3, 5, 7, 7, 5, 3, 1, 1, 2, 4, 5, 7, 8, 8, 7, 5, 4, 2, 1, 1, 3, 7, 9, 9, 7, 3, 1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

REFERENCES

Sierpiński, Cardinal and Ordinal Numbers, Warsaw 1965, 2nd ed., p. 40.

LINKS

Reinhard Zumkeller, Table of n, a(n) for n = 0..10000

MATHEMATICA

order[n_] := Join[-Reverse[ pos = Select[(r = Range[n])/Reverse[r], Numerator[#] + Denominator[#] == n + 1 & ] ], pos]; order[0] = 0; Denominator[ Flatten[ Table[ order[n], {n, 0, 10}]]] (* Jean-François Alcover, Jun 27 2012 *)

PROG

(Haskell)

import Data.List (transpose)

import Data.Ratio ((%), denominator)

a037162 n = a037162_list !! n

a037162_list = 1 : map denominator

  (concat $ concat $ transpose [map (map negate) qss, map reverse qss])

  where qss = map q [1..]

        q x = map (uncurry (%)) $ filter ((== 1) . uncurry gcd) $

                  zip (reverse zs) zs where zs = [1..x]

-- Reinhard Zumkeller, Mar 08 2013

CROSSREFS

Cf. A037161.

Cf. A038567.

Sequence in context: A136480 A050603 A286554 * A278566 A255559 A181935

Adjacent sequences:  A037159 A037160 A037161 * A037163 A037164 A037165

KEYWORD

nonn,easy,nice,frac

AUTHOR

N. J. A. Sloane

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 15 02:31 EDT 2020. Contains 335762 sequences. (Running on oeis4.)