Lets said I have the matrix M = ones(3);
and I want to divide each row by a different number, e.g., C = [1;2;3];
.
1 1 1 -divide_by-> 1 1 1 1
1 1 1 -divide_by-> 2 = 0.5 0.5 0.5
1 1 1 -divide_by-> 3 0.3 0.3 0.3
How can I do this without using loops?