Next: Limitations of the Pumping
Up: Proving that a Language
Previous: The Pumping Lemma for
  Contents
Lemma: The language
=
is not context free.
Proof (By contradiction)
Suppose this language is context-free; then it has a context-free grammar.
Let
be the constant associated with this grammar by the Pumping Lemma.
Consider the string
, which is in
and has length greater than
.
By the Pumping Lemma this must be representable as
, such that all
are also in
.
This is impossible, since:
- -
- either
or
cannot contain a mixture of letters from
;
otherwise they would be in the wrong order for
- -
- if
or
conatin just `a's, `b's or `c's, then
cannot
maintain the balance between the three letters (it can, of course maintain the
balance between two)
Lemma: The language
=
is not context free.
Proof (By contradiction)
Suppose this language is context-free; then it has a context-free grammar.
Let
be the constant associated with this grammar by the Pumping Lemma.
Consider the string
, which is in
and has length greater than
.
By the Pumping Lemma this must be representable as
, such that all
are also in
.
- -
- By the same argument as for the previous lemma neither
nor
may contain a
mixture of symbols.
- -
- Suppose
consists entirely of `a's.
Then there is no way
, which cannot have both `b's and `c's,
can generate enough of these letters to keep
their number greater than that of the `a's (it can do it for one or the other
of them, not both).
Similarly
cannot consist of just `a's.
- -
- So suppose then that
or
contains only `b's or only `c's.
Consider the string
which must be in
. Since we have dropped both
and
, we must have at least one `b' or one `c' less than we had in
, which was
. Consequently, this string no longer
has enough of either `b's or `c's to be a member of
.
Next: Limitations of the Pumping
Up: Proving that a Language
Previous: The Pumping Lemma for
  Contents
James Power
2002-11-29