packages feed

dobutokO-poetry-general-languages 0.1.0.0 → 0.2.0.0

raw patch · 3 files changed

+25/−4 lines, 3 filesdep ~uniqueness-periods-generalPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: uniqueness-periods-general

API changes (from Hackage documentation)

+ DobutokO.Poetry.Languages.UniquenessPeriodsG: uniqueness2nG :: [String] -> (String -> Vector String) -> Int -> ([String] -> [Int]) -> ([String] -> Int) -> Int -> ([[String]], [String]) -> [Int]
+ DobutokO.Poetry.Languages.UniquenessPeriodsG: uniquenessPeriodsN :: [String] -> (String -> Vector String) -> Int -> Int -> String -> [Int]

Files

ChangeLog.md view
@@ -3,3 +3,8 @@ ## 0.1.0.0 -- 2020-08-18  * First version. Released on an unsuspecting world.++## 0.2.0.0 -- 2020-08-18++* Second version. Added new functions uniqueness2nG and uniquenessPeriodsN to the DobutokO.Poetry.Languages.UniquenessPeriodsG module. Some documentation improvements +for the module. Changed the dependency boundaries for the uniqueness-periods-general.
DobutokO/Poetry/Languages/UniquenessPeriodsG.hs view
@@ -62,17 +62,33 @@     let ys = f xs         y2s = mconcat . h $ ys in (ys,y2s) --- | Being given two functions as parameters uses them to create a longer list of 'Int' then application of only one of them. Besides, it can take into +-- | Being given two functions as parameters uses them to create a longer list of 'Int' than just application of only one of them. Besides, it can take into  -- account the possible 0 and to create a non-negative list of 'Int' that can be used e. g. by 'DobutokO.Poetry.Norms.splitNorm'. uniqueness2n :: ([String] -> [Int]) -> ([String] -> Int) -> Int -> ([[String]], [String]) -> [Int] uniqueness2n h f2 x (ys,y2s)   | x == 0 = fmap f2 ys ++ (0:h y2s)  | otherwise = fmap f2 ys ++ h y2s +-- | Approximates the higher order computational scheme of the 'uniqueness2n' function considering the latter one as the second order computational scheme. Because +-- of the possible concatenation and other not phonetic coversions it cannot be considered the exact one, but in some cases can give more information about phonetic +-- \"uniqueness periods\" structure, so is provided here for exploration.+uniqueness2nG :: [String] -> (String -> V.Vector String) -> Int -> ([String] -> [Int]) -> ([String] -> Int) -> Int -> ([[String]], [String]) -> [Int] +uniqueness2nG whspss g n h f2 x (ys,y2s)+ | compare n 2 == LT = error "DobutokO.Poetry.Languages.UniquenessPeriodsG.uniqueness2nG: undefined for that third argument. "+ | n == 2 = uniqueness2n h f2 x (ys,y2s)+ | x == 0 = fmap f2 ys ++ (0:(uniqueness2nG whspss g (n - 1) h f2 0 . uniqueness2 (show7s6 whspss g) (uniquenessP2) . mconcat $ y2s))+ | otherwise = fmap f2 ys ++ (uniqueness2nG whspss g (n - 1) h f2 x . uniqueness2 (show7s6 whspss g) (uniquenessP2) . mconcat $ y2s)++-- | Approximates the higher order computational scheme of the 'uniquenessPeriods2' function considering the latter one as the second order computational +-- scheme. Because of the possible concatenation and other not phonetic coversions it cannot be considered the exact one, but in some cases can give more +-- information about phonetic \"uniqueness periods\" structure, so is provided here for exploration.+uniquenessPeriodsN :: [String] -> (String -> V.Vector String) -> Int -> Int -> String -> [Int]+uniquenessPeriodsN whspss g n x = uniqueness2nG whspss g n (show7snc whspss) (length) x . uniqueness2 (show7s6 whspss g) (uniquenessP2)+ -- | Filters a given arguments so that each element 'String' in the result is filtered from the element, which is doubled the first in the next 'String'  -- (usually, it equals to the head of it, if used as expected). Can be interpreted as a preparation to the second application of the 'uniquenessPeriods'  -- function because it removes the elements that splitted the input into lists and can be seen as a second deeper (so, probably less significant) factor --- of the uniqueness phonetical structure. +-- of the uniqueness phonetic structure.  uniquenessP2 :: [[String]] -> [[String]] uniquenessP2 (yss:ysss)    | null ysss = [yss]
dobutokO-poetry-general-languages.cabal view
@@ -2,7 +2,7 @@ -- documentation, see http://haskell.org/cabal/users-guide/  name:                dobutokO-poetry-general-languages-version:             0.1.0.0+version:             0.2.0.0 synopsis:            Helps to order the 7 or less words to obtain somewhat suitable for poetry or music text description:         Helps to order the 7 or less words (or their concatenations) to obtain somewhat suitable for poetry or music text. Can be also used as a research instrument with generalized functions. @@ -21,6 +21,6 @@   exposed-modules:     DobutokO.Poetry.Languages.UniquenessPeriodsG, DobutokO.Poetry.Languages.General, DobutokO.Poetry.Languages.General.Debug   -- other-modules:   other-extensions:    CPP-  build-depends:       base >=4.7 && <4.15, vector >=0.11 && <0.14, mmsyn3 >=0.1.5 && <1, mmsyn6ukr >=0.8 && <1, uniqueness-periods-general >=0.1 && <1, dobutokO-poetry-general >=0.1 && <1+  build-depends:       base >=4.7 && <4.15, vector >=0.11 && <0.14, mmsyn3 >=0.1.5 && <1, mmsyn6ukr >=0.8 && <1, uniqueness-periods-general >=0.2 && <1, dobutokO-poetry-general >=0.1 && <1   -- hs-source-dirs:   default-language:    Haskell2010