Class RealFieldDenseCooMatMult
java.lang.Object
org.flag4j.linalg.ops.dense_sparse.coo.real_field_ops.RealFieldDenseCooMatMult
This class contains low level methods for computing the matrix multiplication (and matrix vector multiplication) between
a real dense/sparse matrix and a sparse/dense field matrix/vector.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends Field<T>>
voidblockedVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.static <T extends Field<T>>
voidblockedVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.static <T extends Field<T>>
voidconcurrentBlockedVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.static <T extends Field<T>>
voidconcurrentBlockedVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.static <T extends Field<T>>
voidconcurrentStandard(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandard(double[] src1, Shape shape1, T[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandard(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandard(T[] src1, Shape shape1, double[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandardVector(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandardVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandardVector(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a concurrent standard algorithm.static <T extends Field<T>>
voidconcurrentStandardVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a concurrent standard algorithm.static <T extends Field<T>>
voidstandard(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a standard algorithm.static <T extends Field<T>>
voidstandard(double[] src1, Shape shape1, T[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a standard algorithm.static <T extends Field<T>>
voidstandard(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a standard algorithm.static <T extends Field<T>>
voidstandard(T[] src1, Shape shape1, double[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a standard algorithm.static <T extends Field<T>>
voidstandardVector(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a standard algorithm.static <T extends Field<T>>
voidstandardVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a standard algorithm.static <T extends Field<T>>
voidstandardVector(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a standard algorithm.static <T extends Field<T>>
voidstandardVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a standard algorithm.
-
Method Details
-
standard
public static <T extends Field<T>> void standard(double[] src1, Shape shape1, T[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape2- Shape of the sparse matrix.dest- Array to store the dense result of the matrix multiplication.
-
standard
public static <T extends Field<T>> void standard(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a standard algorithm.- Parameters:
src1- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense matrix.shape2- Shape of the dense matrix.dest- Array to store the dense result of the matrix multiplication.
-
concurrentStandard
public static <T extends Field<T>> void concurrentStandard(double[] src1, Shape shape1, T[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a concurrent standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape2- Shape of the sparse matrix.dest- Array to store the dense result of the matrix multiplication.
-
concurrentStandard
public static <T extends Field<T>> void concurrentStandard(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a concurrent standard algorithm.- Parameters:
src1- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense matrix.shape2- Shape of the dense matrix.dest- Array to store the dense result of the matrix multiplication.
-
standard
public static <T extends Field<T>> void standard(T[] src1, Shape shape1, double[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape2- Shape of the sparse matrix.dest- Array to store the dense result of the matrix multiplication in.
-
standard
public static <T extends Field<T>> void standard(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a standard algorithm.- Parameters:
src1- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense matrix.shape2- Shape of the dense matrix.dest- Array to store the dense result of the matrix multiplication.
-
concurrentStandard
public static <T extends Field<T>> void concurrentStandard(T[] src1, Shape shape1, double[] src2, int[] rowIndices, int[] colIndices, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix and a sparse field matrix using a concurrent standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape2- Shape of the sparse matrix.dest- Array to store the dense result of the matrix multiplication.
-
concurrentStandard
public static <T extends Field<T>> void concurrentStandard(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real sparse matrix and a dense field matrix using a concurrent standard algorithm.- Parameters:
src1- Non-zero data of the sparse matrix.rowIndices- Row indices for non-zero data of the sparse matrix.colIndices- Column indices for non-zero data of the sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense matrix.shape2- Shape of the dense matrix.dest- Array to store the dense result of the matrix multiplication.
-
standardVector
public static <T extends Field<T>> void standardVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
standardVector
public static <T extends Field<T>> void standardVector(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a standard algorithm.- Parameters:
src1- Entries of the sparse matrix.rowIndices- Row indices of non-zero data in sparse matrix.colIndices- Column indices of non-zero data in sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense vector.shape2- Shape of the dense vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
blockedVector
public static <T extends Field<T>> void blockedVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
concurrentStandardVector
public static <T extends Field<T>> void concurrentStandardVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a concurrent standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
concurrentStandardVector
public static <T extends Field<T>> void concurrentStandardVector(double[] src1, int[] rowIndices, int[] colIndices, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a concurrent standard algorithm.- Parameters:
src1- Entries of the sparse matrix.rowIndices- Row indices of non-zero data in sparse matrix.colIndices- Column indices of non-zero data in sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense vector.shape2- Shape of the dense vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
concurrentBlockedVector
public static <T extends Field<T>> void concurrentBlockedVector(double[] src1, Shape shape1, T[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
standardVector
public static <T extends Field<T>> void standardVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
standardVector
public static <T extends Field<T>> void standardVector(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a standard algorithm.- Parameters:
src1- Entries of the sparse matrix.rowIndices- Row indices of non-zero data in sparse matrix.colIndices- Column indices of non-zero data in sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense vector.shape2- Shape of the dense vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
blockedVector
public static <T extends Field<T>> void blockedVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
concurrentStandardVector
public static <T extends Field<T>> void concurrentStandardVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a concurrent standard algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
concurrentStandardVector
public static <T extends Field<T>> void concurrentStandardVector(T[] src1, int[] rowIndices, int[] colIndices, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the sparse matrix dense vector multiplication using a concurrent standard algorithm.- Parameters:
src1- Entries of the sparse matrix.rowIndices- Row indices of non-zero data in sparse matrix.colIndices- Column indices of non-zero data in sparse matrix.shape1- Shape of the sparse matrix.src2- Entries of the dense vector.shape2- Shape of the dense vector.dest- Array to store the dense result of the matrix-vector multiplication.
-
concurrentBlockedVector
public static <T extends Field<T>> void concurrentBlockedVector(T[] src1, Shape shape1, double[] src2, int[] indices, T[] dest) Computes the dense matrix sparse vector multiplication using a blocked algorithm.- Parameters:
src1- Entries of the dense matrix.shape1- Shape of the dense matrix.src2- Non-zero data of the sparse vector.indices- Indices of non-zero data in sparse vector.dest- Array to store the dense result of the matrix-vector multiplication.
-