Question: hello im writing a bash script on the shell for...
I'm writing a Bash Script on the shell for matrix operations and I'm currently struggling with my multiply function. I had a working version of the function but it used a lot of temporary files, which was really slowing down on larger inputs. Therefore, I've decided to try and replace all the temporary files with variables in an effort to speed up calculation. So far, I'm only getting half of the correct answer and could really use some help figuring out what I'm doing wrong in my code.
Currently my output looks like this:
The correct output looks like this:
As you can see, it's not calculating the second half of the matrix. For some reason, I'm not multiplying the values in the second column of the second matrix.
My source code looks like this:
Any help would be appreciated! Thanks!