Lehmer code: Difference between revisions

Content deleted Content added
Reverted good faith edits by Darcourse (talk): Duplicates the table already given (but in reverse). (TW)
m Number of right-to-left minima and maxima: LaTeX spacing clean up, replaced: \ </math> → </math> (2) using AWB
Line 45:
Definition : In a sequence ''u{{=}}(u<sub>k</sub>)<sub>1≤k≤n</sub>'', there is '''right-to-left minimum''' (resp. '''maximum''') at rank ''k'' if ''u<sub>k</sub>'' is strictly smaller (resp. strictly bigger) than each element ''u<sub>i</sub>'' with ''i&gt;k'', i.e., to its right.
 
Let ''B(k)'' (resp. ''H(k)'') be the event "there is right-to-left minimum (resp. maximum) at rank ''k''", i.e. ''B(k)'' is the set of the permutations <math>\scriptstyle\ \mathfrak{S}_n\ </math> which exhibit a right-to-left minimum (resp. maximum) at rank ''k''. We clearly have
<center><math>\{\omega\in B(k)\}\Leftrightarrow\{L(k,\omega)=1\}\quad\text{and}\quad\{\omega\in H(k)\}\Leftrightarrow\{L(k,\omega)=k\}.</math></center>
Thus the number ''N<sub>b</sub>(ω)'' (resp. ''N<sub>h</sub>(ω)'') of right-to-left minimum (resp. maximum) for the permutation ''ω'' can be written as a sum of independent [[Bernoulli random variable]]s each with a respective parameter of 1/k :
<center><math>N_b(\omega)=\sum_{1\le k\le n}\ 1\!\!1_{B(k)}\quad\text{and}\quad N_b(\omega)=\sum_{1\le k\le n}\ 1\!\!1_{H(k)}.</math></center>
Indeed, as ''L(k)'' follows the uniform law on <math>\scriptstyle\ [\![1,k]\!],\ </math>
<center><math>\mathbb{P}(B(k))=\mathbb{P}(L(k)=1)=\mathbb{P}(H(k))=\mathbb{P}(L(k)=k)=\tfrac1k.</math></center>
The [[generating function]] for the Bernoulli random variable <math>1\!\!1_{B(k)}</math> is