Can we write CFG for this language? I searched multiple websites but I couldn't find any answers.
CFG for L = {a^mb^nc^k: k = m×n}
642 Views Asked by Alex At
1
There are 1 best solutions below
Related Questions in CONTEXT-FREE-GRAMMAR
- Strings from grammar
- Grammar: Precedence of grammar alternatives
- Context Free Grammar BNF
- Xtext grammar describing cron expression not working as expected
- can removing left recursion introduce ambiguity?
- How to match with a expression grammar only the last time a keyword occurs occurs
- This LL(1) parse table is correct?
- syntax-directed definition to determine the type of expression
- Nullable nonterminals
- Is ε terminal in context-free?
- CFG to Regular expression
- How to fix shift-reduce conflict in this grammar
- How to deal with some ambiguous context free grammar productions in Python
- writing a parser in prolog
- How to Generate and display ParseTree for an expression in C# using Irony?
Related Questions in CONTEXT-FREE-LANGUAGE
- L = {www| w belongs to {0,1}*} prove via pumping lemma
- Is this a context free or context sensitive language?
- How to create a context-free grammar?
- 1 or 2 right hand side variable in Context free language
- context-free matching of characters
- Why pumping lemma for context free languages do not have bound on first part of string?
- NLTK tell if word is generated by CFG
- Implementation of a context-free grammar for logical operators with parentheses
- CFG for a = b and c = d (length)
- In Context Free Grammer, do we replace all variable during a substitution? or can we apply substitution rule to only of the variable of same type?
- CFG for L = {a^mb^nc^k: k = m×n}
- bounded PDA and context-free languages
- Describe the language generated by this context-free grammar
- Context-free grammar for the language L = {a^(n)b^(m)c^(k): m = |i - k|}
- What makes this example a context-free language rather than regular language?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
We can prove this is not context-free using the pumping lemma for context-free languages, as follows.
Assume the language were context-free. Then we'd be able to write any string w in the language as w = uvxyz where |vxy| <= p, |vy| > 0 and for all integers k >= 0, u(v^k)x(y^k)z is also a string in the language.
Consider the string a^(2p) b^(3p) c^(6p^2). This is a string in our language since 2p x 3p = 6p^2. Now, consider the five cases for the placement of the substring vxy:
In all five possible cases we see the equality cannot be maintained while pumping down (choosing k = 0) and so our string cannot be pumped down. But then the language cannot be context-free.