Mathjs 参考

Formula:
Result:
Click an Example call below to populate and execute in the input above.

Expression functions

FunctionDefinitionExample callParametersExpected result
compileParse and compile an expression (no direct calculation).compile('2 + 3')expr (string){}
evaluateEvaluate an expression (and return the result).evaluate('2 + 3')expr (string), scope (object, optional)5
helpRetrieve brief usage info or examples.help('evaluate')search (string){ "name": "evaluate", "category": "Expression", "syntax": [ "evaluate(expression)", "evaluate(expression, scope)", "evaluate([expr1, expr2, expr3, ...])", "evaluate([expr1, expr2, expr3, ...], scope)" ], "description": "Evaluate an expression or an array with expressions.", "examples": [ "evaluate(\"2 + 3\")", "evaluate(\"sqrt(16)\")", "evaluate(\"2 inch to cm\")", "evaluate(\"sin(x * pi)\", { \"x\": 1/2 })", "evaluate([\"width=2\", \"height=4\",\"width*height\"])" ], "seealso": [], "mathjs": "Help" }
parserCreate a parser for custom operations.parser()None{}

Algebra functions

FunctionDefinitionExample callParametersExpected result
derivativeTake the derivative of an expression with respect to a given variable.derivative('x^2', 'x')expr (string|Node), variable (string){ "mathjs": "OperatorNode", "op": "*", "fn": "multiply", "args": [ { "mathjs": "ConstantNode", "value": 2 }, { "mathjs": "SymbolNode", "name": "x" } ], "implicit": false, "isPercentage": false }
leafCountCount the number of leaf nodes (symbols/constants) in the parse tree.leafCount('x^2 + y')expr (string|Node)3
lsolveFind one solution of a linear system by forward substitution.lsolve([[1,2],[3,4]], [5,6])L (Array|Matrix), b (Array|Matrix)[ [ 5 ], [ -2.25 ] ]
lsolveAllFind all solutions of a linear system by forward substitution.lsolveAll([[1,2],[3,4]], [5,6])L (Array|Matrix), b (Array|Matrix)[ [ [ 5 ], [ -2.25 ] ] ]
lupPerform LU decomposition of a matrix with partial pivoting.lup([[1,2],[3,4]])A (Array|Matrix){ "L": [ [ 1, 0 ], [ 0.3333333333333333, 1 ] ], "U": [ [ 3, 4 ], [ 0, 0.6666666666666667 ] ], "p": [ 1, 0 ] }
lusolveSolve linear equation A*x=b, where A is an [n x n] matrix.lusolve([[1,2],[3,4]], [5,6])A (Array|Matrix), b (Array|Matrix)[ [ -3.9999999999999987 ], [ 4.499999999999999 ] ]
lyapSolve the continuous-time Lyapunov equation AP+PA’+Q=0.lyap(A, Q)A (Array|Matrix), Q (Array|Matrix)Error: A is not defined
polynomialRootFind the numerical roots of a polynomial (real or complex).polynomialRoot(1, 2, 3, 4)constant (number), linearCoeff (number), ... up to cubicCoeff (optional)[ -0.605829586188268, { "mathjs": "Complex", "re": -0.07208520690586608, "im": -0.6383267351483765 }, { "mathjs": "Complex", "re": -0.07208520690586608, "im": 0.6383267351483765 } ]
qrPerform the Matrix QR decomposition.qr([[1,2],[3,4]])A (Array|Matrix){ "Q": [ [ 0.316227766016838, 0.9486832980505138 ], [ 0.9486832980505138, -0.316227766016838 ] ], "R": [ [ 3.162277660168379, 4.427188724235731 ], [ 0, 0.6324555320336751 ] ] }
rationalizeTransform a rationalizable expression into a rational fraction.rationalize('1/(x+1)')expr (string|Node){ "mathjs": "OperatorNode", "op": "/", "fn": "divide", "args": [ { "mathjs": "ConstantNode", "value": 1 }, { "mathjs": "OperatorNode", "op": "+", "fn": "add", "args": [ { "mathjs": "SymbolNode", "name": "x" }, { "mathjs": "ConstantNode", "value": 1 } ], "implicit": false, "isPercentage": false } ], "implicit": false, "isPercentage": false }
resolveReplace variable nodes with their values in the given scope.resolve('x + y', {x:2, y:3})expr (string|Node), scope (object){ "mathjs": "OperatorNode", "op": "+", "fn": "add", "args": [ { "mathjs": "ConstantNode", "value": 2 }, { "mathjs": "ConstantNode", "value": 3 } ], "implicit": false, "isPercentage": false }
schurCompute the real Schur decomposition A = U T U’ for a real matrix A.schur([[1,2],[3,4]])A (Array|Matrix){ "U": [ [ 0.41597355791928425, -0.9093767091321243 ], [ 0.9093767091321244, 0.41597355791928414 ] ], "T": [ [ 5.37228132326902, -1.0000000000000002 ], [ 5.147016547482756e-118, -0.37228132326901375 ] ] }
simplifySimplify an expression tree (combine like terms, etc.).simplify('2x + 3x')expr (string|Node){ "mathjs": "OperatorNode", "op": "*", "fn": "multiply", "args": [ { "mathjs": "ConstantNode", "value": 5 }, { "mathjs": "SymbolNode", "name": "x" } ], "implicit": false, "isPercentage": false }
simplifyConstantReplace constant subexpressions with their computed values.simplifyConstant('2+3')expr (string|Node){ "mathjs": "ConstantNode", "value": 5 }
simplifyCorePerform a single-pass simplification for performance-critical cases.simplifyCore('x+x')expr (string|Node){ "mathjs": "OperatorNode", "op": "+", "fn": "add", "args": [ { "mathjs": "SymbolNode", "name": "x" }, { "mathjs": "SymbolNode", "name": "x" } ], "implicit": false, "isPercentage": false }
sluCompute the sparse LU decomposition with full pivoting.slu([[1,2],[3,4]], 'natural', 1)A (Array|Matrix), order (string), threshold (number)Error: Unexpected type of argument in function slu (expected: SparseMatrix, actual: Array, index: 0)
sylvesterSolve the real-valued Sylvester equation AX + XB = C for X.sylvester(A, B, C)A (Array|Matrix), B (Array|Matrix), C (Array|Matrix)Error: A is not defined
symbolicEqualCheck if two expressions are symbolically equivalent.symbolicEqual('x+x', '2x')expr1 (string|Node), expr2 (string|Node)true
usolveFind one solution of a linear system by backward substitution.usolve([[1,2],[0,1]], [3,4])U (Array|Matrix), b (Array|Matrix)[ [ -5 ], [ 4 ] ]
usolveAllFind all solutions of a linear system by backward substitution.usolveAll([[1,2],[0,1]], [3,4])U (Array|Matrix), b (Array|Matrix)[ [ [ -5 ], [ 4 ] ] ]

Arithmetic functions

FunctionDefinitionExample callParametersExpected result
absCompute the absolute value of a number.abs(-3.2)x (number|Complex|Array|Matrix)3.2
addAdd two or more values (x + y).add(2, 3)x, y, ... (number|Array|Matrix)5
cbrtCalculate the cubic root of a value. Optionally compute all roots.cbrt(8)x (number|Complex), allRoots (boolean, optional)2
ceilRound a value towards plus infinity (also applies to complex).ceil(3.2)x (number|Complex|Array|Matrix)4
cubeCompute the cube of a value (x*x*x).cube(3)x (number|Complex|Array|Matrix)27
divideDivide two values (x / y).divide(6, 2)x (number|Array|Matrix), y (number|Array|Matrix)3
dotDivideDivide two matrices/arrays element wise.dotDivide([6,8],[2,4])x (Array|Matrix), y (Array|Matrix)[ 3, 2 ]
dotMultiplyMultiply two matrices/arrays element wise.dotMultiply([2,3],[4,5])x (Array|Matrix), y (Array|Matrix)[ 8, 15 ]
dotPowRaise x to the power of y element wise (x^y).dotPow([2,3],[2,3])x (Array|Matrix), y (Array|Matrix)[ 4, 27 ]
expCompute the exponential of a value.exp(1)x (number|Complex|Array|Matrix)2.718281828459045
expm1Compute (e^x - 1).expm1(1)x (number|Complex)1.718281828459045
fixRound a value towards zero.fix(3.7)x (number|Complex|Array|Matrix)3
floorRound a value towards minus infinity.floor(3.7)x (number|Complex|Array|Matrix)3
gcdCompute the greatest common divisor of two or more values.gcd(8, 12)a, b, ... (number|BigNumber)4
hypotCompute the square root of the sum of squares of provided values.hypot(3, 4)a, b, ... (number|BigNumber)5
invmodCompute the modular multiplicative inverse of a modulo b.invmod(3, 11)a, b (number|BigNumber)4
lcmCompute the least common multiple of two or more values.lcm(4, 6)a, b, ... (number|BigNumber)12
logCompute the logarithm of a value (custom base optional).log(100, 10)x (number|Complex), base (number|Complex, optional)2
log10Compute the 10-base logarithm of a value.log10(100)x (number|Complex)2
log1pCompute ln(1 + x).log1p(1)x (number|Complex)0.6931471805599453
log2Compute the base-2 logarithm of a value.log2(8)x (number|Complex)3
modCompute x mod y, the remainder of x / y.mod(8,3)x, y (number|BigNumber)2
multiplyMultiply two or more values (x * y).multiply(2, 3)x, y, ... (number|Array|Matrix)6
normCompute the norm of a number, vector, or matrix (p optional).norm([3,4])x (Array|Matrix), p (number|string, optional)5
nthRootCompute the nth root of a value (principal root).nthRoot(16, 4)a (number|BigNumber|Complex), root (number, optional)2
nthRootsCompute all nth roots of a value, including complex ones.nthRoots(1,3)x (number|Complex), root (number)[ { "mathjs": "Complex", "re": 1, "im": 0 }, { "mathjs": "Complex", "re": -0.4999999999999998, "im": 0.8660254037844387 }, { "mathjs": "Complex", "re": -0.5000000000000004, "im": -0.8660254037844384 } ]
powCompute x raised to the power of y (x^y).pow(2, 3)x (number|Complex|Array|Matrix), y (number|Complex|Array|Matrix)8
roundRound a value to the nearest value with optional decimals.round(3.14159, 2)x (number|Complex|Array|Matrix), n (number, optional)3.14
signCompute the sign of a value (-1, 0, +1).sign(-3)x (number|BigNumber|Complex)-1
sqrtCompute the square root of a value.sqrt(9)x (number|Complex|Array|Matrix)3
squareCompute the square of a value (x*x).square(3)x (number|Complex|Array|Matrix)9
subtractSubtract two values (x - y).subtract(8, 3)x, y (number|Array|Matrix)5
unaryMinusApply unary minus operation (negate the value).unaryMinus(3)x (number|Complex|Array|Matrix)-3
unaryPlusApply unary plus operation (usually no effect).unaryPlus(-3)x (number|Complex|Array|Matrix)-3
xgcdCompute the extended greatest common divisor of two values.xgcd(8, 12)a, b (number|BigNumber){ "mathjs": "DenseMatrix", "data": [ 4, -1, 1 ], "size": [ 3 ] }

Bitwise functions

FunctionDefinitionExample callParametersExpected result
bitAndApply bitwise AND to two values (x & y).bitAnd(5, 3)x, y (number|BigNumber)1
bitNotApply bitwise NOT to a value (~x).bitNot(5)x (number|BigNumber)-6
bitOrApply bitwise OR to two values (x | y).bitOr(5, 3)x, y (number|BigNumber)7
bitXorApply bitwise XOR to two values (x ^ y).bitXor(5, 3)x, y (number|BigNumber)6
leftShiftShift bits of x left by y (x << y).leftShift(5, 1)x, y (number|BigNumber)10
rightArithShiftArithmetic right shift bits of x by y (x >> y).rightArithShift(5, 1)x, y (number|BigNumber)2
rightLogShiftLogical right shift bits of x by y (x >>> y).rightLogShift(5, 1)x, y (number|BigNumber)2

Combinatorics functions

FunctionDefinitionExample callParametersExpected result
bellNumbersCount the ways to partition a set of n distinct elements.bellNumbers(3)n (number)5
catalanCompute the Catalan number for n, enumerating various combinatorial structures.catalan(5)n (number)42
compositionCompute the number of compositions of n into k parts.composition(5, 3)n, k (number)6
stirlingS2Count the ways to partition n labeled objects into k nonempty unlabeled subsets.stirlingS2(5, 3)n, k (number)25

Complex functions

FunctionDefinitionExample callParametersExpected result
argCompute the argument (angle) of a complex value.arg('2 + 2i')x (Complex|number)Error: Cannot convert "2 + 2i" to a number
conjCompute the complex conjugate of a complex value.conj('2 + 2i')x (Complex|number)Error: Cannot convert "2 + 2i" to a number
imGet the imaginary part of a complex number.im('2 + 3i')x (Complex|number)Error: Cannot convert "2 + 3i" to a number
reGet the real part of a complex number.re('2 + 3i')x (Complex|number)Error: Cannot convert "2 + 3i" to a number

Geometry functions

FunctionDefinitionExample callParametersExpected result
distanceCalculate the Euclidean distance between two points in N-D space.distance([0,0],[3,4])point1 (Array), point2 (Array)5
intersectFind the intersection of two lines (2D/3D) or a line and a plane (3D).intersect([0,0],[2,2],[0,2],[2,0])endPoint1Line1, endPoint2Line1, endPoint1Line2, endPoint2Line2, ...[ 1, 1 ]

Logical functions

FunctionDefinitionExample callParametersExpected result
andPerform a logical AND of two values.and(true, false)x, y (boolean|number)false
notPerform a logical NOT on a value.not(true)x (boolean|number)false
orPerform a logical OR of two values.or(true, false)x, y (boolean|number)true
xorPerform a logical exclusive OR.xor(1, 0)x, y (boolean|number)true

Matrix functions

FunctionDefinitionExample callParametersExpected result
applyApply a callback function over a matrix/array along a specified axis.apply([[1,2],[3,4]], 1, val => val * 2)A (Array|Matrix), dim (number), callback (function)[ null, null ]
columnReturn a specific column from a Matrix.column([[1,2],[3,4]], 0)value (Matrix|Array), index (number)[ [ 1 ], [ 3 ] ]
concatConcatenate multiple matrices/arrays along a specified dimension.concat([1,2], [3,4], [5,6])a, b, c, ... (Array|Matrix), dim (number, optional)[ 1, 2, 3, 4, 5, 6 ]
countCount elements in a matrix, array, or string.count([1,2,3,'hello'])x (Array|Matrix|String)4
crossCompute the cross product for two 3D vectors.cross([1,2,3], [4,5,6])x, y (Array|Matrix with length 3)[ -3, 6, -3 ]
ctransposeTranspose and complex conjugate a matrix.ctranspose([[1,2],[3,4]])x (Matrix|Array)[ [ 1, 3 ], [ 2, 4 ] ]
detCalculate the determinant of a matrix.det([[1,2],[3,4]])x (Matrix|Array)-2
diagCreate a diagonal matrix or retrieve the diagonal of a matrix.diag([1,2,3])X (Array|Matrix)[ [ 1, 0, 0 ], [ 0, 2, 0 ], [ 0, 0, 3 ] ]
diffCompute the difference between successive elements along a given dimension.diff([1,4,9,16])arr (Array|Matrix), dim (number, optional)[ 3, 5, 7 ]
dotCompute the dot product of two vectors.dot([1,2,3],[4,5,6])x, y (Array|Matrix)32
eigsCompute eigenvalues and optionally eigenvectors of a square matrix.eigs([[1,2],[3,4]])x (Matrix|Array), prec (number, optional){ "values": [ -0.37228132326901653, 5.372281323269014 ], "eigenvectors": [ { "value": -0.37228132326901653, "vector": [ -4.505883335311908, 3.091669772938812 ] }, { "value": 5.372281323269014, "vector": [ 0.4438641329939267, 0.9703494293791691 ] } ] }
expmCompute the matrix exponential e^A.expm([[1,0],[0,1]])x (Matrix|Array){ "mathjs": "DenseMatrix", "data": [ [ 2.7182818284590424, 0 ], [ 0, 2.7182818284590424 ] ], "size": [ 2, 2 ] }
fftCompute the N-dimensional Fast Fourier Transform.fft([1,2,3,4])arr (Array|Matrix)[ { "mathjs": "Complex", "re": 10, "im": 0 }, { "mathjs": "Complex", "re": -2, "im": 2 }, { "mathjs": "Complex", "re": -2, "im": 0 }, { "mathjs": "Complex", "re": -1.9999999999999998, "im": -2 } ]
filterFilter the items in an array or 1D matrix using a test function.filter([1,2,3,4,5], val => val > 2)x (Array|Matrix), test (function)[ 3, 4, 5 ]
flattenFlatten a multidimensional matrix into a single dimensional array.flatten([[1,2],[3,4]])x (Array|Matrix)[ 1, 2, 3, 4 ]
forEachIterate over elements of a matrix/array and execute a callback.forEach([1,2,3], val => console.log(val))x (Array|Matrix), callback (function)undefined
getMatrixDataTypeFind the data type of all elements in a matrix/array (e.g., 'number', 'Complex').getMatrixDataType([[1,2.2],[3,'hello']])x (Array|Matrix)mixed
identityCreate an identity matrix of size n x n (or m x n).identity(3)n (number) or [m, n] (Array){ "mathjs": "DenseMatrix", "data": [ [ 1, 0, 0 ], [ 0, 1, 0 ], [ 0, 0, 1 ] ], "size": [ 3, 3 ] }
ifftCompute the N-dimensional inverse Fast Fourier Transform.ifft([1,2,3,4])arr (Array|Matrix)[ { "mathjs": "Complex", "re": 2.5, "im": 0 }, { "mathjs": "Complex", "re": -0.5, "im": -0.5 }, { "mathjs": "Complex", "re": -0.5, "im": 0 }, { "mathjs": "Complex", "re": -0.49999999999999994, "im": 0.5 } ]
invCompute the inverse of a square matrix.inv([[1,2],[3,4]])x (Matrix|Array)[ [ -2, 1 ], [ 1.5, -0.5 ] ]
kronCompute the Kronecker product of two matrices or vectors.kron([[1,1],[0,1]], [[2,0],[0,2]])x, y (Matrix|Array)[ [ 2, 0, 2, 0 ], [ 0, 2, 0, 2 ], [ 0, 0, 2, 0 ], [ 0, 0, 0, 2 ] ]
mapCreate a new array/matrix by applying a callback function to each element.map([1,2,3], val => val * val)x (Array|Matrix), callback (function)[ 1, 4, 9 ]
matrixFromColumnsCreate a dense matrix from vectors as individual columns.matrixFromColumns([1,4],[2,5],[3,6])...arr (Array|Matrix)[ [ 1, 2, 3 ], [ 4, 5, 6 ] ]
matrixFromFunctionCreate a matrix by evaluating a function at each matrix index.matrixFromFunction([2,3], (i,j) => i + j)size (Array), fn (function)Error: Cannot convert "0,0undefined" to a number
matrixFromRowsCreate a dense matrix from vectors as individual rows.matrixFromRows([1,2,3],[4,5,6])...arr (Array|Matrix)[ [ 1, 2, 3 ], [ 4, 5, 6 ] ]
onesCreate a matrix of ones with given dimensions.ones(2, 3)m, n, p... (number){ "mathjs": "DenseMatrix", "data": [ [ 1, 1, 1 ], [ 1, 1, 1 ] ], "size": [ 2, 3 ] }
partitionSelectPartition-based selection of an array or 1D matrix (returns k-th smallest).partitionSelect([3,1,4,2], 2)x (Array|Matrix), k (number)3
pinvCompute the Moore–Penrose pseudoinverse of a matrix.pinv([[1,2],[2,4]])x (Matrix|Array)[ [ 0.04000000000000001, 0.08000000000000002 ], [ 0.08000000000000002, 0.16000000000000003 ] ]
rangeCreate an array of numbers from start to end (step optional).range(1, 5, 2)start (number), end (number), step (number, optional){ "mathjs": "DenseMatrix", "data": [ 1, 3 ], "size": [ 2 ] }
reshapeReshape an array/matrix to the specified dimensions.reshape([1,2,3,4,5,6], [2,3])x (Array|Matrix), sizes (Array)[ [ 1, 2, 3 ], [ 4, 5, 6 ] ]
resizeResize a matrix to new dimensions, filling missing elements with a default value if provided.resize([1,2,3], [5], 0)x (Array|Matrix), size (Array), defaultValue (any, optional)[ 1, 2, 3, 0, 0 ]
rotateRotate a 2D vector by an angle, or a 3D vector around an axis.rotate([1, 0], Math.PI / 2)w (Array|Matrix), theta (number[, axis])[ 6.123233995736766e-17, 1 ]
rotationMatrixCreate a 2D rotation matrix (2x2) for a given angle in radians.rotationMatrix(Math.PI / 2)theta (number){ "mathjs": "DenseMatrix", "data": [ [ 6.123233995736766e-17, -1 ], [ 1, 6.123233995736766e-17 ] ], "size": [ 2, 2 ] }
rowReturn a specific row from a Matrix.row([[1,2],[3,4]], 1)value (Matrix|Array), index (number)[ [ 3, 4 ] ]
sizeCompute the size (dimensions) of a matrix, array, or scalar.size([[1,2,3],[4,5,6]])x (Array|Matrix|number)[ 2, 3 ]
sortSort the items in a matrix or array in ascending order.sort([3,1,2])x (Array|Matrix)[ 1, 2, 3 ]
sqrtmCompute the principal square root of a square matrix.sqrtm([[4,0],[0,4]])A (Matrix|Array)[ [ 2.000000000000002, 0 ], [ 0, 2.000000000000002 ] ]
squeezeRemove inner and outer singleton dimensions from a matrix.squeeze([[[1],[2],[3]]])x (Matrix|Array)[ 1, 2, 3 ]
subsetRetrieve or replace a subset of a matrix or string.subset(['a','b','c'], 1)x (Matrix|Array|String), index (Index), replacement (optional)Error: Unexpected type of argument in function subset (expected: Index, actual: number, index: 1)
traceCompute the trace of a square matrix (sum of diagonal elements).trace([[1,2],[3,4]])x (Matrix|Array)5
transposeTranspose a matrix.transpose([[1,2],[3,4]])x (Matrix|Array)[ [ 1, 3 ], [ 2, 4 ] ]
zerosCreate a matrix filled with zeros of given dimensions.zeros(2, 3)m, n, p... (number){ "mathjs": "DenseMatrix", "data": [ [ 0, 0, 0 ], [ 0, 0, 0 ] ], "size": [ 2, 3 ] }

Numeric functions

FunctionDefinitionExample callParametersExpected result
solveODENumerical integration for ordinary differential equations (default method: RK45).solveODE((t, y) => -0.5 * y, [0, 10], [1])func (Function), tspan (Array), y0 (Array)Error: Unexpected type of argument in function map (expected: Array or Matrix, actual: number, index: 0)

Probability functions

FunctionDefinitionExample callParametersExpected result
combinationsCompute the binomial coefficient C(n, k).combinations(5, 2)n (number), k (number)10
combinationsWithRepCompute combinations where elements can repeat.combinationsWithRep(5, 2)n (number), k (number)15
factorialCompute factorial of an integer n.factorial(5)n (integer)120
gammaCompute the gamma function using approximations.gamma(5)n (number)24
kldivergenceCalculate the Kullback-Leibler divergence.kldivergence([0.1, 0.9], [0.2, 0.8])x (Array|Matrix), y (Array|Matrix)0.036690014034750584
lgammaCompute the log of gamma function (extended approximations).lgamma(5)n (number)3.178053830347945
multinomialCompute the multinomial coefficient for an array of counts.multinomial([1, 2, 3])a (Array)60
permutationsCompute permutations of n items taken k at a time.permutations(5, 2)n (number), k (number, optional)20
pickRandomRandomly pick value(s) from a 1D array.pickRandom([10, 20, 30])array (Array)20
randomGet a random number (uniform distribution).random(1, 10)min (number, optional), max (number, optional)3.6099423753668143
randomIntGet a random integer (uniform distribution).randomInt(1, 10)min (number, optional), max (number, optional)5

Relational functions

FunctionDefinitionExample callParametersExpected result
compareCompare two values (numerical or lexical).compare(2, 3)x, y (any)-1
compareNaturalCompare any two types in a consistent, natural way.compareNatural('2', '10')x, y (any)-1
compareTextLexically compare two strings.compareText('apple', 'banana')x (string), y (string)-1
deepEqualCheck if two matrices/arrays are element-wise equal.deepEqual([[1, 2]], [[1, 2]])x (Array|Matrix), y (Array|Matrix)true
equalCheck whether two values are equal.equal(2, 2)x, y (any)true
equalTextCheck equality of two strings.equalText('hello', 'hello')x (string), y (string)true
largerTest if x is strictly larger than y.larger(3, 2)x, y (number|BigNumber)true
largerEqTest if x is larger or equal to y.largerEq(3, 3)x, y (number|BigNumber)true
smallerTest if x is strictly smaller than y.smaller(2, 3)x, y (number|BigNumber)true
smallerEqTest if x is smaller or equal to y.smallerEq(2, 2)x, y (number|BigNumber)true
unequalTest whether two values are not equal.unequal(2, 3)x, y (any)true

Set functions

FunctionDefinitionExample callParametersExpected result
setCartesianCreate the cartesian product of two (multi)sets.setCartesian([1, 2], [3, 4])set1 (Array), set2 (Array)[ [ 1, 3 ], [ 1, 4 ], [ 2, 3 ], [ 2, 4 ] ]
setDifferenceCreate the difference of two (multi)sets (elements in set1 but not in set2).setDifference([1, 2, 3], [2])set1 (Array), set2 (Array)[ 1, 3 ]
setDistinctCollect unique elements of a (multi)set.setDistinct([1, 2, 2, 3])set (Array)[ 1, 2, 3 ]
setIntersectCreate the intersection of two (multi)sets.setIntersect([1, 2], [2, 3])set1 (Array), set2 (Array)[ 2 ]
setIsSubsetCheck if set1 is a subset of set2.setIsSubset([1, 2], [1, 2, 3])set1 (Array), set2 (Array)true
setMultiplicityCount how many times an element appears in a multiset.setMultiplicity(2, [1, 2, 2, 3])element (any), set (Array)2
setPowersetGenerate the powerset (all subsets) of a (multi)set.setPowerset([1, 2])set (Array)[ [], [ 1 ], [ 2 ], [ 1, 2 ] ]
setSizeCount the total number of elements in a (multi)set.setSize([1, 2, 3])set (Array)3
setSymDifferenceCreate the symmetric difference of two (multi)sets (elements in either set, but not both).setSymDifference([1, 2], [2, 3])set1 (Array), set2 (Array)[ 1, 3 ]
setUnionCreate the union of two (multi)sets.setUnion([1, 2], [2, 3])set1 (Array), set2 (Array)[ 1, 3, 2 ]

Signal functions

FunctionDefinitionExample callParametersExpected result
freqzCalculate the frequency response given filter coefficients.freqz([1, -0.5], [1])b (array), a (array){ "h": [ { "mathjs": "Complex", "re": 0.5, "im": 0 }, { "mathjs": "Complex", "re": 0.5000094123586994, "im": 0.0030679423245772376 }, { "mathjs": "Complex", "re": 0.5000376490804277, "im": 0.006135769142859963 }, { "mathjs": "Complex", "re": 0.5000847091020884, "im": 0.00920336495290241 }, { "mathjs": "Complex", "re": 0.5001505906518979, "im": 0.012270614261456144 }, { "mathjs": "Complex", "re": 0.5002352912494534, "im": 0.015337401588318313 }, { "mathjs": "Complex", "re": 0.5003388077058253, "im": 0.018403611470679416 }, { "mathjs": "Complex", "re": 0.5004611361236773, "im": 0.02146912846747041 }, { "mathjs": "Complex", "re": 0.5006022718974138, "im": 0.024533837163709007 }, { "mathjs": "Complex", "re": 0.5007622097133526, "im": 0.027597622174844967 }, { "mathjs": "Complex", "re": 0.5009409435499255, "im": 0.03066036815110429 }, { "mathjs": "Complex", "re": 0.5011384666779042, "im": 0.033721959781832025 }, { "mathjs": "Complex", "re": 0.5013547716606549, "im": 0.03678228179983371 }, { "mathjs": "Complex", "re": 0.5015898503544172, "im": 0.03984121898571506 }, { "mathjs": "Complex", "re": 0.501843693908611, "im": 0.04289865617221995 }, { "mathjs": "Complex", "re": 0.5021162927661701, "im": 0.04595447824856636 }, { "mathjs": "Complex", "re": 0.5024076366639015, "im": 0.0490085701647803 }, { "mathjs": "Complex", "re": 0.5027177146328723, "im": 0.05206081693602729 }, { "mathjs": "Complex", "re": 0.5030465149988219, "im": 0.05511110364694153 }, { "mathjs": "Complex", "re": 0.5033940253826028, "im": 0.058159315455952376 }, { "mathjs": "Complex", "re": 0.503760232700645, "im": 0.0612053375996081 }, { "mathjs": "Complex", "re": 0.5041451231654502, "im": 0.06424905539689658 }, { "mathjs": "Complex", "re": 0.50454868228611, "im": 0.06729035425356308 }, { "mathjs": "Complex", "re": 0.5049708948688514, "im": 0.0703291196664246 }, { "mathjs": "Complex", "re": 0.5054117450176094, "im": 0.07336523722768087 }, { "mathjs": "Complex", "re": 0.5058712161346253, "im": 0.07639859262922172 }, { "mathjs": "Complex", "re": 0.5063492909210707, "im": 0.07942907166693072 }, { "mathjs": "Complex", "re": 0.5068459513777006, "im": 0.08245656024498496 }, { "mathjs": "Complex", "re": 0.5073611788055294, "im": 0.08548094438015061 }, { "mathjs": "Complex", "re": 0.5078949538065355, "im": 0.08850211020607437 }, { "mathjs": "Complex", "re": 0.5084472562843918, "im": 0.09151994397757048 }, { "mathjs": "Complex", "re": 0.5090180654452223, "im": 0.0945343320749031 }, { "mathjs": "Complex", "re": 0.5096073597983848, "im": 0.09754516100806412 }, { "mathjs": "Complex", "re": 0.5102151171572797, "im": 0.10055231742104595 }, { "mathjs": "Complex", "re": 0.5108413146401862, "im": 0.10355568809610928 }, { "mathjs": "Complex", "re": 0.5114859286711229, "im": 0.10655515995804568 }, { "mathjs": "Complex", "re": 0.5121489349807358, "im": 0.1095506200784349 }, { "mathjs": "Complex", "re": 0.5128303086072121, "im": 0.11254195567989642 }, { "mathjs": "Complex", "re": 0.5135300238972199, "im": 0.11552905414033555 }, { "mathjs": "Complex", "re": 0.5142480545068742, "im": 0.1185118029971836 }, { "mathjs": "Complex", "re": 0.514984373402728, "im": 0.12149008995163194 }, { "mathjs": "Complex", "re": 0.5157389528627914, "im": 0.12446380287286007 }, { "mathjs": "Complex", "re": 0.516511764477574, "im": 0.12743282980225729 }, { "mathjs": "Complex", "re": 0.5173027791511553, "im": 0.13039705895763776 }, { "mathjs": "Complex", "re": 0.51811196710228, "im": 0.13335637873744918 }, { "mathjs": "Complex", "re": 0.5189392978654792, "im": 0.1363106777249745 }, { "mathjs": "Complex", "re": 0.5197847402922171, "im": 0.13925984469252653 }, { "mathjs": "Complex", "re": 0.5206482625520642, "im": 0.14220376860563594 }, { "mathjs": "Complex", "re": 0.5215298321338956, "im": 0.14514233862723117 }, { "mathjs": "Complex", "re": 0.5224294158471146, "im": 0.1480754441218119 }, { "mathjs": "Complex", "re": 0.5233469798229031, "im": 0.15100297465961404 }, { "mathjs": "Complex", "re": 0.5242824895154958, "im": 0.15392482002076743 }, { "mathjs": "Complex", "re": 0.5252359097034817, "im": 0.15684087019944576 }, { "mathjs": "Complex", "re": 0.5262072044911295, "im": 0.15975101540800785 }, { "mathjs": "Complex", "re": 0.5271963373097394, "im": 0.16265514608113146 }, { "mathjs": "Complex", "re": 0.5282032709190199, "im": 0.16555315287993821 }, { "mathjs": "Complex", "re": 0.5292279674084897, "im": 0.16844492669611003 }, { "mathjs": "Complex", "re": 0.530270388198905, "im": 0.1713303586559972 }, { "mathjs": "Complex", "re": 0.5313304940437125, "im": 0.17420934012471728 }, { "mathjs": "Complex", "re": 0.5324082450305262, "im": 0.17708176271024517 }, { "mathjs": "Complex", "re": 0.5335036005826306, "im": 0.17994751826749406 }, { "mathjs": "Complex", "re": 0.5346165194605081, "im": 0.18280649890238693 }, { "mathjs": "Complex", "re": 0.5357469597633921, "im": 0.18565859697591877 }, { "mathjs": "Complex", "re": 0.5368948789308443, "im": 0.18850370510820913 }, { "mathjs": "Complex", "re": 0.5380602337443566, "im": 0.1913417161825449 }, { "mathjs": "Complex", "re": 0.539242980328979, "im": 0.19417252334941312 }, { "mathjs": "Complex", "re": 0.5404430741549711, "im": 0.19699602003052405 }, { "mathjs": "Complex", "re": 0.5416604700394787, "im": 0.1998120999228234 }, { "mathjs": "Complex", "re": 0.5428951221482347, "im": 0.20262065700249493 }, { "mathjs": "Complex", "re": 0.544146983997285, "im": 0.20542158552895196 }, { "mathjs": "Complex", "re": 0.5454160084547388, "im": 0.20821478004881858 }, { "mathjs": "Complex", "re": 0.5467021477425423, "im": 0.21100013539989984 }, { "mathjs": "Complex", "re": 0.5480053534382783, "im": 0.21377754671514104 }, { "mathjs": "Complex", "re": 0.549325576476989, "im": 0.21654690942657598 }, { "mathjs": "Complex", "re": 0.5506627671530231, "im": 0.21930811926926383 }, { "mathjs": "Complex", "re": 0.5520168751219074, "im": 0.2220610722852146 }, { "mathjs": "Complex", "re": 0.5533878494022424, "im": 0.22480566482730327 }, { "mathjs": "Complex", "re": 0.554775638377621, "im": 0.22754179356317192 }, { "mathjs": "Complex", "re": 0.556180189798573, "im": 0.23026935547912 }, { "mathjs": "Complex", "re": 0.557601450784531, "im": 0.2329882478839831 }, { "mathjs": "Complex", "re": 0.5590393678258225, "im": 0.23569836841299882 }, { "mathjs": "Complex", "re": 0.5604938867856832, "im": 0.23839961503166104 }, { "mathjs": "Complex", "re": 0.5619649529022968, "im": 0.24109188603956136 }, { "mathjs": "Complex", "re": 0.563452510790855, "im": 0.243775080074218 }, { "mathjs": "Complex", "re": 0.5649565044456443, "im": 0.24644909611489202 }, { "mathjs": "Complex", "re": 0.5664768772421537, "im": 0.24911383348639093 }, { "mathjs": "Complex", "re": 0.5680135719392065, "im": 0.2517691918628588 }, { "mathjs": "Complex", "re": 0.5695665306811164, "im": 0.2544150712715535 }, { "mathjs": "Complex", "re": 0.5711356949998639, "im": 0.25705137209661083 }, { "mathjs": "Complex", "re": 0.5727210058172998, "im": 0.2596779950827948 }, { "mathjs": "Complex", "re": 0.5743224034473674, "im": 0.2622948413392345 }, { "mathjs": "Complex", "re": 0.5759398275983514, "im": 0.2649018123431473 }, { "mathjs": "Complex", "re": 0.5775732173751464, "im": 0.2674988099435486 }, { "mathjs": "Complex", "re": 0.5792225112815508, "im": 0.2700857363649464 }, { "mathjs": "Complex", "re": 0.580887647222581, "im": 0.27266249421102323 }, { "mathjs": "Complex", "re": 0.58256856250681, "im": 0.2752289864683024 }, { "mathjs": "Complex", "re": 0.5842651938487273, "im": 0.2777851165098011 }, { "mathjs": "Complex", "re": 0.5859774773711222, "im": 0.280330788098668 }, { "mathjs": "Complex", "re": 0.5877053486074874, "im": 0.28286590539180656 }, { "mathjs": "Complex", "re": 0.5894487425044477, "im": 0.28539037294348363 }, { "mathjs": "Complex", "re": 0.5912075934242081, "im": 0.28790409570892267 }, { "mathjs": "Complex", "re": 0.5929818351470257, "im": 0.29040697904788226 }, { "mathjs": "Complex", "re": 0.5947714008737026, "im": 0.29289892872821943 }, { "mathjs": "Complex", "re": 0.5965762232281003, "im": 0.2953798509294371 }, { "mathjs": "Complex", "re": 0.5983962342596776, "im": 0.2978496522462167 }, { "mathjs": "Complex", "re": 0.6002313654460475, "im": 0.3003082396919345 }, { "mathjs": "Complex", "re": 0.6020815476955582, "im": 0.3027555207021628 }, { "mathjs": "Complex", "re": 0.6039467113498938, "im": 0.30519140313815474 }, { "mathjs": "Complex", "re": 0.6058267861866968, "im": 0.3076157952903134 }, { "mathjs": "Complex", "re": 0.6077217014222124, "im": 0.31002860588164455 }, { "mathjs": "Complex", "re": 0.6096313857139528, "im": 0.31242974407119317 }, { "mathjs": "Complex", "re": 0.6115557671633838, "im": 0.3148191194574635 }, { "mathjs": "Complex", "re": 0.6134947733186316, "im": 0.31719664208182274 }, { "mathjs": "Complex", "re": 0.6154483311772101, "im": 0.31956222243188787 }, { "mathjs": "Complex", "re": 0.6174163671887705, "im": 0.3219157714448957 }, { "mathjs": "Complex", "re": 0.6193988072578691, "im": 0.3242572005110562 }, { "mathjs": "Complex", "re": 0.6213955767467577, "im": 0.3265864214768884 }, { "mathjs": "Complex", "re": 0.6234066004781937, "im": 0.3289033466485393 }, { "mathjs": "Complex", "re": 0.6254318027382704, "im": 0.3312078887950859 }, { "mathjs": "Complex", "re": 0.6274711072792669, "im": 0.33349996115181874 }, { "mathjs": "Complex", "re": 0.6295244373225204, "im": 0.33577947742350917 }, { "mathjs": "Complex", "re": 0.6315917155613151, "im": 0.33804635178765796 }, { "mathjs": "Complex", "re": 0.6336728641637936, "im": 0.3403004988977265 }, { "mathjs": "Complex", "re": 0.6357678047758875, "im": 0.3425418338863502 }, { "mathjs": "Complex", "re": 0.6378764585242664, "im": 0.3447702723685334 }, { "mathjs": "Complex", "re": 0.6399987460193092, "im": 0.346985730444827 }, { "mathjs": "Complex", "re": 0.6421345873580907, "im": 0.34918812470448646 }, { "mathjs": "Complex", "re": 0.6442839021273918, "im": 0.35137737222861265 }, { "mathjs": "Complex", "re": 0.6464466094067263, "im": 0.35355339059327373 }, { "mathjs": "Complex", "re": 0.6486226277713874, "im": 0.3557160978726082 }, { "mathjs": "Complex", "re": 0.6508118752955135, "im": 0.3578654126419093 }, { "mathjs": "Complex", "re": 0.653014269555173, "im": 0.3600012539806908 }, { "mathjs": "Complex", "re": 0.6552297276314665, "im": 0.36212354147573345 }, { "mathjs": "Complex", "re": 0.6574581661136498, "im": 0.3642321952241126 }, { "mathjs": "Complex", "re": 0.6596995011022735, "im": 0.3663271358362064 }, { "mathjs": "Complex", "re": 0.661953648212342, "im": 0.3684082844386849 }, { "mathjs": "Complex", "re": 0.6642205225764908, "im": 0.37047556267747955 }, { "mathjs": "Complex", "re": 0.6665000388481812, "im": 0.372528892720733 }, { "mathjs": "Complex", "re": 0.6687921112049141, "im": 0.37456819726172963 }, { "mathjs": "Complex", "re": 0.6710966533514606, "im": 0.3765933995218062 }, { "mathjs": "Complex", "re": 0.6734135785231117, "im": 0.37860442325324223 }, { "mathjs": "Complex", "re": 0.6757427994889438, "im": 0.3806011927421309 }, { "mathjs": "Complex", "re": 0.6780842285551043, "im": 0.3825836328112295 }, { "mathjs": "Complex", "re": 0.6804377775681121, "im": 0.3845516688227898 }, { "mathjs": "Complex", "re": 0.6828033579181773, "im": 0.3865052266813685 }, { "mathjs": "Complex", "re": 0.6851808805425365, "im": 0.3884442328366162 }, { "mathjs": "Complex", "re": 0.6875702559288068, "im": 0.3903686142860472 }, { "mathjs": "Complex", "re": 0.6899713941183554, "im": 0.3922782985777876 }, { "mathjs": "Complex", "re": 0.6923842047096866, "im": 0.3941732138133031 }, { "mathjs": "Complex", "re": 0.6948085968618453, "im": 0.3960532886501062 }, { "mathjs": "Complex", "re": 0.6972444792978372, "im": 0.3979184523044417 }, { "mathjs": "Complex", "re": 0.6996917603080655, "im": 0.3997686345539525 }, { "mathjs": "Complex", "re": 0.7021503477537833, "im": 0.4016037657403224 }, { "mathjs": "Complex", "re": 0.7046201490705628, "im": 0.4034237767718996 }, { "mathjs": "Complex", "re": 0.7071010712717806, "im": 0.4052285991262974 }, { "mathjs": "Complex", "re": 0.7095930209521177, "im": 0.40701816485297415 }, { "mathjs": "Complex", "re": 0.7120959042910773, "im": 0.40879240657579186 }, { "mathjs": "Complex", "re": 0.7146096270565163, "im": 0.4105512574955523 }, { "mathjs": "Complex", "re": 0.7171340946081934, "im": 0.41229465139251265 }, { "mathjs": "Complex", "re": 0.7196692119013319, "im": 0.4140225226288779 }, { "mathjs": "Complex", "re": 0.7222148834901989, "im": 0.4157348061512726 }, { "mathjs": "Complex", "re": 0.7247710135316976, "im": 0.41743143749319 }, { "mathjs": "Complex", "re": 0.7273375057889768, "im": 0.419112352777419 }, { "mathjs": "Complex", "re": 0.7299142636350535, "im": 0.42077748871844917 }, { "mathjs": "Complex", "re": 0.7325011900564513, "im": 0.4224267826248535 }, { "mathjs": "Complex", "re": 0.7350981876568525, "im": 0.42406017240164856 }, { "mathjs": "Complex", "re": 0.7377051586607656, "im": 0.4256775965526326 }, { "mathjs": "Complex", "re": 0.7403220049172052, "im": 0.42727899418270027 }, { "mathjs": "Complex", "re": 0.7429486279033892, "im": 0.42886430500013606 }, { "mathjs": "Complex", "re": 0.7455849287284465, "im": 0.43043346931888365 }, { "mathjs": "Complex", "re": 0.7482308081371412, "im": 0.43198642806079335 }, { "mathjs": "Complex", "re": 0.7508861665136091, "im": 0.4335231227578463 }, { "mathjs": "Complex", "re": 0.7535509038851079, "im": 0.4350434955543557 }, { "mathjs": "Complex", "re": 0.756224919925782, "im": 0.43654748920914505 }, { "mathjs": "Complex", "re": 0.7589081139604386, "im": 0.4380350470977033 }, { "mathjs": "Complex", "re": 0.7616003849683388, "im": 0.4395061132143167 }, { "mathjs": "Complex", "re": 0.764301631587001, "im": 0.44096063217417747 }, { "mathjs": "Complex", "re": 0.7670117521160169, "im": 0.4423985492154689 }, { "mathjs": "Complex", "re": 0.76973064452088, "im": 0.44381981020142697 }, { "mathjs": "Complex", "re": 0.772458206436828, "im": 0.44522436162237894 }, { "mathjs": "Complex", "re": 0.7751943351726966, "im": 0.44661215059775766 }, { "mathjs": "Complex", "re": 0.7779389277147853, "im": 0.44798312487809255 }, { "mathjs": "Complex", "re": 0.7806918807307361, "im": 0.4493372328469769 }, { "mathjs": "Complex", "re": 0.783453090573424, "im": 0.450674423523011 }, { "mathjs": "Complex", "re": 0.786222453284859, "im": 0.45199464656172167 }, { "mathjs": "Complex", "re": 0.7889998646001001, "im": 0.45329785225745767 }, { "mathjs": "Complex", "re": 0.7917852199511813, "im": 0.45458399154526113 }, { "mathjs": "Complex", "re": 0.794578414471048, "im": 0.45585301600271494 }, { "mathjs": "Complex", "re": 0.7973793429975051, "im": 0.45710487785176535 }, { "mathjs": "Complex", "re": 0.8001879000771766, "im": 0.45833952996052135 }, { "mathjs": "Complex", "re": 0.8030039799694759, "im": 0.4595569258450289 }, { "mathjs": "Complex", "re": 0.8058274766505868, "im": 0.46075701967102095 }, { "mathjs": "Complex", "re": 0.8086582838174551, "im": 0.46193976625564337 }, { "mathjs": "Complex", "re": 0.8114962948917909, "im": 0.46310512106915563 }, { "mathjs": "Complex", "re": 0.8143414030240812, "im": 0.46425304023660774 }, { "mathjs": "Complex", "re": 0.817193501097613, "im": 0.46538348053949186 }, { "mathjs": "Complex", "re": 0.8200524817325059, "im": 0.4664963994173694 }, { "mathjs": "Complex", "re": 0.8229182372897548, "im": 0.46759175496947375 }, { "mathjs": "Complex", "re": 0.8257906598752828, "im": 0.4686695059562875 }, { "mathjs": "Complex", "re": 0.8286696413440028, "im": 0.46972961180109496 }, { "mathjs": "Complex", "re": 0.83155507330389, "im": 0.4707720325915104 }, { "mathjs": "Complex", "re": 0.8344468471200618, "im": 0.4717967290809802 }, { "mathjs": "Complex", "re": 0.8373448539188685, "im": 0.47280366269026064 }, { "mathjs": "Complex", "re": 0.8402489845919922, "im": 0.47379279550887055 }, { "mathjs": "Complex", "re": 0.8431591298005542, "im": 0.47476409029651834 }, { "mathjs": "Complex", "re": 0.8460751799792325, "im": 0.47571751048450417 }, { "mathjs": "Complex", "re": 0.8489970253403859, "im": 0.4766530201770969 }, { "mathjs": "Complex", "re": 0.851924555878188, "im": 0.47757058415288534 }, { "mathjs": "Complex", "re": 0.8548576613727689, "im": 0.47847016786610447 }, { "mathjs": "Complex", "re": 0.8577962313943641, "im": 0.4793517374479358 }, { "mathjs": "Complex", "re": 0.8607401553074735, "im": 0.4802152597077829 }, { "mathjs": "Complex", "re": 0.8636893222750255, "im": 0.4810607021345208 }, { "mathjs": "Complex", "re": 0.8666436212625508, "im": 0.4818880328977199 }, { "mathjs": "Complex", "re": 0.8696029410423622, "im": 0.4826972208488447 }, { "mathjs": "Complex", "re": 0.8725671701977427, "im": 0.48348823552242604 }, { "mathjs": "Complex", "re": 0.8755361971271398, "im": 0.48426104713720863 }, { "mathjs": "Complex", "re": 0.878509910048368, "im": 0.485015626597272 }, { "mathjs": "Complex", "re": 0.8814881970028163, "im": 0.4857519454931259 }, { "mathjs": "Complex", "re": 0.8844709458596643, "im": 0.48646997610278003 }, { "mathjs": "Complex", "re": 0.8874580443201037, "im": 0.48716969139278793 }, { "mathjs": "Complex", "re": 0.8904493799215651, "im": 0.4878510650192643 }, { "mathjs": "Complex", "re": 0.8934448400419543, "im": 0.4885140713288772 }, { "mathjs": "Complex", "re": 0.8964443119038907, "im": 0.4891586853598138 }, { "mathjs": "Complex", "re": 0.899447682578954, "im": 0.48978488284272026 }, { "mathjs": "Complex", "re": 0.9024548389919358, "im": 0.4903926402016152 }, { "mathjs": "Complex", "re": 0.9054656679250969, "im": 0.4909819345547776 }, { "mathjs": "Complex", "re": 0.9084800560224294, "im": 0.49155274371560814 }, { "mathjs": "Complex", "re": 0.9114978897939255, "im": 0.4921050461934645 }, { "mathjs": "Complex", "re": 0.9145190556198494, "im": 0.4926388211944706 }, { "mathjs": "Complex", "re": 0.917543439755015, "im": 0.49315404862229933 }, { "mathjs": "Complex", "re": 0.9205709283330693, "im": 0.4936507090789292 }, { "mathjs": "Complex", "re": 0.9236014073707783, "im": 0.49412878386537473 }, { "mathjs": "Complex", "re": 0.9266347627723192, "im": 0.4945882549823905 }, { "mathjs": "Complex", "re": 0.9296708803335754, "im": 0.49502910513114856 }, { "mathjs": "Complex", "re": 0.9327096457464369, "im": 0.49545131771389 }, { "mathjs": "Complex", "re": 0.9357509446031034, "im": 0.49585487683454976 }, { "mathjs": "Complex", "re": 0.9387946624003919, "im": 0.496239767299355 }, { "mathjs": "Complex", "re": 0.9418406845440476, "im": 0.49660597461739725 }, { "mathjs": "Complex", "re": 0.9448888963530584, "im": 0.49695348500117803 }, { "mathjs": "Complex", "re": 0.9479391830639726, "im": 0.4972822853671277 }, { "mathjs": "Complex", "re": 0.9509914298352196, "im": 0.4975923633360984 }, { "mathjs": "Complex", "re": 0.9540455217514336, "im": 0.4978837072338299 }, { "mathjs": "Complex", "re": 0.95710134382778, "im": 0.498156306091389 }, { "mathjs": "Complex", "re": 0.960158781014285, "im": 0.49841014964558283 }, { "mathjs": "Complex", "re": 0.9632177182001662, "im": 0.4986452283393451 }, { "mathjs": "Complex", "re": 0.966278040218168, "im": 0.4988615333220958 }, { "mathjs": "Complex", "re": 0.9693396318488957, "im": 0.4990590564500746 }, { "mathjs": "Complex", "re": 0.9724023778251549, "im": 0.4992377902866474 }, { "mathjs": "Complex", "re": 0.975466162836291, "im": 0.4993977281025862 }, { "mathjs": "Complex", "re": 0.9785308715325295, "im": 0.4995388638763227 }, { "mathjs": "Complex", "re": 0.9815963885293205, "im": 0.49966119229417477 }, { "mathjs": "Complex", "re": 0.9846625984116817, "im": 0.49976470875054657 }, { "mathjs": "Complex", "re": 0.9877293857385439, "im": 0.4998494093481021 }, { "mathjs": "Complex", "re": 0.9907966350470976, "im": 0.4999152908979117 }, { "mathjs": "Complex", "re": 0.99386423085714, "im": 0.49996235091957225 }, { "mathjs": "Complex", "re": 0.9969320576754227, "im": 0.49999058764130055 }, { "mathjs": "Complex", "re": 1, "im": 0.5 }, { "mathjs": "Complex", "re": 1.0030679423245772, "im": 0.49999058764130055 }, { "mathjs": "Complex", "re": 1.0061357691428598, "im": 0.49996235091957225 }, { "mathjs": "Complex", "re": 1.0092033649529024, "im": 0.4999152908979117 }, { "mathjs": "Complex", "re": 1.0122706142614561, "im": 0.4998494093481021 }, { "mathjs": "Complex", "re": 1.0153374015883183, "im": 0.49976470875054657 }, { "mathjs": "Complex", "re": 1.0184036114706794, "im": 0.49966119229417477 }, { "mathjs": "Complex", "re": 1.0214691284674704, "im": 0.4995388638763227 }, { "mathjs": "Complex", "re": 1.024533837163709, "im": 0.4993977281025862 }, { "mathjs": "Complex", "re": 1.0275976221748448, "im": 0.4992377902866474 }, { "mathjs": "Complex", "re": 1.0306603681511042, "im": 0.4990590564500746 }, { "mathjs": "Complex", "re": 1.033721959781832, "im": 0.4988615333220958 }, { "mathjs": "Complex", "re": 1.0367822817998336, "im": 0.4986452283393451 }, { "mathjs": "Complex", "re": 1.039841218985715, "im": 0.4984101496455829 }, { "mathjs": "Complex", "re": 1.0428986561722198, "im": 0.498156306091389 }, { "mathjs": "Complex", "re": 1.0459544782485664, "im": 0.4978837072338299 }, { "mathjs": "Complex", "re": 1.0490085701647802, "im": 0.49759236333609846 }, { "mathjs": "Complex", "re": 1.0520608169360273, "im": 0.4972822853671277 }, { "mathjs": "Complex", "re": 1.0551111036469416, "im": 0.49695348500117803 }, { "mathjs": "Complex", "re": 1.0581593154559523, "im": 0.49660597461739725 }, { "mathjs": "Complex", "re": 1.061205337599608, "im": 0.496239767299355 }, { "mathjs": "Complex", "re": 1.0642490553968966, "im": 0.49585487683454976 }, { "mathjs": "Complex", "re": 1.067290354253563, "im": 0.49545131771389 }, { "mathjs": "Complex", "re": 1.0703291196664246, "im": 0.49502910513114856 }, { "mathjs": "Complex", "re": 1.0733652372276807, "im": 0.4945882549823905 }, { "mathjs": "Complex", "re": 1.0763985926292217, "im": 0.49412878386537473 }, { "mathjs": "Complex", "re": 1.0794290716669306, "im": 0.4936507090789292 }, { "mathjs": "Complex", "re": 1.082456560244985, "im": 0.49315404862229933 }, { "mathjs": "Complex", "re": 1.0854809443801505, "im": 0.4926388211944706 }, { "mathjs": "Complex", "re": 1.0885021102060743, "im": 0.4921050461934645 }, { "mathjs": "Complex", "re": 1.0915199439775705, "im": 0.49155274371560814 }, { "mathjs": "Complex", "re": 1.094534332074903, "im": 0.4909819345547776 }, { "mathjs": "Complex", "re": 1.097545161008064, "im": 0.4903926402016152 }, { "mathjs": "Complex", "re": 1.1005523174210459, "im": 0.48978488284272026 }, { "mathjs": "Complex", "re": 1.1035556880961093, "im": 0.4891586853598138 }, { "mathjs": "Complex", "re": 1.1065551599580457, "im": 0.4885140713288772 }, { "mathjs": "Complex", "re": 1.1095506200784349, "im": 0.4878510650192643 }, { "mathjs": "Complex", "re": 1.1125419556798963, "im": 0.48716969139278793 }, { "mathjs": "Complex", "re": 1.1155290541403355, "im": 0.4864699761027801 }, { "mathjs": "Complex", "re": 1.1185118029971837, "im": 0.4857519454931259 }, { "mathjs": "Complex", "re": 1.121490089951632, "im": 0.485015626597272 }, { "mathjs": "Complex", "re": 1.12446380287286, "im": 0.4842610471372087 }, { "mathjs": "Complex", "re": 1.1274328298022573, "im": 0.48348823552242604 }, { "mathjs": "Complex", "re": 1.1303970589576378, "im": 0.4826972208488447 }, { "mathjs": "Complex", "re": 1.1333563787374492, "im": 0.4818880328977199 }, { "mathjs": "Complex", "re": 1.1363106777249745, "im": 0.4810607021345208 }, { "mathjs": "Complex", "re": 1.1392598446925264, "im": 0.48021525970778295 }, { "mathjs": "Complex", "re": 1.1422037686056359, "im": 0.4793517374479358 }, { "mathjs": "Complex", "re": 1.145142338627231, "im": 0.47847016786610447 }, { "mathjs": "Complex", "re": 1.148075444121812, "im": 0.47757058415288534 }, { "mathjs": "Complex", "re": 1.151002974659614, "im": 0.47665302017709693 }, { "mathjs": "Complex", "re": 1.1539248200207675, "im": 0.47571751048450417 }, { "mathjs": "Complex", "re": 1.1568408701994457, "im": 0.47476409029651834 }, { "mathjs": "Complex", "re": 1.1597510154080077, "im": 0.4737927955088706 }, { "mathjs": "Complex", "re": 1.1626551460811314, "im": 0.4728036626902607 }, { "mathjs": "Complex", "re": 1.165553152879938, "im": 0.4717967290809802 }, { "mathjs": "Complex", "re": 1.1684449266961099, "im": 0.4707720325915104 }, { "mathjs": "Complex", "re": 1.171330358655997, "im": 0.46972961180109496 }, { "mathjs": "Complex", "re": 1.1742093401247171, "im": 0.4686695059562875 }, { "mathjs": "Complex", "re": 1.1770817627102452, "im": 0.4675917549694738 }, { "mathjs": "Complex", "re": 1.179947518267494, "im": 0.4664963994173694 }, { "mathjs": "Complex", "re": 1.182806498902387, "im": 0.46538348053949186 }, { "mathjs": "Complex", "re": 1.1856585969759188, "im": 0.4642530402366078 }, { "mathjs": "Complex", "re": 1.188503705108209, "im": 0.4631051210691557 }, { "mathjs": "Complex", "re": 1.1913417161825448, "im": 0.46193976625564337 }, { "mathjs": "Complex", "re": 1.1941725233494132, "im": 0.460757019671021 }, { "mathjs": "Complex", "re": 1.196996020030524, "im": 0.4595569258450289 }, { "mathjs": "Complex", "re": 1.1998120999228234, "im": 0.45833952996052135 }, { "mathjs": "Complex", "re": 1.2026206570024949, "im": 0.45710487785176535 }, { "mathjs": "Complex", "re": 1.2054215855289518, "im": 0.45585301600271494 }, { "mathjs": "Complex", "re": 1.2082147800488185, "im": 0.45458399154526125 }, { "mathjs": "Complex", "re": 1.2110001353998998, "im": 0.45329785225745767 }, { "mathjs": "Complex", "re": 1.213777546715141, "im": 0.4519946465617217 }, { "mathjs": "Complex", "re": 1.216546909426576, "im": 0.450674423523011 }, { "mathjs": "Complex", "re": 1.2193081192692636, "im": 0.44933723284697696 }, { "mathjs": "Complex", "re": 1.2220610722852145, "im": 0.4479831248780926 }, { "mathjs": "Complex", "re": 1.2248056648273034, "im": 0.4466121505977576 }, { "mathjs": "Complex", "re": 1.2275417935631718, "im": 0.445224361622379 }, { "mathjs": "Complex", "re": 1.23026935547912, "im": 0.44381981020142697 }, { "mathjs": "Complex", "re": 1.232988247883983, "im": 0.44239854921546895 }, { "mathjs": "Complex", "re": 1.235698368412999, "im": 0.4409606321741775 }, { "mathjs": "Complex", "re": 1.238399615031661, "im": 0.43950611321431676 }, { "mathjs": "Complex", "re": 1.2410918860395614, "im": 0.4380350470977033 }, { "mathjs": "Complex", "re": 1.2437750800742178, "im": 0.4365474892091451 }, { "mathjs": "Complex", "re": 1.246449096114892, "im": 0.43504349555435573 }, { "mathjs": "Complex", "re": 1.2491138334863907, "im": 0.4335231227578464 }, { "mathjs": "Complex", "re": 1.2517691918628588, "im": 0.4319864280607934 }, { "mathjs": "Complex", "re": 1.2544150712715536, "im": 0.4304334693188836 }, { "mathjs": "Complex", "re": 1.2570513720966108, "im": 0.42886430500013606 }, { "mathjs": "Complex", "re": 1.2596779950827948, "im": 0.42727899418270027 }, { "mathjs": "Complex", "re": 1.2622948413392343, "im": 0.4256775965526326 }, { "mathjs": "Complex", "re": 1.2649018123431475, "im": 0.4240601724016486 }, { "mathjs": "Complex", "re": 1.2674988099435485, "im": 0.4224267826248536 }, { "mathjs": "Complex", "re": 1.2700857363649465, "im": 0.4207774887184492 }, { "mathjs": "Complex", "re": 1.2726624942110232, "im": 0.4191123527774191 }, { "mathjs": "Complex", "re": 1.2752289864683024, "im": 0.41743143749319006 }, { "mathjs": "Complex", "re": 1.277785116509801, "im": 0.41573480615127273 }, { "mathjs": "Complex", "re": 1.2803307880986678, "im": 0.4140225226288779 }, { "mathjs": "Complex", "re": 1.2828659053918066, "im": 0.4122946513925126 }, { "mathjs": "Complex", "re": 1.2853903729434837, "im": 0.4105512574955524 }, { "mathjs": "Complex", "re": 1.2879040957089227, "im": 0.40879240657579186 }, { "mathjs": "Complex", "re": 1.2904069790478823, "im": 0.40701816485297426 }, { "mathjs": "Complex", "re": 1.2928989287282193, "im": 0.4052285991262974 }, { "mathjs": "Complex", "re": 1.295379850929437, "im": 0.4034237767718997 }, { "mathjs": "Complex", "re": 1.2978496522462166, "im": 0.40160376574032247 }, { "mathjs": "Complex", "re": 1.3003082396919343, "im": 0.3997686345539526 }, { "mathjs": "Complex", "re": 1.3027555207021626, "im": 0.3979184523044418 }, { "mathjs": "Complex", "re": 1.3051914031381548, "im": 0.39605328865010614 }, { "mathjs": "Complex", "re": 1.3076157952903134, "im": 0.39417321381330317 }, { "mathjs": "Complex", "re": 1.3100286058816446, "im": 0.39227829857778757 }, { "mathjs": "Complex", "re": 1.3124297440711932, "im": 0.3903686142860473 }, { "mathjs": "Complex", "re": 1.3148191194574634, "im": 0.3884442328366162 }, { "mathjs": "Complex", "re": 1.3171966420818226, "im": 0.38650522668136855 }, { "mathjs": "Complex", "re": 1.319562222431888, "im": 0.3845516688227898 }, { "mathjs": "Complex", "re": 1.3219157714448957, "im": 0.38258363281122953 }, { "mathjs": "Complex", "re": 1.3242572005110562, "im": 0.38060119274213094 }, { "mathjs": "Complex", "re": 1.3265864214768883, "im": 0.37860442325324234 }, { "mathjs": "Complex", "re": 1.3289033466485394, "im": 0.37659339952180626 }, { "mathjs": "Complex", "re": 1.331207888795086, "im": 0.37456819726172963 }, { "mathjs": "Complex", "re": 1.3334999611518188, "im": 0.37252889272073303 }, { "mathjs": "Complex", "re": 1.3357794774235092, "im": 0.3704755626774795 }, { "mathjs": "Complex", "re": 1.338046351787658, "im": 0.368408284438685 }, { "mathjs": "Complex", "re": 1.3403004988977265, "im": 0.3663271358362064 }, { "mathjs": "Complex", "re": 1.3425418338863502, "im": 0.36423219522411265 }, { "mathjs": "Complex", "re": 1.3447702723685335, "im": 0.36212354147573345 }, { "mathjs": "Complex", "re": 1.346985730444827, "im": 0.3600012539806909 }, { "mathjs": "Complex", "re": 1.3491881247044863, "im": 0.35786541264190935 }, { "mathjs": "Complex", "re": 1.3513773722286126, "im": 0.35571609787260833 }, { "mathjs": "Complex", "re": 1.3535533905932737, "im": 0.3535533905932738 }, { "mathjs": "Complex", "re": 1.3557160978726084, "im": 0.3513773722286126 }, { "mathjs": "Complex", "re": 1.3578654126419094, "im": 0.34918812470448646 }, { "mathjs": "Complex", "re": 1.3600012539806907, "im": 0.346985730444827 }, { "mathjs": "Complex", "re": 1.3621235414757333, "im": 0.3447702723685335 }, { "mathjs": "Complex", "re": 1.3642321952241125, "im": 0.3425418338863502 }, { "mathjs": "Complex", "re": 1.3663271358362064, "im": 0.3403004988977266 }, { "mathjs": "Complex", "re": 1.368408284438685, "im": 0.33804635178765796 }, { "mathjs": "Complex", "re": 1.3704755626774794, "im": 0.3357794774235093 }, { "mathjs": "Complex", "re": 1.3725288927207329, "im": 0.3334999611518188 }, { "mathjs": "Complex", "re": 1.3745681972617296, "im": 0.331207888795086 }, { "mathjs": "Complex", "re": 1.3765933995218063, "im": 0.3289033466485394 }, { "mathjs": "Complex", "re": 1.3786044232532424, "im": 0.3265864214768883 }, { "mathjs": "Complex", "re": 1.380601192742131, "im": 0.3242572005110563 }, { "mathjs": "Complex", "re": 1.3825836328112295, "im": 0.3219157714448957 }, { "mathjs": "Complex", "re": 1.3845516688227897, "im": 0.3195622224318879 }, { "mathjs": "Complex", "re": 1.3865052266813684, "im": 0.31719664208182274 }, { "mathjs": "Complex", "re": 1.3884442328366162, "im": 0.3148191194574636 }, { "mathjs": "Complex", "re": 1.3903686142860472, "im": 0.31242974407119317 }, { "mathjs": "Complex", "re": 1.3922782985777875, "im": 0.3100286058816447 }, { "mathjs": "Complex", "re": 1.3941732138133032, "im": 0.30761579529031347 }, { "mathjs": "Complex", "re": 1.396053288650106, "im": 0.30519140313815485 }, { "mathjs": "Complex", "re": 1.3979184523044417, "im": 0.30275552070216283 }, { "mathjs": "Complex", "re": 1.3997686345539526, "im": 0.30030823969193443 }, { "mathjs": "Complex", "re": 1.4016037657403224, "im": 0.29784965224621673 }, { "mathjs": "Complex", "re": 1.4034237767718998, "im": 0.2953798509294371 }, { "mathjs": "Complex", "re": 1.4052285991262974, "im": 0.2928989287282195 }, { "mathjs": "Complex", "re": 1.4070181648529743, "im": 0.29040697904788226 }, { "mathjs": "Complex", "re": 1.4087924065757917, "im": 0.2879040957089227 }, { "mathjs": "Complex", "re": 1.4105512574955523, "im": 0.28539037294348363 }, { "mathjs": "Complex", "re": 1.4122946513925125, "im": 0.2828659053918067 }, { "mathjs": "Complex", "re": 1.4140225226288778, "im": 0.28033078809866807 }, { "mathjs": "Complex", "re": 1.4157348061512727, "im": 0.2777851165098011 }, { "mathjs": "Complex", "re": 1.41743143749319, "im": 0.27522898646830246 }, { "mathjs": "Complex", "re": 1.419112352777419, "im": 0.2726624942110232 }, { "mathjs": "Complex", "re": 1.4207774887184492, "im": 0.2700857363649465 }, { "mathjs": "Complex", "re": 1.4224267826248536, "im": 0.2674988099435486 }, { "mathjs": "Complex", "re": 1.4240601724016486, "im": 0.2649018123431474 }, { "mathjs": "Complex", "re": 1.4256775965526325, "im": 0.2622948413392345 }, { "mathjs": "Complex", "re": 1.4272789941827002, "im": 0.2596779950827949 }, { "mathjs": "Complex", "re": 1.428864305000136, "im": 0.2570513720966109 }, { "mathjs": "Complex", "re": 1.4304334693188836, "im": 0.25441507127155366 }, { "mathjs": "Complex", "re": 1.4319864280607932, "im": 0.25176919186285884 }, { "mathjs": "Complex", "re": 1.4335231227578464, "im": 0.24911383348639088 }, { "mathjs": "Complex", "re": 1.4350434955543556, "im": 0.24644909611489207 }, { "mathjs": "Complex", "re": 1.436547489209145, "im": 0.24377508007421794 }, { "mathjs": "Complex", "re": 1.4380350470977032, "im": 0.24109188603956144 }, { "mathjs": "Complex", "re": 1.4395061132143168, "im": 0.23839961503166104 }, { "mathjs": "Complex", "re": 1.4409606321741775, "im": 0.23569836841299893 }, { "mathjs": "Complex", "re": 1.442398549215469, "im": 0.2329882478839831 }, { "mathjs": "Complex", "re": 1.4438198102014268, "im": 0.2302693554791201 }, { "mathjs": "Complex", "re": 1.445224361622379, "im": 0.22754179356317195 }, { "mathjs": "Complex", "re": 1.4466121505977576, "im": 0.22480566482730344 }, { "mathjs": "Complex", "re": 1.4479831248780926, "im": 0.22206107228521466 }, { "mathjs": "Complex", "re": 1.449337232846977, "im": 0.21930811926926377 }, { "mathjs": "Complex", "re": 1.450674423523011, "im": 0.21654690942657603 }, { "mathjs": "Complex", "re": 1.4519946465617217, "im": 0.21377754671514101 }, { "mathjs": "Complex", "re": 1.4532978522574576, "im": 0.21100013539989992 }, { "mathjs": "Complex", "re": 1.4545839915452612, "im": 0.20821478004881858 }, { "mathjs": "Complex", "re": 1.455853016002715, "im": 0.20542158552895207 }, { "mathjs": "Complex", "re": 1.4571048778517652, "im": 0.20262065700249496 }, { "mathjs": "Complex", "re": 1.4583395299605213, "im": 0.19981209992282353 }, { "mathjs": "Complex", "re": 1.459556925845029, "im": 0.19699602003052408 }, { "mathjs": "Complex", "re": 1.460757019671021, "im": 0.1941725233494133 }, { "mathjs": "Complex", "re": 1.4619397662556435, "im": 0.19134171618254495 }, { "mathjs": "Complex", "re": 1.4631051210691557, "im": 0.18850370510820907 }, { "mathjs": "Complex", "re": 1.4642530402366076, "im": 0.18565859697591885 }, { "mathjs": "Complex", "re": 1.4653834805394919, "im": 0.1828064989023869 }, { "mathjs": "Complex", "re": 1.4664963994173694, "im": 0.17994751826749417 }, { "mathjs": "Complex", "re": 1.4675917549694737, "im": 0.1770817627102452 }, { "mathjs": "Complex", "re": 1.4686695059562873, "im": 0.1742093401247174 }, { "mathjs": "Complex", "re": 1.469729611801095, "im": 0.17133035865599722 }, { "mathjs": "Complex", "re": 1.4707720325915103, "im": 0.16844492669611016 }, { "mathjs": "Complex", "re": 1.4717967290809801, "im": 0.16555315287993824 }, { "mathjs": "Complex", "re": 1.4728036626902605, "im": 0.16265514608113163 }, { "mathjs": "Complex", "re": 1.4737927955088705, "im": 0.1597510154080079 }, { "mathjs": "Complex", "re": 1.4747640902965182, "im": 0.1568408701994457 }, { "mathjs": "Complex", "re": 1.4757175104845042, "im": 0.15392482002076752 }, { "mathjs": "Complex", "re": 1.4766530201770969, "im": 0.15100297465961401 }, { "mathjs": "Complex", "re": 1.4775705841528852, "im": 0.148075444121812 }, { "mathjs": "Complex", "re": 1.4784701678661043, "im": 0.1451423386272312 }, { "mathjs": "Complex", "re": 1.4793517374479357, "im": 0.14220376860563605 }, { "mathjs": "Complex", "re": 1.480215259707783, "im": 0.13925984469252659 }, { "mathjs": "Complex", "re": 1.4810607021345208, "im": 0.13631067772497463 }, { "mathjs": "Complex", "re": 1.48188803289772, "im": 0.13335637873744924 }, { "mathjs": "Complex", "re": 1.4826972208488447, "im": 0.13039705895763792 }, { "mathjs": "Complex", "re": 1.483488235522426, "im": 0.12743282980225734 }, { "mathjs": "Complex", "re": 1.4842610471372086, "im": 0.12446380287286005 }, { "mathjs": "Complex", "re": 1.485015626597272, "im": 0.12149008995163203 }, { "mathjs": "Complex", "re": 1.4857519454931258, "im": 0.11851180299718359 }, { "mathjs": "Complex", "re": 1.48646997610278, "im": 0.11552905414033567 }, { "mathjs": "Complex", "re": 1.4871696913927879, "im": 0.11254195567989642 }, { "mathjs": "Complex", "re": 1.4878510650192642, "im": 0.10955062007843502 }, { "mathjs": "Complex", "re": 1.4885140713288771, "im": 0.10655515995804571 }, { "mathjs": "Complex", "re": 1.4891586853598138, "im": 0.10355568809610942 }, { "mathjs": "Complex", "re": 1.4897848828427203, "im": 0.100552317421046 }, { "mathjs": "Complex", "re": 1.4903926402016152, "im": 0.0975451610080643 }, { "mathjs": "Complex", "re": 1.4909819345547777, "im": 0.09453433207490318 }, { "mathjs": "Complex", "re": 1.4915527437156082, "im": 0.09151994397757045 }, { "mathjs": "Complex", "re": 1.4921050461934646, "im": 0.08850211020607447 }, { "mathjs": "Complex", "re": 1.4926388211944706, "im": 0.08548094438015061 }, { "mathjs": "Complex", "re": 1.4931540486222992, "im": 0.08245656024498507 }, { "mathjs": "Complex", "re": 1.4936507090789293, "im": 0.07942907166693074 }, { "mathjs": "Complex", "re": 1.4941287838653747, "im": 0.07639859262922184 }, { "mathjs": "Complex", "re": 1.4945882549823906, "im": 0.0733652372276809 }, { "mathjs": "Complex", "re": 1.4950291051311484, "im": 0.07032911966642477 }, { "mathjs": "Complex", "re": 1.49545131771389, "im": 0.06729035425356314 }, { "mathjs": "Complex", "re": 1.4958548768345499, "im": 0.06424905539689654 }, { "mathjs": "Complex", "re": 1.496239767299355, "im": 0.061205337599608174 }, { "mathjs": "Complex", "re": 1.4966059746173972, "im": 0.058159315455952355 }, { "mathjs": "Complex", "re": 1.496953485001178, "im": 0.05511110364694162 }, { "mathjs": "Complex", "re": 1.4972822853671277, "im": 0.052060816936027286 }, { "mathjs": "Complex", "re": 1.4975923633360984, "im": 0.04900857016478041 }, { "mathjs": "Complex", "re": 1.49788370723383, "im": 0.045954478248566376 }, { "mathjs": "Complex", "re": 1.498156306091389, "im": 0.04289865617222008 }, { "mathjs": "Complex", "re": 1.4984101496455828, "im": 0.0398412189857151 }, { "mathjs": "Complex", "re": 1.498645228339345, "im": 0.036782281799833866 }, { "mathjs": "Complex", "re": 1.4988615333220958, "im": 0.03372195978183209 }, { "mathjs": "Complex", "re": 1.4990590564500745, "im": 0.030660368151104244 }, { "mathjs": "Complex", "re": 1.4992377902866474, "im": 0.027597622174845047 }, { "mathjs": "Complex", "re": 1.4993977281025863, "im": 0.024533837163708983 }, { "mathjs": "Complex", "re": 1.4995388638763227, "im": 0.02146912846747051 }, { "mathjs": "Complex", "re": 1.4996611922941747, "im": 0.018403611470679416 }, { "mathjs": "Complex", "re": 1.4997647087505466, "im": 0.015337401588318433 }, { "mathjs": "Complex", "re": 1.499849409348102, "im": 0.012270614261456163 }, { "mathjs": "Complex", "re": 1.4999152908979116, "im": 0.00920336495290255 }, { "mathjs": "Complex", "re": 1.4999623509195723, "im": 0.0061357691428600035 }, { "mathjs": "Complex", "re": 1.4999905876413004, "im": 0.0030679423245773994 } ], "w": [ 0, 0.006135923151542565, 0.01227184630308513, 0.018407769454627694, 0.02454369260617026, 0.030679615757712823, 0.03681553890925539, 0.04295146206079795, 0.04908738521234052, 0.05522330836388308, 0.06135923151542565, 0.0674951546669682, 0.07363107781851078, 0.07976700097005335, 0.0859029241215959, 0.09203884727313846, 0.09817477042468103, 0.1043106935762236, 0.11044661672776616, 0.11658253987930872, 0.1227184630308513, 0.12885438618239387, 0.1349903093339364, 0.14112623248547898, 0.14726215563702155, 0.15339807878856412, 0.1595340019401067, 0.16566992509164924, 0.1718058482431918, 0.17794177139473438, 0.18407769454627693, 0.1902136176978195, 0.19634954084936207, 0.20248546400090464, 0.2086213871524472, 0.21475731030398976, 0.22089323345553233, 0.2270291566070749, 0.23316507975861744, 0.23930100291016002, 0.2454369260617026, 0.25157284921324513, 0.25770877236478773, 0.2638446955163303, 0.2699806186678728, 0.2761165418194154, 0.28225246497095796, 0.28838838812250056, 0.2945243112740431, 0.30066023442558565, 0.30679615757712825, 0.3129320807286708, 0.3190680038802134, 0.32520392703175593, 0.3313398501832985, 0.3374757733348411, 0.3436116964863836, 0.34974761963792617, 0.35588354278946877, 0.3620194659410113, 0.36815538909255385, 0.37429131224409645, 0.380427235395639, 0.3865631585471816, 0.39269908169872414, 0.3988350048502667, 0.4049709280018093, 0.4111068511533518, 0.4172427743048944, 0.42337869745643697, 0.4295146206079795, 0.4356505437595221, 0.44178646691106466, 0.4479223900626072, 0.4540583132141498, 0.46019423636569234, 0.4663301595172349, 0.4724660826687775, 0.47860200582032003, 0.48473792897186263, 0.4908738521234052, 0.4970097752749477, 0.5031456984264903, 0.5092816215780329, 0.5154175447295755, 0.521553467881118, 0.5276893910326605, 0.5338253141842031, 0.5399612373357456, 0.5460971604872883, 0.5522330836388308, 0.5583690067903734, 0.5645049299419159, 0.5706408530934585, 0.5767767762450011, 0.5829126993965437, 0.5890486225480862, 0.5951845456996288, 0.6013204688511713, 0.607456392002714, 0.6135923151542565, 0.619728238305799, 0.6258641614573416, 0.6320000846088841, 0.6381360077604268, 0.6442719309119693, 0.6504078540635119, 0.6565437772150544, 0.662679700366597, 0.6688156235181395, 0.6749515466696822, 0.6810874698212247, 0.6872233929727672, 0.6933593161243098, 0.6994952392758523, 0.705631162427395, 0.7117670855789375, 0.7179030087304801, 0.7240389318820226, 0.7301748550335652, 0.7363107781851077, 0.7424467013366504, 0.7485826244881929, 0.7547185476397354, 0.760854470791278, 0.7669903939428205, 0.7731263170943632, 0.7792622402459057, 0.7853981633974483, 0.7915340865489908, 0.7976700097005334, 0.803805932852076, 0.8099418560036186, 0.8160777791551611, 0.8222137023067037, 0.8283496254582462, 0.8344855486097889, 0.8406214717613314, 0.8467573949128739, 0.8528933180644165, 0.859029241215959, 0.8651651643675016, 0.8713010875190442, 0.8774370106705868, 0.8835729338221293, 0.8897088569736719, 0.8958447801252144, 0.9019807032767571, 0.9081166264282996, 0.9142525495798421, 0.9203884727313847, 0.9265243958829272, 0.9326603190344698, 0.9387962421860124, 0.944932165337555, 0.9510680884890975, 0.9572040116406401, 0.9633399347921826, 0.9694758579437253, 0.9756117810952678, 0.9817477042468103, 0.9878836273983529, 0.9940195505498954, 1.000155473701438, 1.0062913968529805, 1.012427320004523, 1.0185632431560658, 1.0246991663076084, 1.030835089459151, 1.0369710126106935, 1.043106935762236, 1.0492428589137786, 1.055378782065321, 1.0615147052168636, 1.0676506283684062, 1.0737865515199487, 1.0799224746714913, 1.086058397823034, 1.0921943209745766, 1.0983302441261191, 1.1044661672776617, 1.1106020904292042, 1.1167380135807468, 1.1228739367322893, 1.1290098598838318, 1.1351457830353744, 1.141281706186917, 1.1474176293384597, 1.1535535524900022, 1.1596894756415448, 1.1658253987930873, 1.1719613219446299, 1.1780972450961724, 1.184233168247715, 1.1903690913992575, 1.1965050145508, 1.2026409377023426, 1.2087768608538851, 1.214912784005428, 1.2210487071569704, 1.227184630308513, 1.2333205534600555, 1.239456476611598, 1.2455923997631406, 1.2517283229146832, 1.2578642460662257, 1.2640001692177683, 1.2701360923693108, 1.2762720155208536, 1.282407938672396, 1.2885438618239387, 1.2946797849754812, 1.3008157081270237, 1.3069516312785663, 1.3130875544301088, 1.3192234775816514, 1.325359400733194, 1.3314953238847365, 1.337631247036279, 1.3437671701878218, 1.3499030933393643, 1.3560390164909069, 1.3621749396424494, 1.368310862793992, 1.3744467859455345, 1.380582709097077, 1.3867186322486196, 1.3928545554001621, 1.3989904785517047, 1.4051264017032472, 1.41126232485479, 1.4173982480063325, 1.423534171157875, 1.4296700943094176, 1.4358060174609601, 1.4419419406125027, 1.4480778637640452, 1.4542137869155878, 1.4603497100671303, 1.4664856332186729, 1.4726215563702154, 1.4787574795217582, 1.4848934026733007, 1.4910293258248433, 1.4971652489763858, 1.5033011721279284, 1.509437095279471, 1.5155730184310134, 1.521708941582556, 1.5278448647340985, 1.533980787885641, 1.5401167110371838, 1.5462526341887264, 1.552388557340269, 1.5585244804918115, 1.564660403643354, 1.5707963267948966, 1.576932249946439, 1.5830681730979816, 1.5892040962495242, 1.5953400194010667, 1.6014759425526093, 1.607611865704152, 1.6137477888556946, 1.6198837120072371, 1.6260196351587797, 1.6321555583103222, 1.6382914814618648, 1.6444274046134073, 1.6505633277649499, 1.6566992509164924, 1.662835174068035, 1.6689710972195777, 1.6751070203711202, 1.6812429435226628, 1.6873788666742053, 1.6935147898257479, 1.6996507129772904, 1.705786636128833, 1.7119225592803755, 1.718058482431918, 1.7241944055834606, 1.7303303287350031, 1.736466251886546, 1.7426021750380885, 1.748738098189631, 1.7548740213411735, 1.761009944492716, 1.7671458676442586, 1.7732817907958012, 1.7794177139473437, 1.7855536370988863, 1.7916895602504288, 1.7978254834019713, 1.8039614065535141, 1.8100973297050567, 1.8162332528565992, 1.8223691760081417, 1.8285050991596843, 1.8346410223112268, 1.8407769454627694, 1.846912868614312, 1.8530487917658545, 1.859184714917397, 1.8653206380689396, 1.8714565612204823, 1.8775924843720249, 1.8837284075235674, 1.88986433067511, 1.8960002538266525, 1.902136176978195, 1.9082721001297376, 1.9144080232812801, 1.9205439464328227, 1.9266798695843652, 1.932815792735908, 1.9389517158874505, 1.945087639038993, 1.9512235621905356, 1.9573594853420782, 1.9634954084936207, 1.9696313316451632, 1.9757672547967058, 1.9819031779482483, 1.9880391010997909, 1.9941750242513334, 2.000310947402876, 2.0064468705544187, 2.012582793705961, 2.018718716857504, 2.024854640009046, 2.030990563160589, 2.0371264863121317, 2.043262409463674, 2.0493983326152168, 2.055534255766759, 2.061670178918302, 2.067806102069844, 2.073942025221387, 2.0800779483729293, 2.086213871524472, 2.0923497946760143, 2.098485717827557, 2.1046216409791, 2.110757564130642, 2.116893487282185, 2.1230294104337273, 2.12916533358527, 2.1353012567368124, 2.141437179888355, 2.1475731030398975, 2.1537090261914402, 2.1598449493429825, 2.1659808724945253, 2.172116795646068, 2.1782527187976104, 2.184388641949153, 2.1905245651006955, 2.1966604882522383, 2.2027964114037806, 2.2089323345553233, 2.2150682577068657, 2.2212041808584084, 2.227340104009951, 2.2334760271614935, 2.2396119503130363, 2.2457478734645786, 2.2518837966161214, 2.2580197197676637, 2.2641556429192065, 2.270291566070749, 2.2764274892222915, 2.282563412373834, 2.2886993355253766, 2.2948352586769194, 2.3009711818284617, 2.3071071049800045, 2.313243028131547, 2.3193789512830896, 2.325514874434632, 2.3316507975861747, 2.337786720737717, 2.3439226438892597, 2.350058567040802, 2.356194490192345, 2.3623304133438876, 2.36846633649543, 2.3746022596469727, 2.380738182798515, 2.386874105950058, 2.3930100291016, 2.399145952253143, 2.405281875404685, 2.411417798556228, 2.4175537217077703, 2.423689644859313, 2.429825568010856, 2.435961491162398, 2.442097414313941, 2.448233337465483, 2.454369260617026, 2.4605051837685683, 2.466641106920111, 2.4727770300716534, 2.478912953223196, 2.4850488763747385, 2.4911847995262812, 2.497320722677824, 2.5034566458293663, 2.509592568980909, 2.5157284921324514, 2.521864415283994, 2.5280003384355365, 2.5341362615870793, 2.5402721847386216, 2.5464081078901644, 2.552544031041707, 2.5586799541932495, 2.564815877344792, 2.5709518004963345, 2.5770877236478773, 2.5832236467994196, 2.5893595699509624, 2.5954954931025047, 2.6016314162540475, 2.60776733940559, 2.6139032625571326, 2.6200391857086753, 2.6261751088602177, 2.6323110320117604, 2.6384469551633027, 2.6445828783148455, 2.650718801466388, 2.6568547246179306, 2.662990647769473, 2.6691265709210157, 2.675262494072558, 2.6813984172241008, 2.6875343403756435, 2.693670263527186, 2.6998061866787286, 2.705942109830271, 2.7120780329818137, 2.718213956133356, 2.724349879284899, 2.730485802436441, 2.736621725587984, 2.742757648739526, 2.748893571891069, 2.7550294950426117, 2.761165418194154, 2.767301341345697, 2.773437264497239, 2.779573187648782, 2.7857091108003242, 2.791845033951867, 2.7979809571034093, 2.804116880254952, 2.8102528034064944, 2.816388726558037, 2.82252464970958, 2.8286605728611223, 2.834796496012665, 2.8409324191642074, 2.84706834231575, 2.8532042654672924, 2.859340188618835, 2.8654761117703775, 2.8716120349219203, 2.8777479580734626, 2.8838838812250054, 2.890019804376548, 2.8961557275280905, 2.9022916506796332, 2.9084275738311756, 2.9145634969827183, 2.9206994201342606, 2.9268353432858034, 2.9329712664373457, 2.9391071895888885, 2.945243112740431, 2.9513790358919736, 2.9575149590435164, 2.9636508821950587, 2.9697868053466014, 2.9759227284981438, 2.9820586516496865, 2.988194574801229, 2.9943304979527716, 3.000466421104314, 3.0066023442558567, 3.0127382674073995, 3.018874190558942, 3.0250101137104846, 3.031146036862027, 3.0372819600135696, 3.043417883165112, 3.0495538063166547, 3.055689729468197, 3.06182565261974, 3.067961575771282, 3.074097498922825, 3.0802334220743677, 3.08636934522591, 3.0925052683774528, 3.098641191528995, 3.104777114680538, 3.11091303783208, 3.117048960983623, 3.1231848841351653, 3.129320807286708, 3.1354567304382504 ] }
zpk2tfCompute the transfer function from zero, pole, and gain data.zpk2tf([-0.5], [1], 1)z (array), p (array), k (number)[ [ { "mathjs": "Complex", "re": 1, "im": 0 }, { "mathjs": "Complex", "re": 0.5, "im": 0 } ], [ { "mathjs": "Complex", "re": 1, "im": 0 }, { "mathjs": "Complex", "re": -1, "im": 0 } ] ]

Special functions

FunctionDefinitionExample callParametersExpected result
erfCompute the error function using rational Chebyshev approximations.erf(0.5)x (number)0.5204998778130465
zetaCompute the Riemann Zeta function using a series expansion.zeta(2)n (number)1.6449340668482526

Statistics functions

FunctionDefinitionExample callParametersExpected result
corrCompute the correlation coefficient between two lists or matrices.corr([2, 3, 4], [5, 6, 7])A (Array|Matrix), B (Array|Matrix)1
cumsumCompute the cumulative sum of a list or matrix.cumsum([1, 2, 3, 4])[ 1, 3, 6, 10 ]
madCompute the median absolute deviation of values.mad([1, 2, 3, 4])1
maxCompute the maximum of a list or matrix.max([1, 2, 3])3
meanCompute the mean (average) of values.mean([2, 4, 6])4
medianCompute the median of values.median([1, 2, 3, 4, 5])3
minCompute the minimum of a list or matrix.min([1, 2, 3])1
modeCompute the mode of a list or set of values.mode([1, 2, 2, 3])[ 2 ]
prodCompute the product of a list or matrix.prod([1, 2, 3, 4])24
quantileSeqCompute the prob-order quantile of given data.quantileSeq([1, 2, 3, 4], 0.25)1.75
stdCompute the standard deviation of data.std([1, 2, 3, 4])1.2909944487358056
sumCompute the sum of a list or matrix.sum([1, 2, 3])6
varianceCompute the variance of data.variance([1, 2, 3, 4])1.6666666666666667

String functions

FunctionDefinitionExample callParametersExpected result
binFormat a number as binary.bin(13)0b1101
formatFormat a value of any type into a string with optional precision.format(123.456, 2)120
hexFormat a number as hexadecimal.hex(255)0xff
octFormat a number as octal.oct(64)0o100
printInterpolate values into a string template.print('x = $x, y = $y', {x: 3, y: 4}, 2)x = 3, y = 4

Trigonometry functions

FunctionDefinitionExample callParametersExpected result
acosCalculate the inverse cosine.acos(0.5)1.0471975511965979
acoshCalculate the hyperbolic arccos.acosh(2)1.3169578969248166
acotCalculate the inverse cotangent.acot(1)0.7853981633974483
acothCalculate the inverse hyperbolic cotangent.acoth(2)0.5493061443340548
acscCalculate the inverse cosecant.acsc(2)0.5235987755982989
acschCalculate the inverse hyperbolic cosecant.acsch(2)0.48121182505960347
asecCalculate the inverse secant.asec(2)1.0471975511965979
asechCalculate the inverse hyperbolic secant.asech(0.5)1.3169578969248166
asinCalculate the inverse sine.asin(0.5)0.5235987755982989
asinhCalculate the hyperbolic arcsine.asinh(1.5)1.1947632172871094
atanCalculate the inverse tangent.atan(1)0.7853981633974483
atan2Calculate the two-argument inverse tangent.atan2(1, 2)0.4636476090008061
atanhCalculate the hyperbolic arctangent.atanh(0.5)0.5493061443340548
cosCalculate the cosine of x.cos(0.5)0.8775825618903728
coshCalculate the hyperbolic cosine of x.cosh(0.5)1.1276259652063807
cotCalculate the cotangent of x.cot(0.5)1.830487721712452
cothCalculate the hyperbolic cotangent of x.coth(0.5)2.163953413738653
cscCalculate the cosecant of x.csc(0.5)2.085829642933488
cschCalculate the hyperbolic cosecant of x.csch(0.5)1.9190347513349437
secCalculate the secant of x.sec(0.5)1.139493927324549
sechCalculate the hyperbolic secant of x.sech(0.5)0.886818883970074
sinCalculate the sine of x.sin(0.5)0.479425538604203
sinhCalculate the hyperbolic sine of x.sinh(0.5)0.5210953054937474
tanCalculate the tangent of x.tan(0.5)0.5463024898437905
tanhCalculate the hyperbolic tangent of x.tanh(0.5)0.46211715726000974

Unit functions

FunctionDefinitionExample callParametersExpected result
toConvert a value to another unit.to(5, 'cm')Error: Unexpected type of argument in function to (expected: Array or DenseMatrix or Matrix, actual: identifier | string, index: 1)

Utils functions

FunctionDefinitionExample callParametersExpected result
cloneMake a deep copy of a value.clone([1, 2, 3])[ 1, 2, 3 ]
hasNumericValueTest whether the value contains a valid numeric value.hasNumericValue('123')true
isIntegerTest whether the value is an integer.isInteger(3.0)true
isNaNTest whether the value is NaN (not a number).isNaN(NaN)true
isNegativeTest whether the value is negative.isNegative(-5)true
isNumericTest whether the value is numeric.isNumeric('123')false
isPositiveTest whether the value is positive.isPositive(2)true
isPrimeTest whether the value is a prime number.isPrime(7)true
isZeroTest whether the value is zero.isZero(0)true
numericConvert the value to a specific numeric type (number, BigNumber, etc.).numeric('123')123
typeOfReturn the type name of the value.typeOf([1, 2, 3])Array