LongestCommonGeneralizedRepeatL Type

Evaluates the longest string, that is i) common to a number of words and ii) is repeated a certain number of times in those strings. The number of repeats the string should occur in each word is given by an array of integers here.

This is close to the original implementation, using a linked list of class instances. Thus, a lot (repeats * textlength) class instances will be created as intermediates. The implementation LongestCommonGeneralizedRepeatA is avoiding this by using a array of struct's instead.

For details of the algorithm see the very nice paper by Michael Arnold and Enno Ohlebusch, 'Linear Time Algorithms for Generalizations of the Longest Common Substring Problem', Algorithmica (2011) 60; 806-818; DOI: 10.1007/s00453-009-9369-1. This code was adopted by D.Lellinger from the C++ sources from the web site of the authors at http://www.uni-ulm.de/in/theo/research/sequana.html.

Constructors

Constructor Description

LongestCommonGeneralizedRepeatL(gsa)

Full Usage: LongestCommonGeneralizedRepeatL(gsa)

Parameters:
    gsa : GeneralizedSuffixArray - Generalized suffix array. It is neccessary that this was constructed with individual words.

Initializes a new instance of the problem solver for the repeated longest common substring problem.

gsa : GeneralizedSuffixArray

Generalized suffix array. It is neccessary that this was constructed with individual words.

LongestCommonGeneralizedRepeatL(gsa, x_repeats)

Full Usage: LongestCommonGeneralizedRepeatL(gsa, x_repeats)

Parameters:
    gsa : GeneralizedSuffixArray - Generalized suffix array. It is neccessary that this was constructed with individual words.
    x_repeats : int[] - Array (length: number of words) with the number of repeats that should occur in each of the words.

Initializes a new instance of the problem solver for the repeated longest common substring problem.

gsa : GeneralizedSuffixArray

Generalized suffix array. It is neccessary that this was constructed with individual words.

x_repeats : int[]

Array (length: number of words) with the number of repeats that should occur in each of the words.

Instance members

Instance member Description

this.Evaluate

Full Usage: this.Evaluate

Returns: LongestCommonGeneralizedRepeatL This instance.

Evaluates the repeated longest common substring. After evaluation, the results can be accessed by the properties of this instance. Please be aware that the amount of resulting information depends on the state of P:StoreVerboseResults.

Returns: LongestCommonGeneralizedRepeatL

This instance.

this.Evaluate

Full Usage: this.Evaluate

Parameters:
    x_repeats : int[]

Returns: LongestCommonGeneralizedRepeatL This instance.

Evaluates the repeated longest common substring. After evaluation, the results can be accessed by the properties of this instance. Please be aware that the amount of resulting information depends on the state of P:StoreVerboseResults.

x_repeats : int[]
Returns: LongestCommonGeneralizedRepeatL

This instance.