Skip to content

oceans20737/Collatz_Fermat

Repository files navigation

Collatz Dynamics: Structural Description of the Collatz Inverse Tree via Mersenne-Fermat Factorization and Jacobsthal Sequences

Hiroshi Harada - June 24, 2026

DOI License: MIT Document: CC BY 4.0

Overview

This project is a research dataset that describes and demonstrates the generation structure of the Inverse Tree in the Collatz conjecture as a completely deterministic algebraic process from the perspective of Mersenne-Fermat (M-F) factorization and Jacobsthal (J) sequences.

It shows, both theoretically and via code, the splitting of the "M-type factor" and "F-type factor" generated by transforming an odd nucleus $a$ into the form $a\cdot 2^k - 1$ and embedding it into the Fermat-type difference of squares $(a\cdot 2^k)^2 - 1$, as well as the extraction process of the inverse tree trajectory ($3J$) through a $\pmod{3}$ selection gate.

Files

  • Research Reports:
    • Report_JP.pdf / Report_EN.pdf (Structural Description of the Collatz Inverse Tree via Mersenne-Fermat Factorization and Jacobsthal Sequences)
  • Demonstration Code:
    • collatz_fermat_branches.py: A numerical verification script that computes the M-F split and the selection gate ($3J/cJ$) from an arbitrary odd nucleus, outputting the results as a CSV file.
    • collatz_fermat_cascade.py: A script that uses Graphviz to generate a "cascade decay diagram" illustrating the extraction of the pure trajectory ($J$) and the separation of unnecessary factors ($cJ$) in the reverse Collatz orbit for the initial value $7$.

Usage

Runs in a Python 3.x environment.

1. Running the Numerical Verification Script

python collatz_fermat_branches.py

Note: After execution, a CSV file with the calculation results (e.g., collatz_branches_a=5.csv) will be generated in the current directory. You can test with any odd nucleus by modifying the variable a in the code.

2. Generating the Cascade Decay Diagram

Requires the external library graphviz.

pip install graphviz
python collatz_fermat_cascade.py

Note: After execution, MF_Cascade_Decay.png will be generated in the same directory.

License

Copyright (c) 2026 Hiroshi Harada

About

Collatz Dynamics: Structural Description of the Collatz Inverse Tree via Mersenne-Fermat Factorization and Jacobsthal Sequences

Topics

Resources

License

MIT, MIT licenses found

Licenses found

MIT
LICENSE
MIT
LICENSE_MIT.txt

Stars

1 star

Watchers

0 watching

Forks

Packages

 
 
 

Contributors

Languages