This algorithm is built on a research paper: doi.org/10.21203/rs.3.rs-2288122/v1, please read the paper before reading the code.
- Set the boundaries in src/lib/ConfigurationForLimitTest.java and src/App.java
- Compile src/App.java:
cd src && javac App.java
- Run the code:
java App
You have four columns for all nontrivial cycles.
- Level: This is the loop level
- Q: the 'q' value in qx+c
- C : the 'c' value in qx+c
- X : the first term in the cycle for a specified qx+c
- CycleLength : The length of the cycle, that is, the distance between the first X occurence (inclusive) and the second X occurence (exclusive). For example, for 5x+3 such that x=-12, the CycleLength is 3 where the sequence is [-12, -6, -3, -12]
- Nontrivial cycle : A cycle such that it does not contain +1 or -1 in its sequence.
This work is licensed under GNU General Public License v3.0, check the full legal text in LICENSE.