| Lua bc (big number) functions |
|---|
| Big number (bc) functions This library lets you do arbitrary precision (big number) arithmetic. Big numbers have a metatable attached to them so you can add, subtract, divide, multiply, raise to a power, and compare them in the usual way. You can also use bc.add, bc.sub, bc.div, bc.mul, and bc.pow to do the same operations. Thus, the following two forms are equivalent: Also see:
Some useful constants are: See Also ... Topics
Lua base functions
Lua bit manipulation functions
Lua coroutine functions
Lua debug functions
Lua io functions
Lua math functions
Lua os functions
Lua package functions
Lua PCRE regular expression functions
Lua script extensions
Lua string functions
Lua table functions
Lua utilities
ScriptingLua functions
bc.add (Addition)
bc.compare (Comparison)
bc.digits (Digits after the decimal place)
bc.div (Division)
bc.isneg (Tests if negative)
bc.iszero (Tests if zero)
bc.mod (Modulus)
bc.mul (Multiplication)
bc.number (Create a big number)
bc.pow (Power)
bc.sqrt (Square root)
bc.sub (Subtraction)
bc.tostring (Converts to a string)
bc.version (Version)(Help topic: general=lua_bc)
Documentation contents page |