ArrayMatMul¶
Array matrix multiplication.
Declaration¶
Sintaxe¶
ArrayMatMul(expr matrix_a, expr matrix_b, ttype type, expr? value)
Argumentos¶
Argument Name |
Argument Description |
---|---|
|
matrix first |
|
second matrix |
|
table entry type |
`value |
expression value |
Valores de retorno¶
The return value is the expression that the ArrayMatMul represents.
Descrição¶
ArrayMatMul represents array matrix multiplication.
Tipos¶
Only accepts integers.
Exemplos¶
integer :: a(3, 4)
real :: b(4, 3), cmat(3, 3)
cmat = matmul(a, b)
ASR:
(TranslationUnit
(SymbolTable
1
{
a:
(Variable
1
a
Local
()
()
Default
(Integer 4 [((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 3 (Integer 4 [])))
((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 4 (Integer 4 [])))])
Source
Public
Required
.false.
),
b:
(Variable
1
b
Local
()
()
Default
(Real 4 [((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 4 (Integer 4 [])))
((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 3 (Integer 4 [])))])
Source
Public
Required
.false.
),
cmat:
(Variable
1
cmat
Local
()
()
Default
(Real 4 [((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 3 (Integer 4 [])))
((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 3 (Integer 4 [])))])
Source
Public
Required
.false.
)
})
[(=
(Var 1 cmat)
(ArrayMatMul
(Var 1 a)
(Var 1 b)
(Real 4 [((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 3 (Integer 4 [])))
((IntegerConstant 1 (Integer 4 []))
(IntegerConstant 3 (Integer 4 [])))])
()
)
()
)]
)