Package jline.lib.fjcodes
Class FjCodesUtils
java.lang.Object
jline.lib.fjcodes.FjCodesUtils
FJ_codes utility helpers: the free functions of the FJ_codes port, collected
as static methods on a non-instantiable holder.
-
Method Summary
Modifier and TypeMethodDescriptionstatic Matrixbuild_index(int m, int cr) Build combinatorial index patterns: enumerate all ways to distributecritems intombins.static double[]getRowAsArray(Matrix matrix, int row) Extract rowrowofmatrixas adouble[].static MatrixCompute Kronecker sum of two matrices: A xor B = A x I + I x B.static voidsetSubMatrix(Matrix target, int startRow, int startCol, Matrix source) Copysourceintotargetstarting at the given (0-based) row/column position.static intFind the 1-based index of the row inmatrixthat matchesrowelementwise (within 1e-10), or -1 if no row matches.
-
Method Details
-
kronsum
Compute Kronecker sum of two matrices: A xor B = A x I + I x B. -
vectmatch
Find the 1-based index of the row inmatrixthat matchesrowelementwise (within 1e-10), or -1 if no row matches. -
build_index
Build combinatorial index patterns: enumerate all ways to distributecritems intombins. Each row of the returned matrix is one distribution pattern. -
getRowAsArray
Extract rowrowofmatrixas adouble[]. -
setSubMatrix
Copysourceintotargetstarting at the given (0-based) row/column position.
-