Reference. Stack permutations and an order relation for binary trees [hille1982stack]

An isomorphism between stack permutations of a set of $n$ elements and ordered binary trees with $n$ vertices is presented. which allows the construction of simple linear time algorithms to compute a ranking function and its inverse for binary trees. No pre-processing of tables is required, as was the case with previously published methods.

@article{hille1982stack,
  title={Stack permutations and an order relation for binary trees},
  author={Hille, Reinhold Friedrich},
  year={1982}
}