3

Given a context-free language $L$, define the language $p(L)$ as containing all permutations of strings in $L$ (i.e. all strings in $L$ such that the order of symbols is not important). Is $p(L)$ context-free?

I found two papers dealing with similar, but not identical, questions:

Raphael
  • 73,212
  • 30
  • 182
  • 400
Erel Segal-Halevi
  • 6,088
  • 1
  • 25
  • 60

2 Answers2

4

Start with simple context-free (or even regular) languages, and see what happens. For instance determine $p(L)$ for $L = (ab)^*$ and $L=(abc)^*$.

Hendrik Jan
  • 31,459
  • 1
  • 54
  • 109
1

No, in general not. For example the MIX language, consisting of equal numbers of $\{a,b,c\}$ in any order is not context-free but is the permutation of the regular language $(abc)^*$.