Learn R Programming

Brobdingnag (version 1.2-9)

infinite-methods: Infinite brobs and glubs

Description

Brobdingnagian and Glubbdubdribian infinity

Usage

# S4 method for brob
is.infinite(x)
# S4 method for glub
is.infinite(x)
# S4 method for brob
is.finite(x)
# S4 method for glub
is.finite(x)

Arguments

x

vector of class brob or glub

Author

Robin K. S. Hankin

Details

For a Brobdingnagian number, is.infinite() returns TRUE if the exponent is infinite.

A Glubbdubdribian number is infinite if either the real or imaginary component is infinite.

Function is.finite() is simply the logical negation of is.infinite().

Examples

Run this code

is.infinite(brob(c(1,4,Inf)))

is.infinite(glub(3,Inf))
is.infinite(glub(Inf,3))


is.infinite(exp(1e300))
is.infinite(brob(1e300))
# (Brobdingnagian infinity is bigger than regular infinity ;-)


Run the code above in your browser using DataLab