Learn R Programming

Zseq (version 0.1.1)

Juggler: Juggler sequence

Description

Under OEIS A094683, a Juggler sequence is an integer-valued sequence that starts with a nonnegative number iteratively follows that \(J_{k+1}=floor(J_k^{1/2})\) if \(J_k\) is even, or \(J_{k+1}=floor(J_k^{3/2})\) if odd. No first 6 terms are given since it all depends on the starting value.

Usage

Juggler(start, Rmpfr = TRUE, PrecisionBits = 496)

Arguments

start

the starting nonnegative integer.

Rmpfr

a logical; TRUE to use large number representation, FALSE otherwise.

PrecisionBits

a positive integer for precision bits larger than 2.

Value

a vector recording the sequence of unknown length a priori.

Examples

Run this code
# NOT RUN {
## let's start from 9 and show the sequence
print(Juggler(9), drop0trailing=TRUE)

# }

Run the code above in your browser using DataLab