## Mathematics

### Complex Numbers

COMPLEX - Converts argument to complex type.

CONJ - Returns the complex conjugate of X.

DCOMPLEX - Converts argument to double-precision complex type.

IMAGINARY - Returns the imaginary part of a complex value.

REAL_PART - Returns the real part of a complex-valued argument.

### Correlation Analysis

A_CORRELATE - Computes autocorrelation.

C_CORRELATE - Computes cross correlation.

CORRELATE - Computes the linear Pearson correlation.

M_CORRELATE - Computes multiple correlation coefficient.

P_CORRELATE - Computes partial correlation coefficient.

R_CORRELATE - Computes rank correlation.

### Curve and Surface Fitting

COMFIT - Fits paired data using one of six common filtering functions.

CRVLENGTH - Computes the length of a curve.

CURVEFIT - Fits multivariate data with a user-supplied function.

GAUSS2DFIT - Fits a 2D elliptical Gaussian equation to rectilinearly gridded data.

GAUSSFIT - Fits the sum of a Gaussian and a quadratic.

GRID_TPS - Uses thin plate splines to interpolate a set of values over a regular 2D grid, from irregularly sampled data values.

KRIG2D - Interpolates set of points using kriging.

LADFIT - Fits paired data using least absolute deviation method.

LINFIT - Fits by minimizing the Chi-square error statistic.

LMFIT - Does a non-linear least squares fit.

MIN_CURVE_SURF -  Interpolates points with a minimum curvature surface or a thin-plate-spline surface. Useful with CONTOUR.

POLY_FIT - Performs a least-square polynomial fit.

REGRESS - Computes fit using multiple linear regression.

SFIT - Performs polynomial fit to a surface.

SVDFIT - Multivariate least squares fit using SVD method.

TRIGRID - Interpolates irregularly-gridded data to a regular grid from a triangulation.

### Differentiation and Integration

CRVLENGTH - Computes the length of a curve.

DERIV - Performs differentiation using 3-point Langrangian interpolation.

DERIVSIG - Computes standard deviation of derivative found by DERIV.

INT_2D - Computes the double integral of a bivariate function.

INT_3D - Computes the triple integral of a trivariate function.

INT_TABULATED - Integrates a tabulated set of data.

LSODE - Advances a solution to a system of ordinary differential equations one time-step H.

QROMB - Evaluates integral over a closed interval.

QROMO - Evaluates integral over an open interval.

QSIMP - Evaluates integral using Simpson's rule.

RK4 - Solves differential equations using fourth-order Runge-Kutta method.

### Eigenvalues and Eigenvectors

EIGENQL - Computes eigenvalues and eigenvectors of a real, symmetric array.

EIGENVEC - Computes eigenvectors of a real, non-symmetric array.

ELMHES - Reduces nonsymmetric array to upper Hessenberg form.

HQR - Returns all eigenvalues of an upper Hessenberg array.

TRIQL - Determines eigenvalues and eigenvectors of tridiagonal array.

TRIRED - Reduces a real, symmetric array to tridiagonal form.

### Gridding and Interpolation

BILINEAR - Computes array using bilinear interpolation.

GRID_INPUT - Preprocesses and sorts two-dimensional scattered data points, and removes duplicate values.

GRID_TPS - Uses thin plate splines to interpolate a set of values over a regular 2D grid, from irregularly sampled data values.

GRID3 - Creates a regularly-gridded 3D dataset from a set of scattered 3D nodes.

GRIDDATA - Interpolates scattered data values and locations sampled on a plane or a sphere to a regular grid.

INTERPOL - Performs linear interpolation on vectors.

INTERPOLATE - Returns an array of interpolates.

KRIG2D - Interpolates set of points using kriging.

MIN_CURVE_SURF - Interpolates points with a minimum curvature surface or a thin-plate-spline surface. Useful with CONTOUR.

POLAR_SURFACE - Interpolates a surface from polar coordinates to rectangular coordinates.

SPH_SCAT - Performs spherical gridding.

SPL_INIT - Establishes the type of interpolating spline.

SPL_INTERP - Performs cubic spline interpolation (Numerical Recipes).

SPLINE - Performs cubic spline interpolation.

SPLINE_P - Performs parametric cubic spline interpolation.

TRI_SURF - Interpolates gridded set of points with a smooth quintic surface.

TRIANGULATE - Constructs Delaunay triangulation of a planar set of points.

TRIGRID - Interpolates irregularly-gridded data to a regular grid from a triangulation.

VALUE_LOCATE - Finds the intervals within a given monotonic vector that brackets a given set of one or more search values.

VORONOI - Computes Voronoi polygon given Delaunay triangulation.

### Hypothesis Testing

CTI_TEST - Performs chi-square goodness-of-fit test.

FV_TEST - Performs the F-variance test.

KW_TEST - Performs Kruskal-Wallis H-test.

LNP_TEST - Computes the Lomb Normalized Periodogram.

MD_TEST - Performs the Median Delta test.

R_TEST - Runs test for randomness.

RS_TEST - Performs the Wilcoxon Rank-Sum test.

S_TEST - Performs the Sign test.

TM_TEST - Performs t-means test.

XSQ_TEST - Computes Chi-square goodness-of-fit test.

### LAPACK Routines

LA_CHOLDC - Computes the Cholesky factorization of an n-by-n symmetric positive-definite array.

LA_CHOLMPROVE - Uses Cholesky factorization to improve the solution to a system of linear equations.

LA_CHOLSOL - Used in conjunction with LA_CHOLDC to solve a set of linear equations.

LA_DETERM - Uses LU decomposition to compute the determinant of a square array.

LA_EIGENPROBLEM - Uses the QR algorithm to compute eigenvalues and eigenvectors of an array.

LA_EIGENQL - Computes selected eigenvalues and eigenvectors.

LA_EIGENVEC - Uses the QR algorithm to compute all of some eigenvectors of an array.

LA_ELMHES - Reduces a real nonsymmetric or complex array to upper Hessenberg from.

LA_GM_LINEAR_MODEL - Used to solve a general Gauss-Markov linear model problem.

LA_HQR - Uses the multishift QR algorithm to compute all eigenvalues of an array.

LA_INVERT - Uses LU decomposition to compute the inverse of a square array.

LA_LEAST_SQUARE_EQUALITY - Used to solve linear least-squares problems.

LA_LEAST_SQUARES - Used to solve linear least-squares problems.

LA_LINEAR_EQUATION - Uses LU decomposition to sole a system of linear equations.

LA_LUDC - Computes the LU decomposition of an array.

LA_LUMPROVE - Uses LU decomposition to improve the solution to a system of linear equations.

LA_LUSOL - Used in conjunction with LA_LUDC to solve a set of linear equations.

LA_SVD - Computes the singular value decomposition of an array.

LA_TRIDC - Computes the LU decomposition of a tridiagonal array.

LA_TRIMPROVE - Improves the solution to a system of linear equations with a tridiagonal array.

LA_TRIQL - Uses the QL and QR variants of the implicitly-shifted QR algorithm to compute the eigenvalues and eigenvectors of an array.

LA_TRIRED - Reduces a real symmetric or complex Hermitian array to real tridiagonal from.

LA_TRISOL - Used in conjunction with LA_TRIDC to solve a set of linear equations.

### Linear Systems

CHOLDC - Constructs Cholesky decomposition of a matrix.

CHOLSOL - Solves set of linear equations (use with CHOLDC).

COND - Computes the condition number of a square matrix.

CRAMER - Solves system of linear equations using Cramer's rule.

CROSSP - Computes vector cross product.

DETERM - Computes the determinant of a square matrix.

GS_ITER - Solves linear system using Gauss-Seidel iteration.

IDENTITY - Returns an identity array.

INVERT - Computes the inverse of a square array.

LINBCG - Solves a set of sparse linear equations using the iterative biconjugate gradient method.

LU_COMPLEX - Solves complex linear system using LU decomposition.

LUDC - Replaces array with the LU decomposition.

LUMPROVE - Uses LU decomposition to iteratively improve an approximate solution.

LUSOL - Solves a set of linear equations. Use with LUDC.

NORM - Computes Euclidean norm of vector or Infinity norm of array.

SVDC - Computes Singular Value Decomposition of an array.

SVSOL - Solves set of linear equations using back-substitution.

TRACE - Computes the trace of an array.

TRISOL - Solves tridiagonal systems of linear equations.

### Mathematical Error Assessment

CHECK_MATH - Returns and clears accumulated math error status.

FINITE - Returns True if its argument is finite.

MACHAR - Determines and returns machine-specific parameters affecting floating-point arithmetic.

### Miscellaneous Math Routines

ABS - Returns the absolute value of X.

CEIL - Returns the closest integer greater than or equal to X.

CIR_3PNT - Returns radius and center of circle, given 3 points.

COMPLEXROUND - Rounds a complex array.

DIAG_MATRIX - Constructs a diagonal matrix from an input vector, or if given a matrix, then extracts a diagonal vector.

DIST - Creates array with each element proportional to its frequency.

EXP - Returns the natural exponential function of given expression.

FLOOR - Returns closest integer less than or equal to argument.

IMAGINARY - Returns the imaginary part of a complex value.

ISHFT - Performs integer bit shift.

LEEFILT - Performs the Lee filter algorithm on an image array.

MATRIX_MULTIPLY - Calculates the IDL matrix-multiply operator (#) of two (possibly transposed) arrays.

MATRIX_POWER - Computes the product of a matrix with itself.

PNT_LINE - Returns the perpendicular distance between a point and a line.

POLY_AREA - Returns the area of a polygon given the coordinates of its vertices.

PRIMES - Computes the first K prime numbers.

PRODUCT - Returns the product of elements within an army.

ROUND - Returns the integer closest to its argument.

SPH_4PNT - Returns center and radius of a sphere given 4 points.

SQRT - Returns the square root of X.

TOTAL - Sums of the elements of an array.

VOIGT - Calculates intensity of atomic absorption line (Voight) profile.

### Multivariate Analysis

CLUST_WTS - Computes cluster weights of array for cluster analysis.

CLUSTER - Performs cluster analysis.

CLUSTER_TREE - Computes the hierarchical clustering for a set of m items in an n-dimensional space.

CTI_TEST - Performs chi-square goodness-of-fit test.

DENDRO_PLOT - Draws a two-dimensional dendrite plot on the current direct graphics device if given a hierarchical tree cluster, as created by CLUSTER_TREE.

DENDROGRAM - Constructs a dendrogram and returns a set of vertices and connectivity that can be used to visualize the dendrite plot if given a hierarchical tree cluster, as created by CLUSTER_TREE.

DISTANCE_MEASURE - Computes the pairwise distance between a set of items or observations.

KW_TEST - Performs Kruskal-Wallis H-test.

M_CORRELATE - Computes multiple correlation coefficient.

P_CORRELATE - Computes partial correlation coefficient.

PCOMP - Computes principal components/derived variables.

STANDARDIZE - Computes standardized variables.

### Nonlinear Equations

BROYDEN - Solves nonlinear equations using Broyden's method.

FX_ROOT - Computes real and complex roots of a univariate nonlinear function using an optimal Müller's method.

FZ_ROOTS - Finds the roots of a complex polynomial using Laguerre's method.

NEWTON - Solves nonlinear equations using Newton's method.

### Optimization

AMOEBA - Minimizes a function using downhill simplex method.

CONSTRAINED_MIN - Minimizes a function using Generalized Reduced Gradient Method.

DFPMIN - Minimizes a function using Davidon-Fletcher-Powell method.

POWELL - Minimizes a function using the Powell method.

SIMPLEX - Use the simplex method to solve linear programming problems.

### Probability

BINOMIAL - Computes binomial distribution function.

CHISQR_CVF - Computes cutoff value in a Chi-square distribution.

CHISQR_PDF - Computes Chi-square distribution function.

F_CVF - Computes the cutoff value in an F distribution.

F_PDF - Computes the F distribution function.

GAUSS_CVF - Computes cutoff value in Gaussian distribution.

GAUSS_PDF - Computes Gaussian distribution function.

GAUSSINT - Returns integral of Gaussian probability function.

T_CVF - Computes the cutoff value in a Student's t distribution.

T_PDF - Computes Student's t distribution.

### Sparse Arrays

FULSTR - Restores a sparse matrix to full storage mode.

LINBCG - Solves a set of sparse linear equations using the iterative biconjugate gradient method.

READ_SPR - Reads a row-indexed sparse matrix from a file.

SPRSAB - Performs matrix multiplication on sparse matrices.

SPRSAX - Multiplies sparse matrix by a vector.

SPRSIN - Converts matrix to row-index sparse matrix.

SPRSTP - Constructs the transpose of a sparse matrix.

WRITE_SPR - Writes row-indexed sparse array structure to a file.

### Special Math Functions

BESELI - Returns the I Bessel function of order N for X.

BESELJ - Returns the J Bessel function of order N for X.

BESELK - Returns the K Bessel function of order N for X.

BESELY - Returns the Y Bessel function of order N for X.

BETA - Returns the value of the beta function.

ERF - Returns the value of an error function.

ERFC - Returns the value of a complementary error function.

ERFCX - Returns the value of a scaled complementary error function.

EXPINT - Returns the value of the exponential integral.

GAMMA - Returns the gamma function of X.

IBETA - Computes the incomplete beta function.

IGAMMA - Computes the incomplete gamma function.

LAGUERRE - Returns value of the associated Laguerre polynomial.

LEGENDRE - Returns value of the associated Legendre polynomial.

LNGAMMA - Returns logarithm of the gamma function of X.

POLY - Evaluates polynomial function of a variable.

SPHER_HARM - Returns value of the spherical harmonic function.

### Statistical Fitting

COMFIT - Fits paired data using one of six common filtering functions.

CURVEFIT - Fits multivariate data with a user-supplied function.

FUNCT - Evaluates the sum of a Gaussian and a 2nd-order polynomial and optionally returns the value of its partial derivatives.

LADFIT - Fits paired data using least absolute deviation method.

LINFIT - Fits by minimizing the Chi-square error statistic.

REGRESS - Multiple linear regression.

SVDFIT - Multivariate least squares fit using SVD method.

### Statistical Tools

FACTORIAL - Computes the factorial N!.

HIST_2D - Returns histogram of two variables.

HISTOGRAM - Computes the density function of an array.

KURTOSIS - Computes statistical kurtosis of n-element vector.

MAX - Returns the value of the largest element of an array.

MEAN - Computes the mean of a numeric vector.

MEANABSDEV - Computes the mean absolute deviation of a vector.

MEDIAN - Returns the median value of Array or applies a median filter.

MIN - Returns the value of the smallest element of an array.

MOMENT - Computes mean, variance, skewness, and kurtosis.

RANDOMN - Returns normally-distributed pseudo-random numbers.

RANDOMU - Returns uniformly-distributed pseudo-random numbers.

RANKS - Computes magnitude-based ranks.

SKEWNESS - Computes statistical skewness of an n-element vector.

SORT - Returns the indices of an array sorted in ascending order.

STDDEV - Computes the standard deviation of an n-element vector.

TOTAL - Sums of the elements of an array.

VARIANCE - Computes the statistical variance of an n-element vector.

### Time-Series Analysis

A_CORRELATE - Computes autocorrelation.

C_CORRELATE - Computes cross correlation.

SMOOTH - Smooths with a boxcar average.

TS_COEF - Computes the coefficients for autoregressive time-series.

TS_DIFF - Computes the forward differences of a time-series.

TS_FCAST - Computes future or past values of stationary time-series.

TS_SMOOTH - Computes moving averages of a time-series.

### Transcendental Functions

ACOS - Returns the arc-cosine of X.

ALOG - Returns the natural logarithm of X.

ALOG10 - Returns the logarithm to the base 10 of X.

ASIN - Returns the arc-sine of X.

ATAN - Returns the arc-tangent of X.

COS - Returns the cosine of X.

COSH - Returns the hyperbolic cosine of X.

EXP - Returns the natural exponential function of a given expression.

SIN - Returns the trigonometric sine of X.

SINH - Returns the hyperbolic sine of X.

TAN - Returns the tangent of X.

TANH - Returns the hyperbolic tangent of X.

### Transforms

BLK_CON - Convolves input signal with impulse-response sequence.

CHEBYSHEV - Returns the forward or reverse Chebyshev polynomial expansion.

CONVOL - Convolves two vectors or arrays.

FFT - Returns the Fast Fourier Transform of an array.

HILBERT - Constructs a Hilbert transform.

HOUGH - Returns the Hough transform of a two-dimensional image.

RADON - Returns the Radon transform of a two-dimensional image.

WTN - Returns wavelet transform of the input array.

See Also - Wavelet Toolkit