Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 32

Made By: ABHIROOP SONI ABHISHEK DARGAN AKSHAT JAIN AYUSH MADAAN

Chomsky Normal Form


A CFG is in Chomsky Normal Form if each rule is

of the form:

A BC A a S where B,C V {S}

Reduction to Chomsky Normal Form


To convert a grammar to CNF, following steps have to be followed: Step 1: Elimination of null productions and unit productions Step 2: Elimination of terminals on R.H.S. Step 3: Restricting the number of variables on R.H.S. (or removing useless productions)

JFLAP
JFLAP is software for experimenting with formal languages topics including nondeterministic finite automata, nondeterministic pushdown automata, and multi-tape Turing machines, several types of grammars, parsing, and L-systems.

Problem & Solution using JFLAP


Ques. Convert to Chomsky Normal Form (CNF):

Consider, P = {SAB, Aa, BC|b, CD, DE, Ea} Remove Lambda Productions Remove Unit Productions Remove Useless Productions Convert to CNF

SOLUTION

You might also like