phonetic-languages-phonetics-basics-0.10.0.2: A library for working with generalized phonetic languages usage.
Copyright(c) Oleksandr Zhabenko 2020-2023
LicenseMIT
Maintaineroleksandr.zhabenko@yahoo.com
StabilityExperimental
Safe HaskellSafe-Inferred
LanguageHaskell2010

Phladiprelio.RGLPK.General

Description

Can be used to calculate the durations of the approximations of the phonemes using some prepared text with its correct (at least mostly) pronunciation. The prepared text is located in the same directory and contains lines -the phonetic language word and its duration in seconds separated with whitespace. The library is intended to use the functionality of the :

1) R programming language https://www.r-project.org/

2) Rglpk library https://cran.r-project.org/web/packages/Rglpk/index.html

3) GNU GLPK library https://www.gnu.org/software/glpk/glpk.html

For more information, please, see the documentation for them.

For the model correctness the js here refers to sorted list of the Lexeme representations of the phonetic language phenomenae.

The length of the Lexeme js is refered to as lng::Int. The number of pairs' function elements in the lists is refered to as nn::Int. The number of constraints is refered here as nc::Int. nc == nn quot 2.

Is generalized from the Numeric.Wrapper.R.GLPK.Phonetics.Ukrainian.Durations module from the r-glpk-phonetic-languages-ukrainian-durations package.

Synopsis

Documentation

data PairwisePL Source #

A way to encode the pairs of the phonetic language representations that give some additional associations, connections between elements, usually being caused by some similarity or commonality of the pronunciation act for the phenomenae corresponding to these elements. All [Int] must be equal in length throughout the same namespace and this length is given as Int argument in the PairwisePL. This Int parameter is nn.

Constructors

PW Char Int [Int] 

data PairwiseC Source #

Constructors

LL [PairwisePL] Int 

matrixLine Source #

Arguments

:: Int

The number of pairs' function elements in the lists.

-> PairwiseC

Actually the data type value that sets the behaviour of the pairs' function.

-> [String] 
-> String

A sorted list of the Lexeme representations of the phonetic language phenomenae.

-> String 

Actually n is a length bss.

objLine Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> [(Int, Int)]

List of pairs of indices that shows how the input data is related to the representation (which coefficients relates to which representation elements).

-> Array Int Double

An array of coefficients.

-> String 

objCoeffsNew Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> [(Int, Int)]

List of pairs of indices that shows how the input data is related to the representation (which coefficients relates to which representation elements).

-> Array Int Double

An array of coefficients.

-> [Double] 

A way to reorder the coefficients of the input and the elements representations related to each other.

dirLine Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> Int

The number of pairs' function elements in the lists.

-> [String]

An argument of the matrixLine function.

-> String

A sorted list of the Lexeme representations of the phonetic language phenomenae.

-> String 

rhsLine Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> Int

The number of pairs' function elements in the lists.

-> Double

Maximum duration of the phonetic language element representation in seconds.

-> Double

A minimum positive duration value for some group of phonetic language representation (usually, some sorts of phonemes, e. g. vowels) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for some *special* group of phonetic language representation (usually, some sorts of phonemes, e. g. soft sign representation) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for all other phonetic language representations (usually, some sorts of phonemes) to set a general (common) behaviour for the set of resulting values.

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the some group of representations (e. g. vowels).

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the special group of representations (e. g. soft sign).

-> [Double] 
-> [Double] 
-> String 

minDurations Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> Double

A minimum positive duration value for some group of phonetic language representation (usually, some sorts of phonemes, e. g. vowels) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for some *special* group of phonetic language representation (usually, some sorts of phonemes, e. g. soft sign representation) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for all other phonetic language representations (usually, some sorts of phonemes) to set a general (common) behaviour for the set of resulting values.

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the some group of representations (e. g. vowels).

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the special group of representations (e. g. soft sign).

-> [Double] 

maxDurations Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> Double

Maximum duration of the phonetic language element representation in seconds.

-> [Double] 

answer Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> Int

The number of pairs' function elements in the lists.

-> PairwiseC

Actually the data type value that sets the behaviour of the pairs' function.

-> Double

Maximum duration of the phonetic language element representation in seconds.

-> [(Int, Int)]

List of pairs of indices that shows how the input data is related to the representation (which coefficients relates to which representation elements).

-> Double

A minimum positive duration value for some group of phonetic language representation (usually, some sorts of phonemes, e. g. vowels) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for some *special* group of phonetic language representation (usually, some sorts of phonemes, e. g. soft sign representation) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for all other phonetic language representations (usually, some sorts of phonemes) to set a general (common) behaviour for the set of resulting values.

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the some group of representations (e. g. vowels).

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the special group of representations (e. g. soft sign).

-> Array Int Double

An array of coefficients.

-> [String]

An argument of the matrixLine function.

-> [Double] 
-> [Double] 
-> String

A sorted list of the Lexeme representations of the phonetic language phenomenae.

-> String 

A variant of the more general answer2 where the predefined randomization parameters are used to produce every time being run a new result (e. g. this allows to model accents).

answer2 Source #

Arguments

:: Int

The length of the Lexeme js that is a sorted list of the phonetic language representations as Lexemes that appears in the file with test words and their spoken durations.

-> Int

The number of pairs' function elements in the lists.

-> PairwiseC

Actually the data type value that sets the behaviour of the pairs' function.

-> Double

Maximum duration of the phonetic language element representation in seconds.

-> [(Int, Int)]

List of pairs of indices that shows how the input data is related to the representation (which coefficients relates to which representation elements).

-> Double

A maximum in absolute value (being, usually, a negative one) possible random deviation from the computed value to be additionally applied to emulate 'more natural' behaviour and to get every time while running new sets of values.

-> Double

A maximum in absolute value (being, usually, a positive one) possible random deviation from the computed value to be additionally applied to emulate 'more natural' behaviour and to get every time while running new sets of values.

-> Double

A minimum in absolute value (being, usually, a negative one) possible random deviation from the computed value to be additionally applied to emulate 'more natural' behaviour and to get every time while running new sets of values.

-> Double

A minimum in absolute value (being, usually, a positive one) possible random deviation from the computed value to be additionally applied to emulate 'more natural' behaviour and to get every time while running new sets of values.

-> Double

A minimum positive duration value for some group of phonetic language representation (usually, some sorts of phonemes, e. g. vowels) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for some *special* group of phonetic language representation (usually, some sorts of phonemes, e. g. soft sign representation) to set some peculiar behaviour for the set of resulting values.

-> Double

A minimum positive duration value for all other phonetic language representations (usually, some sorts of phonemes) to set a general (common) behaviour for the set of resulting values.

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the some group of representations (e. g. vowels).

-> [Int]

A list of indices of the phonetic languages representations in their sorted in ascending order sequence that corresponds to the elements from the special group of representations (e. g. soft sign).

-> Array Int Double

An array of coefficients.

-> [String]

An argument of the matrixLine function.

-> [Double] 
-> [Double] 
-> String

A sorted list of the Lexeme representations of the phonetic language phenomenae.

-> String