AutoIt+
  • Overview
  • Getting started
  • The language
    • Basic
    • Grammar
      • Expressions
      • Statements
      • Declarations
    • Operators
    • Variables
    • Types & values
      • Null
      • Booleans
      • Numbers
      • Strings
      • Functions
      • Classes
      • Pointers
    • Control flow
      • If statement
      • For loop
      • While loop
      • Break & continue
      • Error handling
    • Collections
      • Array
        • APIs
        • Implementation
      • Map
        • APIs
        • Implementation
    • Modules
    • Exceptions
  • Built-in modules
    • C
      • APIs
      • Constants
    • Math
      • APIs
      • Constants
    • Task
      • Types
      • APIs
    • Global
  • The aup
    • Compiler
    • Runtime
    • Options
Powered by GitBook
On this page
  • .abs
  • .acos
  • .acosh
  • .asin
  • .asinh
  • .atan
  • .atan2
  • .atanh
  • .ceil
  • .cos
  • .cosh
  • .exp
  • .floor
  • .imul
  • .log
  • .log2
  • .log10
  • .pow
  • .rand
  • .round
  • .sin
  • .sinh
  • .sqrt
  • .tan
  • .tanh

Was this helpful?

  1. Built-in modules
  2. Math

APIs

.abs

math.abs(x: num) -> num

Returns the absolute value of the number.

This function is equivalent to expression (x < 0) ? (-x) : x.

.acos

math.acos(x: num) -> num

Returns the arccosine of a number.

.acosh

math.acos(x: num) -> num

Returns the hyperbolic arccosine of a number.

.asin

math.asin(x: num) -> num

Returns the arcsine of a number.

.asinh

math.asinh(x: num) -> num

Returns the hyperbolic arcsine of a number.

.atan

math.atan(x: num) -> num

Returns the arctangent of a number.

.atan2

math.atan2(x: num, y: num) -> num

Returns the arctangent of the quotient of its arguments.

.atanh

math.atanh(x: num) -> num

Returns the hyperbolic arctangent of a number.

.ceil

math.ceil(x: num) -> num

Returns the smallest integer greater than or equal to a number.

.cos

math.cos(x: num) -> num

Returns the cosine of a number.

.cosh

math.cosh(x: num) -> num

Returns the hyperbolic cosine of a number.

.exp

math.exp(x: num) -> num

Returns E^x, where x is the argument, and E is Euler's constant (2.718…), the base of the natural logarithm.

.floor

math.floor(x: num) -> num

Returns the largest integer less than or equal to a number.

.imul

math.floor(x: num) -> num

Returns the result of a 32-bit integer multiplication.

.log

math.log(x: num) -> num

Returns the natural logarithm (base e logarithm, also ln) of a number.

.log2

math.log2(x: num) -> num

Returns the base 2 logarithm of a number.

.log10

math.log10(x: num) -> num

Returns the base 10 logarithm of a number.

.pow

math.pow(x: num, y: num) -> num

Returns base to the exponent power.

.rand

math.rand() -> num

Returns a pseudo-random number between 0 and 1.

math.rand(n: num) -> num

Returns a random integer between 0 and n.

math.rand(min: num, max: num) -> num

Returns a random integer between min and max.

.round

math.round(x: num) -> num

Returns the value of a number rounded to the nearest integer.

.sin

math.sin(x: num) -> num

Returns the sine of a number.

.sinh

math.sinh(x: num) -> num

Returns the hyperbolic sine of a number.

.sqrt

math.sqrt(x: num)

Returns the positive square root of a number.

.tan

math.tan(x: num) -> num

Returns the tangent of a number.

.tanh

math.tanh(x: num) -> num

Returns the hyperbolic tangent of a number.

PreviousMathNextConstants

Last updated 3 years ago

Was this helpful?