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.
%I A072733 #5 May 01 2014 02:47:42 %S A072733 0,1,5,6,2,14,15,3,9,27,28,10,4,20,44,45,21,7,13,35,65,66,36,16,8,26, %T A072733 54,90,91,55,29,11,19,43,77,119,120,78,46,22,12,34,64,104,152,153,105, %U A072733 67,37,17,25,53,89,135,189,190,136,92,56,30,18,42,76,118,170,230,231 %N A072733 Simple triangle-stretching N X N -> N bijection: Inverse of A072732. %H A072733 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a> %o A072733 (Scheme) (define (A072733 n) (packA072733 (A025581 n) (A002262 n))) %o A072733 (define (packA001477 x y) (/ (+ (expt (+ x y) 2) x (* 3 y)) 2)) %o A072733 (define (packA072733 x y) (cond ((<= x y) (let ((half-x (floor->exact (/ x 2)))) (packA001477 half-x (+ half-x (* 2 (- y (* 2 half-x) (modulo x 2))) (modulo x 2))))) (else (let ((half-y (floor->exact (/ y 2)))) (packA001477 (+ 1 half-y (* 2 (- (-1+ x) (* 2 half-y) (modulo y 2))) (modulo y 2)) half-y))))) %Y A072733 Inverse: A072732, projections: A072738 & A072739, variant of the same theme: A072735. Cf. also A001477 and its projections A025581 & A002262. %K A072733 nonn,tabl %O A072733 0,3 %A A072733 _Antti Karttunen_, Jun 12 2002