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>.

Package details

AuthorNathan Levett [aut, cre]
MaintainerNathan Levett <nathan.a.z.levett@gmail.com>
LicenseApache License (== 2.0)
Version1.0.0
URL https://github.com/Skenvy/Collatz https://github.com/Skenvy/Collatz/tree/main/R https://skenvy.github.io/Collatz/R/ https://skenvy.github.io/Collatz/R/pdf/
Package repositoryView on CRAN
Installation Install the latest version of this package by entering the following in R:
install.packages("collatz")

Try the collatz package in your browser

Any scripts or data that you put into this service are public.

collatz documentation built on Sept. 5, 2022, 9:06 a.m.