add pattern inference class and associated tests, so far implemented phase 1 of inference; detecting start and end points of pattern complete.
alterations to pattern following recognition of errors through testing of pattern inference module