Changes

504 bytes added ,  06:53, April 11, 2012
Line 51: Line 51:  
The stages in the generation of these examples are as follows:
 
The stages in the generation of these examples are as follows:
 
:''Sentence''
 
:''Sentence''
−
:''NounPhrase'' ''VerbPhrase''
+
:-> ''NounPhrase'' ''VerbPhrase''
−
:''Determiner'' ''Noun'' ''Verb'' ''NounPhrase''
+
:-> ''Determiner'' ''Noun'' ''Verb'' ''NounPhrase''
−
:''Determiner'' ''Noun'' ''Verb'' ''Determiner'' ''Noun''
+
:-> ''Determiner'' ''Noun'' ''Verb'' ''Determiner'' ''Noun''
   −
By choosing the various options for ''Determiner'', ''Noun'', and ''Verb'', we can, in this simple case, generate 108 (= 2 * 3 * 3 * 2 * 3) different grammatical sentences.  
+
By appropriate selection of words to substitute for ''Determiner'', ''Noun'', and ''Verb'' we can produce the 3 example sentences above.
 +
 
 +
The simple grammar defines a few words which can be substituted for ''Determiner'', ''Noun'', and ''Verb''. There are two possibilities for ''Determiner'', three for ''Noun'', and three for ''Verb'', with both ''Determiner'' and ''Noun'' appearing twice in the expansion. Hence the total number of grammatical sentences which can be generated by this simple grammar is 108 (= 2 * 3 * 3 * 2 * 3). In this particular case the possible words have been carefully chosen so that all of these 108 sentences also actually mean something.
    
==Caution==
 
==Caution==
SkipCaptcha
265

edits