ShannonMarkovSet:
Filter:
Classes (extension) | Collections > Unordered | Libraries > MathLib > Markov & Fuzzy

ShannonMarkovSet : Object
ExtensionExtension

shannon implementation of a markov set
Subclasses: ShannonFinger

Description

The basic shannon implementation of a markov set is to simply leave the data as it is and to iterate over it by doing random jumps and looking for the next matching item. The item that follows that one is the next item of the chain. As this requires searching the data, which can be of very irregular efficiency, this current implementation uses an identity dictionary to find the indices of items in constant time. Higher order is slightly more costly, but still this is a major speed increase.

This implementation allows to vary the order at each step and it is very fast in reading. In difference to MarkovSet and MarkovSetN it can only read data as a chain, not as single nodes. Also it does not compress data, as the standard implementation does.

Part of MathLib, a diverse library of mathematical functions.

Class Methods

Inherited class methods

Undocumented class methods

ShannonMarkovSet.fill(size, stream)

ShannonMarkovSet.new(size: 8)

Instance Methods

Inherited instance methods

Undocumented instance methods

.add(item)

.addAll(array)

.asStream(order: 1, repeats: inf)

.chooseIndex

.clear(size)

.data

.data = array

.fitKey(index, prevIndex, order: 1)

.indexOf(obj)

.maxSearchLength

.maxSearchLength = value

.next(object, order: 1)

.nextIndex(prevIndex, order: 1)

.notify

.notify = value

.parse(pattern, length)

.put(i, item)

.scanForNextIndex(index, prevIndex, order: 1)

.seeds

.seeds = value

.wrapPut(i, item)

Examples

shannon markov

empty set test

Authors

Julian Rohrhuber, et al, 2003.