From 39b3f8bcc2251d6fb99d3f6acaf0cca0e7ce180d Mon Sep 17 00:00:00 2001 From: Lucien Cartier-Tilet Date: Sun, 24 Apr 2022 03:21:18 +0200 Subject: [PATCH] Delete two unused files --- content/archived/headers.tex | 1 - content/archived/hjelp/tools/gen.cc | 66 ----------------------------- 2 files changed, 67 deletions(-) delete mode 120000 content/archived/headers.tex delete mode 100644 content/archived/hjelp/tools/gen.cc diff --git a/content/archived/headers.tex b/content/archived/headers.tex deleted file mode 120000 index a80f2e7..0000000 --- a/content/archived/headers.tex +++ /dev/null @@ -1 +0,0 @@ -../headers.tex \ No newline at end of file diff --git a/content/archived/hjelp/tools/gen.cc b/content/archived/hjelp/tools/gen.cc deleted file mode 100644 index a76135b..0000000 --- a/content/archived/hjelp/tools/gen.cc +++ /dev/null @@ -1,66 +0,0 @@ -#include -#include -#include -#include -#include -#include -#include -#include - -using namespace std; - -int main() { - srand(time(nullptr)); - - vector consonants{"", "m", "n", "ng", "p", "b", "t", "d", - "ŧ", "đ", "k", "g", "f", "v", "þ", "ð", - "s", "z", "sh", "zh", "ch", "jh", "qh", "rh", - "h", "ŕ", "r", "lh", "l"}; - const vector glides{"j", "w"}; - vector vowels{"i", "y", "u", "ì", "ĩ", "ů", "ù", "ũ", "e", "é", "ø", - "ö", "o", "õ", "è", "œ", "ô", "ò", "a", "å", "ã"}; - const vector tones{"2", "3", "4", "5", "6", "7"}; - { - const auto tmp = consonants; - for_each(begin(tmp), end(tmp), [&](const auto &cons) { - for_each(begin(glides), end(glides), - [&](const auto &glide) { consonants.push_back(cons + glide); }); - }); - } - { - const auto tmp = vowels; - // create each possible diphthong - for_each(begin(tmp), end(tmp), [&](const auto &vow1) { - // add tones for this vowel - std::for_each(std::begin(tones), std::end(tones), - [&](const auto &tone) { vowels.push_back(vow1 + tone); }); - for_each(begin(tmp), end(tmp), [&](const auto &vow2) { - if (vow1 != vow2) { - // if both vowels are the same, their association is ignored - const auto new_vow = vow1 + vow2; - vowels.push_back(new_vow); - // add tones to these vowels - for_each(begin(tones), end(tones), - [&](const auto &tone) { vowels.push_back(new_vow + tone); }); - } - }); - }); - } - auto all_phonemes = vowels; - for_each(begin(consonants), end(consonants), [&](const auto &cons) { - for_each(begin(vowels), end(vowels), - [&](const auto &vow) { all_phonemes.push_back(cons + vow); }); - }); - all_phonemes.shrink_to_fit(); - printf("%zu syllables\n", all_phonemes.size()); - set particules = {}; - for (auto i = 0; i < 10000; ++i) { - int random = rand() % all_phonemes.size(); - printf("%s\n", all_phonemes[random].c_str()); - all_phonemes.erase(all_phonemes.begin() + random); - } - std::for_each(std::begin(particules), std::end(particules), - [](const auto &elem) { printf("%s\n", elem.c_str()); }); - - return 0; -}