DocumentCode
3408040
Title
A Sentence Generation Algorithm for Testing Grammars
Author
Zheng, Lixiao ; Wu, Duanyi
Author_Institution
Inst. of Software, State Key Lab. of Comput. Sci., Chinese Acad. of Sci., Beijing, China
Volume
1
fYear
2009
fDate
20-24 July 2009
Firstpage
130
Lastpage
135
Abstract
One simple approach to testing grammars is to derive a number of sentences from the grammar under test and to validate whether they comply with the intended language. Purdom has proposed a by-now folklore sentence generation algorithm which however suffers from the fact that the sentences generated are usually too few and some of them are long with complicated derivation structures. In this paper, we present an improved algorithm which incorporates a length control mechanism into the generation process to produce more and simpler sentences. Experiments demonstrate that besides the benefits for user validation and error location, our algorithm is also helpful in highlighting more errors in some cases.
Keywords
context-free grammars; program debugging; program testing; program verification; by-now folklore sentence generation algorithm; complicated derivation structure; context-free grammar testing; error location; grammar debugging; length control mechanism; user validation; Algorithm design and analysis; Application software; Computer applications; Computer errors; Computer science; Laboratories; Natural languages; Software algorithms; Software testing; Terminology;
fLanguage
English
Publisher
ieee
Conference_Titel
Computer Software and Applications Conference, 2009. COMPSAC '09. 33rd Annual IEEE International
Conference_Location
Seattle, WA
ISSN
0730-3157
Print_ISBN
978-0-7695-3726-9
Type
conf
DOI
10.1109/COMPSAC.2009.193
Filename
5254270
Link To Document