20.07.2013 Views

Notes on computational linguistics.pdf - UCLA Department of ...

Notes on computational linguistics.pdf - UCLA Department of ...

Notes on computational linguistics.pdf - UCLA Department of ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Stabler - Lx 185/209 2003<br />

10.5.1 Representing the derivati<strong>on</strong>s<br />

C<strong>on</strong>sider the c<strong>on</strong>text free grammar G1 =〈Σ,N,→〉, where<br />

Σ ={p, q, r, ¬, ∨, ∧},<br />

N ={S}, and<br />

→ has the following 6 pairs in it:<br />

S → p S → q S → r<br />

S →¬S S → S ∨ S S → S ∧ S<br />

This grammar is ambiguous since we have two derivati<strong>on</strong> trees for ¬p ∧ q:<br />

S<br />

¬ S<br />

S<br />

p<br />

∧ S<br />

q<br />

Here we see that the yield ¬p ∧ q does not determine the derivati<strong>on</strong>.<br />

One way to eliminate the ambiguity is with parentheses. Another way is to use Polish notati<strong>on</strong>. C<strong>on</strong>sider<br />

the c<strong>on</strong>text free grammar G2 =〈Σ,N,→〉, where<br />

Σ ={p, q, r, ¬, ∨, ∧},<br />

N ={S}, and<br />

→ has the following 6 pairs in it:<br />

S<br />

¬ S<br />

p<br />

S<br />

∧ S<br />

S → p S → q S → r<br />

S →¬S S →∨SS S→∧SS<br />

With this grammar, we have just <strong>on</strong>e derivati<strong>on</strong> tree for ∧¬pq, and just <strong>on</strong>e for ¬∧pq:<br />

C<strong>on</strong>sider the minimalist grammar G2 =〈Σ,N,Lex,F〉,where<br />

Σ ={p, q, r, ¬, ∨, ∧},<br />

N ={S}, and<br />

Lex has the following 6 lexical items built from Σ and N:<br />

p :: S q :: S r :: S<br />

¬ :: =S S ∨ :: =S =S S ∧ :: =S =S S<br />

This grammar has ambiguous expressi<strong>on</strong>s, since we have the following two different two derivati<strong>on</strong>s <strong>of</strong> ¬p ∧q:<br />

∧q : =S S<br />

∧ :: =S =S S q :: S<br />

¬p ∧ q : S<br />

¬p : S<br />

¬ :: =S S p :: S<br />

q<br />

¬p ∧ q : S<br />

¬ :: =S S p ∧ q : S<br />

∧q : =S S<br />

∧ :: =S=SS q :: S<br />

p :: S<br />

These corresp<strong>on</strong>d to trees that we might depict with X-bar structure in the following way:<br />

224

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!