Class RealFieldDenseMatMult
java.lang.Object
org.flag4j.linalg.ops.dense.real_field_ops.RealFieldDenseMatMult
This class contains several low level methods for computing dense matrix-matrix multiplications between one field matrix and one real matrix.
Warning: This class does not perform any sanity checks on the input.
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends Field<T>>
voidComputes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm.static <T extends Field<T>>
voidComputes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm.static <T extends Field<T>>
voidblockedReordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm with the j-k loops swapped.static <T extends Field<T>>
voidblockedReordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm with the j-k loops swapped.static <T extends Field<T>>
voidblockedVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a blocked algorithm.static <T extends Field<T>>
voidblockedVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a blocked algorithm.static <T extends Field<T>>
voidconcurrentBlocked(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm.static <T extends Field<T>>
voidconcurrentBlocked(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm.static <T extends Field<T>>
voidconcurrentBlockedReordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm with the j-k loops swapped.static <T extends Field<T>>
voidconcurrentBlockedReordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm with the j-k loops swapped.static <T extends Field<T>>
voidconcurrentBlockedVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of a blocked algorithm.static <T extends Field<T>>
voidconcurrentBlockedVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of a blocked algorithm.static <T extends Field<T>>
voidconcurrentReordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm with j-k loops swapped.static <T extends Field<T>>
voidconcurrentReordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm with j-k loops swapped.static <T extends Field<T>>
voidconcurrentStandard(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm.static <T extends Field<T>>
voidconcurrentStandard(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm.static <T extends Field<T>>
voidconcurrentStandardVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of the standard matrix multiplication algorithm.static <T extends Field<T>>
voidconcurrentStandardVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of the standard matrix multiplication algorithm.static <T extends Field<T>>
voidComputes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm with j-k loops swapped.static <T extends Field<T>>
voidComputes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm with j-k loops swapped.static <T extends Field<T>>
voidComputes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm.static <T extends Field<T>>
voidComputes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm.static <T extends Field<T>>
voidstandardVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using the standard algorithm.static <T extends Field<T>>
voidstandardVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using the standard algorithm.
-
Method Details
-
standard
public static <T extends Field<T>> void standard(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
reordered
public static <T extends Field<T>> void reordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm with j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
blocked
public static <T extends Field<T>> void blocked(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
blockedReordered
public static <T extends Field<T>> void blockedReordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm with the j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentStandard
public static <T extends Field<T>> void concurrentStandard(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentReordered
public static <T extends Field<T>> void concurrentReordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm with j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentBlocked
public static <T extends Field<T>> void concurrentBlocked(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentBlockedReordered
public static <T extends Field<T>> void concurrentBlockedReordered(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm with the j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
standardVector
public static <T extends Field<T>> void standardVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using the standard algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
blockedVector
public static <T extends Field<T>> void blockedVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
concurrentStandardVector
public static <T extends Field<T>> void concurrentStandardVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of the standard matrix multiplication algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
concurrentBlockedVector
public static <T extends Field<T>> void concurrentBlockedVector(double[] src1, Shape shape1, T[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
standard
public static <T extends Field<T>> void standard(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
reordered
public static <T extends Field<T>> void reordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication between a real dense matrix with a dense field matrix using the standard algorithm with j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
blocked
public static <T extends Field<T>> void blocked(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
blockedReordered
public static <T extends Field<T>> void blockedReordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a blocked algorithm with the j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentStandard
public static <T extends Field<T>> void concurrentStandard(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentReordered
public static <T extends Field<T>> void concurrentReordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of the standard matrix multiplication algorithm with j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentBlocked
public static <T extends Field<T>> void concurrentBlocked(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
concurrentBlockedReordered
public static <T extends Field<T>> void concurrentBlockedReordered(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the matrix multiplication of a real dense matrix with a dense field matrix using a concurrent implementation of a blocked algorithm with the j-k loops swapped.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix multiplication in (modified). Must have size lengthshape1.get(0)*shape2.get(1).
-
standardVector
public static <T extends Field<T>> void standardVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using the standard algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
blockedVector
public static <T extends Field<T>> void blockedVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
concurrentStandardVector
public static <T extends Field<T>> void concurrentStandardVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of the standard matrix multiplication algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-
concurrentBlockedVector
public static <T extends Field<T>> void concurrentBlockedVector(T[] src1, Shape shape1, double[] src2, Shape shape2, T[] dest) Computes the multiplication of a real dense matrix with a dense field vector using a concurrent implementation of a blocked algorithm.- Parameters:
src1- Entries of the first matrix.shape1- Shape of the first matrix.src2- Entries of the second matrix.shape2- Shape fo the second matrix.dest- Array to store result of the matrix-vector multiplication in (modified). Must have size lengthshape1.get(0)].
-