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.

A057115 Order-preserving permutation of the rational numbers (x -> x-1); positions in Stern-Brocot tree.

This page as a plain text file.
%I A057115 #6 May 01 2014 02:48:24
%S A057115 2,4,1,8,9,5,3,16,17,18,19,10,11,6,7,32,33,34,35,36,37,38,39,20,21,22,
%T A057115 23,12,13,14,15,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,40,41,
%U A057115 42,43,44,45,46,47,24,25,26,27,28,29,30,31,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150
%N A057115 Order-preserving permutation of the rational numbers (x -> x-1); positions in Stern-Brocot tree.
%H A057115 <a href="/index/St#Stern">Index entries for sequences related to Stern's sequences</a>
%H A057115 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>
%F A057115 a(n) = frac2position_in_whole_SB_tree(sbtree_perm_1_1_left(SternBrocotTreeNum(n)/SternBrocotTreeDen(n)))
%p A057115 sbtree_perm_1_1_left := x -> (`if`((x <= 0),x,(`if`((x < 1),(x/(1+x)),(`if`((x < 2),(1/(3-x)),(x-1)))))));
%Y A057115 Inverse permutation: A057114.
%Y A057115 When conjugated with A059893, one gets A065260, a valid siteswap permutation.
%Y A057115 The first row of A065626, i.e. a(n) = RotateNodeLeft(1, n).
%K A057115 nonn
%O A057115 1,1
%A A057115 _Antti Karttunen_, Aug 09 2000