Say you have a 2D matrix,Is there a particular algorithm or way to do this in excel or matlab that would find the max of each row and column, such that each column and each row has only one maximal number N, where summing all N would result in the largest possible sum,i.e. is a row or column has a max number that is repeated., as such with the simple example below
1 2 4
3 1 4
1 2 4
the out put would be
1 2 4
3 2 4
1 2 4