This script is simply provided because a few rare people may actually be able to use one or two coding ideas. It is not possible to provide useful (description, explanation)s here. Maybe you can find those with a webSearch. If anybody is interested in the basic concept, just copy the code and run with it.
As the original was in violation of PineScript rules, I've removed many links, including : - documentation of my code - external sources of code - blog solutions to Pine script programming - math, science references, people
Hopefully it will won't be rejected this time, if so, too bad. I only made it through 10% of the conceptual objectives, and I do not believe any of the rest of the concepts are do-able in Pine Script. The current coding is (incomplete, unstable) but does give a faint idea of my "first step" intents. I have stopped all work, as I have to get back to my real projects (nothing to do with markets).