FFT Example: 2D Signal - Teradata Vantage

Machine Learning Engine Analytic Function Reference

Product
Teradata Vantage
Release Number
8.10
1.1
Published
October 2019
Language
English (United States)
Last Update
2019-12-31
dita:mapPath
ima1540829771750.ditamap
dita:ditavalPath
jsj1481748799576.ditaval
dita:id
B700-4003
lifecycle
previous
Product Category
Teradata Vantageā„¢

In this example, the signal is two-dimensional (2D).

Input

The InputTable has one time sequence of 2D signals of length 4, represented by a 2x2 matrix in the value1 column. The first two value1 values (1, 2) represent the first column of the matrix. The next two value1 values (3, 4) represent the second column of the matrix.

InputTable: fft_input2
id1 timestep value1
1 1 1
1 2 2
1 3 3
1 4 4

SQL Call

CREATE MULTISET TABLE fft_output_2 AS (
  SELECT * FROM FFT (
    ON fft_input2 AS InputTable PARTITION BY id1 ORDER BY timestep
    USING
    TargetColumns ('value1')
    Dimensions (2)
  ) AS dt
) WITH DATA;

Output

SELECT * FROM fft_output_2;
 id_0 timestep real_value1 imag_value1 
 ---- -------- ----------- ----------- 
    1        3        -4.0         0.0
    1        4         0.0         0.0
    1        2        -2.0         0.0
    1        1        10.0         0.0

Download a zip file of all examples and a SQL script file that creates their input tables from the attachment in the left sidebar.