Open pristinawang opened 1 year ago
$$ \text{Time Complexity of variant 1} = O(N^3 \cdot K^3) $$
$$ \text{Time Complexity of variant 2} = O(N^3 \cdot K^2 \cdot D) $$
$$ \text{Time Complexity of variant 3} = O(N^3 \cdot K^2) $$
$$ \text{Time Complexity of variant 1} = O(N^3 \cdot G) $$
$$K = Number \ of \ Non-Terminals$$
$$D = Rules \ with \ YZ \ on \ RHS$$
$$G = Searching \ entire \ Grammar$$
CKY Algorithm
$$ \text{Time Complexity of variant 1} = O(N^3 \cdot K^3) $$
$$ \text{Time Complexity of variant 2} = O(N^3 \cdot K^2 \cdot D) $$
$$ \text{Time Complexity of variant 3} = O(N^3 \cdot K^2) $$
$$ \text{Time Complexity of variant 1} = O(N^3 \cdot G) $$
$$K = Number \ of \ Non-Terminals$$
$$D = Rules \ with \ YZ \ on \ RHS$$
$$G = Searching \ entire \ Grammar$$