pipe generator for (nX)