R: Compute the inner product between two rectangular matrices

matrix.inner {fastmatrix} | R Documentation

## Compute the inner product between two rectangular matrices

### Description

Computes the inner product between two rectangular matrices calling BLAS.

### Usage

    matrix.inner(x, y = x)

### Arguments

`x` | a numeric matrix.
`y` | a numeric matrix.

### Value

a real value, indicating the inner product between two matrices.

### Examples

    x <- matrix(c(1, 1, 1,
                  1, 2, 1,
                  1, 3, 1,
                  1, 1,-1,
                  1, 2,-1,
                  1, 3,-1), ncol = 3, byrow = TRUE)
    y <- matrix(1, nrow = 6, ncol = 3)
    matrix.inner(x, y)

    # must be equal
    matrix.norm(x, type = "Frobenius")^2
    matrix.inner(x)

[Package fastmatrix version 0.3-819 Index]