Learn R Programming

⚠️There's a newer version (1.2) of this package.Take me there.

FunWithNumbers (version 1.1)

Fun with Fractions and Number Sequences

Description

A collection of toys to do things like generate Collatz sequences, convert a fraction to "continued fraction" form, calculate a fraction which is a close approximation to some value (e.g., 22/7 or 355/113 for pi), and so on.

Copy Link

Version

Install

install.packages('FunWithNumbers')

Monthly Downloads

238

Version

1.1

License

LGPL-3

Maintainer

Carl Witthoft

Last Published

January 13th, 2022

Functions in FunWithNumbers (1.1)

vaneck

Generate a sequence 'invented' by Jan Ritsema Van Eck
bestFrac

Generate a fraction close to the input value.
sptable

Calculate the number of unique values in the cross-table of sums and products for the input set of numbers
preciseNumbersAsChar

High-precision values for some common constants, in character strings.
bpp

Function which calculates pi, or other irrationals, using the BaileyBorweinPlouffe formula ~~
cfrac

Generate the continued-fraction form of an input number
FunWithNumbers-package

tools:::Rd_package_title("FunWithNumbers")
collatz

Test the Collatz Conjecture. ~~
juggatz

Function which calculates the "Juggler" sequence ~~
aliquot

Generate the Aliquot sequence.
benprob

Generate random numbers based on the Benford distribution
cf2latex

Generate readable equations from the output of cfrac
morris

Generate the Morris sequence