Copyright | (c) OleksandrZhabenko 2020 |
---|---|
License | MIT |
Stability | Experimental |
Safe Haskell | None |
Language | Haskell2010 |
Maintainer : olexandr543@yahoo.com
Helps to order the 7 or less Ukrainian words (or their concatenations) to obtain (to some extent) suitable for poetry or music text. The main module in the library that imports all other ones except Main.
Synopsis
- type Uniqueness = ([Int], Vector Int, String)
- uniq10Poetical4 :: String -> IO ()
- uniq10Poetical5 :: String -> IO ()
- uniq10PoeticalG :: ([Int] -> Int) -> String -> IO ()
- uniqNPoeticalG :: Int -> ([Int] -> Int) -> String -> IO ()
- uniqNPoeticalGN :: Int -> Int -> Vector ([Int] -> Int) -> String -> IO ()
- uniqNPoetical :: Int -> Vector ([Int], Int, Int, Int, String) -> IO ()
- uniqNPoeticalN :: Int -> Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> IO ()
- uniqNPoeticalV :: Int -> Vector ([Int], Int, Int, Int, String) -> IO (Vector ([Int], Int, Int, Int, String))
- uniqNPoeticalVN :: Int -> Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> IO (Vector Uniqueness)
- uniqNPoeticalVG :: Int -> ([Int] -> Int) -> String -> IO (Vector ([Int], Int, Int, Int, String))
- uniqNPoeticalVGN :: Int -> Int -> Vector ([Int] -> Int) -> String -> IO (Vector Uniqueness)
- uniquenessVariantsG :: ([Int] -> Int) -> String -> Vector ([Int], Int, Int, Int, String)
- uniquenessVariantsGN :: Vector ([Int] -> Int) -> String -> Vector Uniqueness
- uniquenessVariants3 :: String -> Vector ([Int], Int, Int, Int, String)
- uniquenessVariants4 :: String -> Vector ([Int], Int, Int, Int, String)
- uniqMaxPoeticalG :: ([Int] -> Int) -> String -> ([Int], Int, Int, Int, String)
- uniqMaxPoeticalGN :: Int -> Vector ([Int] -> Int) -> String -> Uniqueness
- uniqMaxPoeticalGNV :: Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> Uniqueness
- uniqInMaxPoetical :: Vector ([Int], Int, Int, Int, String) -> IO (Vector ([Int], Int, Int, Int, String))
- uniqInMaxPoeticalN :: Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> IO (Vector Uniqueness)
- uniqNPoetical2GN :: Int -> Int -> Vector ([Int] -> Int) -> (String -> [Int]) -> String -> IO ()
- uniqNPoetical2VGN :: Int -> Int -> Vector ([Int] -> Int) -> (String -> [Int]) -> String -> IO (Vector Uniqueness)
- uniqNPoeticalUGN_ :: Int -> Int -> Int -> Vector ([Int] -> Int) -> String -> IO ()
- uniqNPoeticalUGN :: Int -> Int -> Int -> Vector ([Int] -> Int) -> String -> IO (Vector Uniqueness)
- uniqNPoeticalUGN51_ :: Int -> Int -> String -> IO ()
- uniqNPoeticalUGN51 :: Int -> Int -> String -> IO (Vector Uniqueness)
- uniquenessVariants2GN :: Vector ([Int] -> Int) -> (String -> [Int]) -> String -> Vector Uniqueness
- uniqMaxPoetical2GN :: Int -> Vector ([Int] -> Int) -> (String -> [Int]) -> String -> Uniqueness
Uniqueness type synonym
Main functions
uniq10Poetical4 :: String -> IO () Source #
A variant of uniq10PoeticalG
with the norm4
applied. The list is (according to some model, not universal, but a reasonable one in the most cases) the
most suitable for intonation changing and, therefore, for the accompaniment of the highly changable or variative melody.
uniq10Poetical5 :: String -> IO () Source #
A variant of uniq10PoeticalG
with the norm5
applied. The list is (according to some model, not universal, but a reasonable one in the most cases) the
most suitable for rhythmic speech and two-syllabilistic-based poetry. Therefore, it can be used to create a poetic composition or to emphasize some
thoughts.
uniq10PoeticalG :: ([Int] -> Int) -> String -> IO () Source #
A variant of the uniqNPoeticalG
function with the n
equal to 10.
uniqNPoeticalG :: Int -> ([Int] -> Int) -> String -> IO () Source #
Recursive n :: Int
times application of the uniqInMaxPoetical
function after the uniquenessVariantsG
application to the String
.
Prints n
(or less if there are less of them) maximum elements starting from the first and further to the rest. The norm given defines the way,
in which the elements are considered the "maximum" ones.
uniqNPoeticalGN :: Int -> Int -> Vector ([Int] -> Int) -> String -> IO () Source #
Generalized variant of the uniqNPoeticalG
with usage of several norms.
uniqNPoetical :: Int -> Vector ([Int], Int, Int, Int, String) -> IO () Source #
Recursive n :: Int
times application of the uniqInMaxPoetical
function. Prints n
(or less if there are less of them) maximum elements starting from
the first and further to the rest. The norm given defines the way, in which the elements are considered the "maximum" ones.
uniqNPoeticalN :: Int -> Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> IO () Source #
Generalized variant of the uniqNPoetical
with usage of several norms.
uniqNPoeticalV :: Int -> Vector ([Int], Int, Int, Int, String) -> IO (Vector ([Int], Int, Int, Int, String)) Source #
The result of the recursive n :: Int
times application of the uniqInMaxPoetical
function. The norm given defines the way, in which the elements
are considered the "maximum" ones.
uniqNPoeticalVN :: Int -> Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> IO (Vector Uniqueness) Source #
Generalized variant of the uniqNPoeticalV
with usage of several norms.
uniqNPoeticalVG :: Int -> ([Int] -> Int) -> String -> IO (Vector ([Int], Int, Int, Int, String)) Source #
The result of the recursive n :: Int
times application of the uniqInMaxPoetical
function after the uniquenessVariantsG
application to the String
.
The norm given defines the way, in which the elements are considered the "maximum" ones.
uniqNPoeticalVGN :: Int -> Int -> Vector ([Int] -> Int) -> String -> IO (Vector Uniqueness) Source #
Generalized variant of the uniqNPoeticalVG
with usage of several norms.
Additional functions
uniquenessVariantsG :: ([Int] -> Int) -> String -> Vector ([Int], Int, Int, Int, String) Source #
Given a String
consisting of no more than 7 Ukrainian words [some of them can be created by concatenation with preserving the Ukrainian
pronunciation of the parts, e. g. "так як" (actually two correct Ukrainian words and a single conjunction) can be written "такйак"
(one phonetical Ukrainian word transformed literally with preserving phonetical structure), if you would not like to treat them separately],
it returns a Vector
of possible combinations without repeating of the words in different order and for each of them appends also
the information about uniquenessPeriods
to it and finds out three different metrics -- named "norms".
Afterwards, depending on these norms it can be specified some phonetical properties of the words that
allow to use them poetically or to create a varied melody with them. Some variants of this generalized function are uniquesessVariants3
and
uniquesessVariants4
with the predefined norms.
uniquenessVariantsGN :: Vector ([Int] -> Int) -> String -> Vector Uniqueness Source #
Generalization of the uniquenessVariantsG
with usage of several norms (instead of one). They constitute a Vector
of functions
norm :: [Int] -> Int
. So the inner vector in the each resulting Uniqueness
has the same length as the vector of norms.
uniquenessVariants3 :: String -> Vector ([Int], Int, Int, Int, String) Source #
A variant of uniquesessVariantsG
with the norm being norm3
.
uniquenessVariants4 :: String -> Vector ([Int], Int, Int, Int, String) Source #
A variant of uniquesessVariantsG
with the norm being norm4
.
uniqMaxPoeticalG :: ([Int] -> Int) -> String -> ([Int], Int, Int, Int, String) Source #
Given a norm and a Ukrainian String
consisting of no more than 7 words (see also the information for uniquenessVariantG
), returns the maximum by the
specified norm element of the uniquenessVariantsG
applied to the same arguments.
uniqMaxPoeticalGN :: Int -> Vector ([Int] -> Int) -> String -> Uniqueness Source #
Generalized variant of the uniqMaxPoeticalG
with the several norms given as a Vector
of functions and an Int
parameter. The function evaluates
the generated Vector
of Uniqueness
elements to retrieve the possibly maximum element in it with respect to the order and significance (principality)
of the norms being evaluated. The most significant and principal is the norm, which index in the Vector
of them is the Int
argument of the function
minus 1, then less significant is the next to the left norm and so on.
uniqMaxPoeticalGNV :: Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> Uniqueness Source #
The same as uniqMaxPoetical2GN
but applied to the other last argument. Is used inside the former one.
uniqInMaxPoetical :: Vector ([Int], Int, Int, Int, String) -> IO (Vector ([Int], Int, Int, Int, String)) Source #
Similar to uniqMaxPoeticalG
but instead of resulting in a maximum element, outputs it by parts and returns the rest of the Vector
without this
maximum element.
uniqInMaxPoeticalN :: Int -> Vector ([Int] -> Int) -> Vector Uniqueness -> IO (Vector Uniqueness) Source #
Generalized variant of the uniqInMaxPoetical
with usage of the several norms.
Generalized variants
Main ones
uniqNPoetical2GN :: Int -> Int -> Vector ([Int] -> Int) -> (String -> [Int]) -> String -> IO () Source #
Generalized variant of the uniqNPoeticalG
with usage of the several norms.
uniqNPoetical2VGN :: Int -> Int -> Vector ([Int] -> Int) -> (String -> [Int]) -> String -> IO (Vector Uniqueness) Source #
Generalized variant of the uniqNPoeticalVG
with usage of the several norms.
uniqNPoeticalUGN_ :: Int -> Int -> Int -> Vector ([Int] -> Int) -> String -> IO () Source #
Variant of the uniqNPoetical2GN
, which uses as a function uniquenessPeriods2
with the first argument equal to the first Int
argument.
uniqNPoeticalUGN :: Int -> Int -> Int -> Vector ([Int] -> Int) -> String -> IO (Vector Uniqueness) Source #
Variant of the uniqNPoetical2VGN
, which uses as a function uniquenessPeriods2
with the first argument equal to the first Int
argument.
uniqNPoeticalUGN51_ :: Int -> Int -> String -> IO () Source #
Variant of the uniqNPoeticalUGN_
, which uses as a single norm norm51
.
uniqNPoeticalUGN51 :: Int -> Int -> String -> IO (Vector Uniqueness) Source #
Variant of the uniqNPoeticalUGN
, which uses as a single norm norm51
.
Additional functions
uniquenessVariants2GN :: Vector ([Int] -> Int) -> (String -> [Int]) -> String -> Vector Uniqueness Source #
Generalization of the uniquenessVariantsG
with usage of several norms (instead of one). They constitute a Vector
of functions
norm :: [Int] -> Int
. So the inner vector in the each resulting Uniqueness
has the same length as the vector of norms.
uniqMaxPoetical2GN :: Int -> Vector ([Int] -> Int) -> (String -> [Int]) -> String -> Uniqueness Source #
Generalized variant of the uniqMaxPoeticalG
with the several norms given as a Vector
of functions and an Int
parameter. The function evaluates
the generated Vector
of Uniqueness
elements to retrieve the possibly maximum element in it with respect to the order and significance (principality)
of the norms being evaluated. The most significant and principal is the norm, which index in the Vector
of them is the Int
argument of the function
minus 1, then less significant is the next to the left norm and so on.