LitDev Extension API
LDMathX
![](images/IntellisenseObject.png)
Extended maths methods, FFT and cubic spline.
CreateSpline
![]() |
FFTComplex
![]() |
FFTForward
![]() |
FFTImaginary
![]() |
FFTInverse
![]() |
FFTReal
![]() |
InterpolateSpline
![]() |
CreateSpline(data,mode)
![](images/IntellisenseMethod.png)
Create a cubic spline for later interpolation.
data A set of x,y data in an array data[x]=y.
mode Spline termination (both ends) or other variants
1 : first derivitive = 0
2 : second derivitive = 0
3 : Hermite cubic spline (all first derivatives = 0)
4 : Akima cubic spline (reduce outlier overshoots)
returns The cubic spline.
FFTComplex(real,imaginary)
![](images/IntellisenseMethod.png)
Create an array of complex values from arrays of real and imaginary parts.
real An array of real data.
imaginary An array of imaginary data.
returns An array of complex data (real amplitude and imaginary phase), "MISMATCH" or "FAILED".
For each complex pair the index is the real part and the value is the imaginary part.
FFTForward(real)
![](images/IntellisenseMethod.png)
Compute a FFT (Fast Fourier Transform).
real An array of real values to calculate the FFT from.
returns An array of complex data (real amplitude and imaginary phase) or "FAILED".
For each complex pair the index is the real part and the value is the imaginary part.
FFTImaginary(complex)
![](images/IntellisenseMethod.png)
Get the imaginary part of an array of complex data.
complex An array of complex data (real amplitude and imaginary phase).
For each complex pair the index is the real part and the value is the imaginary part.
returns An array of the imaginary part of the data or "FAILED".
FFTInverse(complex)
![](images/IntellisenseMethod.png)
The inverse of a FFT (Fast Fourier Transform).
complex An array of complex data (real amplitude and imaginary phase).
For each complex pair the index is the real part and the value is the imaginary part.
returns An array of inverse FFT values or "FAILED".
FFTReal(complex)
![](images/IntellisenseMethod.png)
Get the real part of an array of complex data.
complex An array of complex data (real amplitude and imaginary phase).
For each complex pair the index is the real part and the value is the imaginary part.
returns An array of the real part of the data or "FAILED".
InterpolateSpline(splineName,data)
![](images/IntellisenseMethod.png)
Calculated interpolated data from a previopusly created cubic spline.
splineName The cubic spline created with CreateSpline.
data An array of x values to interpolate.
returns An array of interpolated x,y pairs, result[x] = y.