P488: Enumeration of all $k$-ary trees with $n$ vertices

P488: Enumeration of all $k$-ary trees with $n$ vertices
Input:
Integers $k$ and $n$.
Output:
All $k$-ary trees with $n$ vertices.
Complexity:
$O(1)$ delay.
Comment:
Only use homogenous transpositions.
Reference:
[VanBaronaigien1988] (Bibtex)