Here is a class that solves linear equation system with LU-decomposition algorithmus. I got the error message when ran it:
Please enter an integer as the size of the matrix:
5
java.lang.ArrayIndex OutOfBoundsException: 5
at NB2A71.main(NB2A71.java:31)
Press any key to continue...
The source code is as following:
In this program, the initial values of a[i][j] and b[i] are specified here:
How should I modify the code so that it can run? Thank you very much in advance!