MATLAB: Multiply table and matrix multiply how can i multiply these example? A= {[0.2 0.5 0.3] [ 0.1 0.1 0.3]} A=cell2table(A) B=[ 2 3] A*B must be {[0.4 1 0.6] [0.3 0.3 0.9]} Best Answer I prefer Adam's method :although if you want to multiply table with matrix then=>arrayfun(@(x) A{:,x}*B(x),1:numel(B),'un',0) Related SolutionsMATLAB: Find a submatrix in a matrix https://in.mathworks.com/matlabcentral/answers/395258-most-efficent-way-of-finding-submatrices-of-a-matrixhttps://in.mathworks.com/matlabcentral/answers/286890-how-do-i-find-the-submatrix-of-a-matrix MATLAB: Get a three column matrix from meshgrid data Add one line: x=linspace(0.1,0.3,3);y=linspace(1,3,3);[x1,y1] = meshgrid(x,y);z=x1.*y1;C = [x1(:), y1(:), z(:)] to produce: C = 0.1 1 0.1 0.1 2 0.2 0.1 3 0.3 0.2 1 0.2 0.2 2 0.4 0.2 3 0.6 0.3 1 0.3 0.3 2 0.6 0.3 3 0.9The ‘(:)’ subscripting convention forces a column vector. Related QuestionHow to find the index of first and last nonzero elements in each columnCalling text file in matlabHow to generate 100 sample points of a 3-state Markov chain with initial prob vector and transition probability matrix using inverse transform method on matlab.Block diagonal matrix on lower diagonals
Best Answer