Translation Into Definite Clauses
DCG notation is just syntactic sugar for normal definite clauses in Prolog. For example, the previous example could be translated into the following:
sentence(S1,S3) :- noun_phrase(S1,S2), verb_phrase(S2,S3). noun_phrase(S1,S3) :- det(S1,S2), noun(S2,S3). verb_phrase(S1,S3) :- verb(S1,S2), noun_phrase(S2,S3). det(, X). det(, X). noun(, X). noun(, X). verb(, X).Read more about this topic: Definite Clause Grammar
Famous quotes containing the words translation and/or definite:
“The Bible is for the Government of the People, by the People, and for the People.”
—General prologue, Wycliffe translation of the Bible (1384)
“The fact that a man is to vote forces him to think. You may preach to a congregation by the year and not affect its thought because it is not called upon for definite action. But throw your subject into a campaign and it becomes a challenge.”
—John Jay Chapman (18621933)