frobenius.prod {matrixcalc} | R Documentation |
This function returns the Fronbenius inner product of two matrices, x and y, with the same row and column dimensions.
frobenius.prod(x, y)
x |
a numeric matrix object |
y |
a numeric matrix object |
The Frobenius inner product is the element-by-element sum of the Hadamard or Shur product of two numeric matrices.
A numeric value.
Frederick Novomestky fnovomes@poly.edu
Magnus, J. R. and H. Neudecker (1999) Matrix Differential Calculus with Applications in Statistics and Econometrics, Second Edition, John Wiley.
x <- matrix( c( 1, 2, 3, 4 ), nrow=2, byrow=TRUE ) y <- matrix( c( 2, 4, 6, 8 ), nrow=2, byrow=TRUE ) z <- frobenius.prod( x, y ) print( z )