For any grammar with maximum rule size n, a fairly straightforward dynamic programming strategy yields an O(N n+4 ) algorithm for parsing sentences of length N .
the overall complexity is unchanged, because each assignment to all variables in each cluster is still considered only once.