To demonstrate it, let's use the alphabet:
a = {A.B.C.D.E.F.G.H.I.J.K.L.M.N.O.P.Q.R.S.T.U.V.W.X.Y.Z}Now put it to use (for brevity I omit the gm2sw-v2.py and load into console step):
sa: next[0] |A> incoming_sequence: ['A'] |B . C . D . E . F . G . H . I . J . K . L . M . N . O . P . Q . R . S . T . U . V . W . X . Y . Z> |B> sa: next[0] |A.E> incoming_sequence: ['A', 'E'] nodes 1: 0.1|node 1: 0> intersected nodes: |> |> sa: next[1] |A.E> incoming_sequence: ['A', 'E'] nodes 1: 0.1|node 1: 0> intersected nodes: |> |> sa: next[2] |A.E> incoming_sequence: ['A', 'E'] nodes 1: 0.1|node 1: 0> intersected nodes: |> |> sa: next[3] |A.E> incoming_sequence: ['A', 'E'] nodes 1: 0.1|node 1: 0> intersected nodes: 0.1|node 1: 4> |F . G . H . I . J . K . L . M . N . O . P . Q . R . S . T . U . V . W . X . Y . Z> |F> sa: next[4] |A.E> incoming_sequence: ['A', 'E'] nodes 1: 0.1|node 1: 0> intersected nodes: 0.1|node 1: 4> |F . G . H . I . J . K . L . M . N . O . P . Q . R . S . T . U . V . W . X . Y . Z> |F>So, what is happening there? Well in the first example, given A, predict the rest of the alphabet. Next example, given A followed by E, predict the rest of the sequence. But observe we get the null result |> until we specify a skip of at least size 3. And that's it! A small improvement to our next operator.
No comments:
Post a Comment