mirror of
https://bitbucket.org/Mattrixwv/matrix.git
synced 2025-12-07 07:23:58 -05:00
Update test coverage
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
//Matrix/src/main/java/com/mattrixwv/BigIntegerMatrix.java
|
||||
//Mattrixwv
|
||||
// Created: 02-10-22
|
||||
//Modified: 06-30-22
|
||||
//Modified: 06-30-23
|
||||
package com.mattrixwv.matrix;
|
||||
|
||||
|
||||
@@ -68,14 +68,14 @@ public class BigIntegerMatrix{
|
||||
}
|
||||
//Returns a matrix with the supplied row and column removed
|
||||
protected BigIntegerMatrix laplaceExpansionHelper(int row, int col){
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the matrix is large enough to have this operation performed
|
||||
if((getNumRows() <= 1) || (getNumCols() <= 1)){
|
||||
throw new InvalidGeometryException("A matrix must be at least 2x2 for you to perform Laplace Expansion: " + getNumRows() + "x" + getNumCols());
|
||||
}
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the row is valid
|
||||
if((row < 0) || (row >= getNumRows())){
|
||||
throw new InvalidCoordinatesException("An invalid row number was supplied: " + row + ". The matrix contains " + getNumRows() + " rows");
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
//Matrix/src/main/java/com/mattrixwv/matrix/DoubleMatrix.java
|
||||
//Mattrixwv
|
||||
// Created: 02-07-22
|
||||
//Modified: 06-30-22
|
||||
//Modified: 06-30-23
|
||||
package com.mattrixwv.matrix;
|
||||
|
||||
|
||||
@@ -68,14 +68,14 @@ public class DoubleMatrix{
|
||||
}
|
||||
//Returns a matrix with the supplied row and column removed
|
||||
protected DoubleMatrix laplaceExpansionHelper(int row, int col){
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the matrix is large enough to have this operation performed
|
||||
if((getNumRows() <= 1) || (getNumCols() <= 1)){
|
||||
throw new InvalidGeometryException("A matrix must be at least 2x2 for you to perform Laplace Expansion: " + getNumRows() + "x" + getNumCols());
|
||||
}
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the row is valid
|
||||
if((row < 0) || (row >= getNumRows())){
|
||||
throw new InvalidCoordinatesException("An invalid row number was supplied: " + row + ". The matrix contains " + getNumRows() + " rows");
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
//Matrix/src/main/java/com/mattrixwv/IntegerMatrix.java
|
||||
//Mattrixwv
|
||||
// Created: 02-01-22
|
||||
//Modified: 06-30-22
|
||||
//Modified: 06-30-23
|
||||
package com.mattrixwv.matrix;
|
||||
|
||||
|
||||
@@ -67,14 +67,14 @@ public class IntegerMatrix{
|
||||
}
|
||||
//Returns a matrix with the supplied row and column removed
|
||||
protected IntegerMatrix laplaceExpansionHelper(int row, int col){
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the matrix is large enough to have this operation performed
|
||||
if((getNumRows() <= 1) || (getNumCols() <= 1)){
|
||||
throw new InvalidGeometryException("A matrix must be at least 2x2 for you to perform Laplace Expansion: " + getNumRows() + "x" + getNumCols());
|
||||
}
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the row is valid
|
||||
if((row < 0) || (row >= getNumRows())){
|
||||
throw new InvalidCoordinatesException("An invalid row number was supplied: " + row + ". The matrix contains " + getNumRows() + " rows");
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
//Matrix/src/main/java/com/mattrixwv/matrix/LongMatrix.java
|
||||
//Mattrixwv
|
||||
// Created: 02-10-22
|
||||
//Modified: 07-01-22
|
||||
//Modified: 06-30-23
|
||||
package com.mattrixwv.matrix;
|
||||
|
||||
|
||||
@@ -67,14 +67,14 @@ public class LongMatrix{
|
||||
}
|
||||
//Returns a matrix with the supplied row and column removed
|
||||
protected LongMatrix laplaceExpansionHelper(int row, int col){
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the matrix is large enough to have this operation performed
|
||||
if((getNumRows() <= 1) || (getNumCols() <= 1)){
|
||||
throw new InvalidGeometryException("A matrix must be at least 2x2 for you to perform Laplace Expansion: " + getNumRows() + "x" + getNumCols());
|
||||
}
|
||||
//Make sure the matrix is square
|
||||
if(!isSquare()){
|
||||
throw new InvalidGeometryException("A matrix must be square for you to perform Laplace Expansion");
|
||||
}
|
||||
//Make sure the row is valid
|
||||
if((row < 0) || (row >= getNumRows())){
|
||||
throw new InvalidCoordinatesException("An invalid row number was supplied: " + row + ". The matrix contains " + getNumRows() + " rows");
|
||||
|
||||
Reference in New Issue
Block a user