TD_BINARYMATRIXOP Syntax Elements - Teradata Vantage

Database Unbounded Array Framework Time Series Functions

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2023-12-08
dita:mapPath
ncd1634149624743.ditamap
dita:ditavalPath
ruu1634160136230.ditaval
dita:id
ncd1634149624743
MATRIX_SPEC
The function accepts two matrices having the same dimensions, that is having the same number of matrix rows and same number of matrix columns. The first matrix referenced in the function is referred to the primary matrix. The second matrix is referred as the secondary matrix. The result matrix always inherits the identifiers, MATRIX_ID(), from the primary matrix.

This function also supports combinations in which one input is a univariate matrix and other input is a multivariate matrix. The result series is of type multivariate, and is formulated by reusing the univariate series as many times as necessary to produce the multivariate result.

For CONTENT type, both inputs are required to be of the same high-level classification. When both inputs are univariate, or both are multivariate, then the CONTENT type should match exactly. When one input is univariate and the other is multivariate, then the CONTENT should be of the same classification, meaning both are real, both are rectangular complex, or both are polar amplitude-phase.

See Matrix Specifications.

FUNC_PARAMS
Name Data Type Description
MATHOP Enum, String The mathematical operation to be performed between the passed in primary and secondary matrices. The options are as follows:
  • SUB: For MATHOP(SUB), the secondary series is subtracted from the primary series.
  • ADD: For MATHOP(ADD), the secondary series is added to the primary series.
  • MUL: For MATHOP(MUL), the primary series is multiplied by the secondary series.
  • DIV: For MATHOP(DIV), the primary series is divided by the secondary series.
INPUT_FMT
The INPUT_MODE parameter has the following options:
  • ONE2ONE: Both the primary and secondary matrices specifications include a WHERE filter clause identifying one matrix instance to serve as the input series for the mathematical operation.
  • MANY2ONE: The primary input MATRIX_SPEC references MANY series instances. The secondary input MATRIX_SPEC includes a WHERE filter clause identifying a single matrix instance. When applying the mathematical operation, the secondary input single matrix is reused as many times as necessary to match the number of matrix instances found in the primary input.
  • MATCH: A matrix instance residing in the primary input whose MATRIX_ID matches the MATRIX_ID of a matrix instance in the secondary input, has the mathematical operation applied to produce a result matrix. For those instances in one input who have no corresponding MATRIX_ID partner in the other input, the matrix is skipped over.
OUTPUT_FMT
[Optional] Specify the INDEX_STYLE of the output format. Options are NUMERICAL_SEQUENCE or FLOW_THROUGH. The default is NUMERICAL_SEQUENCE.