Package: collatz 1.0.1

Nathan Levett

collatz: Functions Related to the Collatz/Syracuse/3n+1 Problem

Provides the basic functionality to interact with the Collatz conjecture. The parameterisation uses the same (P,a,b) notation as Conway's generalisations. Besides the function and reverse function, there is also functionality to retrieve the hailstone sequence, the "stopping time"/"total stopping time", or tree-graph. The only restriction placed on parameters is that both P and a can't be 0. For further reading, see <https://en.wikipedia.org/wiki/Collatz_conjecture>.

Authors:Nathan Levett [aut, cre]

collatz_1.0.1.tar.gz
collatz_1.0.1.zip(r-4.5)collatz_1.0.1.zip(r-4.4)collatz_1.0.1.zip(r-4.3)
collatz_1.0.1.tgz(r-4.5-any)collatz_1.0.1.tgz(r-4.4-any)collatz_1.0.1.tgz(r-4.3-any)
collatz_1.0.1.tar.gz(r-4.5-noble)collatz_1.0.1.tar.gz(r-4.4-noble)
collatz_1.0.1.tgz(r-4.4-emscripten)collatz_1.0.1.tgz(r-4.3-emscripten)
collatz.pdf |collatz.html
collatz/json (API)

# Install 'collatz' in R:
install.packages('collatz', repos = c('https://skenvy.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/skenvy/collatz/issues

Pkgdown site:https://skenvy.github.io

On CRAN:

Conda-Forge:

collatz

6.42 score 6 stars 9 scripts 229 downloads 5 exports 1 dependencies

Last updated 4 days agofrom:f0d6b3859d. Checks:1 OK, 8 NOTE. Indexed: yes.

TargetResultLatest binary
Doc / VignettesOKMar 03 2025
R-4.5-winNOTEMar 03 2025
R-4.5-macNOTEMar 03 2025
R-4.5-linuxNOTEMar 03 2025
R-4.4-winNOTEMar 03 2025
R-4.4-macNOTEMar 03 2025
R-4.4-linuxNOTEMar 03 2025
R-4.3-winNOTEMar 03 2025
R-4.3-macNOTEMar 03 2025

Exports:collatz_functionhailstone_sequencereverse_functionstopping_timetree_graph

Dependencies:gmp

collatz

Rendered fromcollatz.Rmdusingknitr::rmarkdownon Mar 03 2025.

Last update: 2022-08-27
Started: 2022-08-27

Hailstone of 27+576460752303423488

Rendered fromhailstones_576460752303423488.Rmdusingknitr::rmarkdownon Mar 03 2025.

Last update: 2022-08-27
Started: 2022-08-27

Hailstone Sequences

Rendered fromhailstones.Rmdusingknitr::rmarkdownon Mar 03 2025.

Last update: 2022-08-27
Started: 2022-08-27

Tree Graphs

Rendered fromtreegraphs.Rmdusingknitr::rmarkdownon Mar 03 2025.

Last update: 2022-08-27
Started: 2022-08-27

Readme and manuals

Help Manual

Help pageTopics
Sane Parameter Checkassert_sane_parameterication
Collatzcollatz-package collatz
The Collatz functioncollatz_function
Hailstone Sequencerhailstone_sequence
The "inverse"/"reverse" Collatz functionreverse_function
Stopping Timestopping_time
Stopping Time Terminusstopping_time_terminus
Tree Graphtree_graph