MATLAB: Matlab matrix with specific elements MATLABmatlab functionmatrix i want to create an m by n matricx and its elements are write by this firmula a(i, j) = (j − 4)2 (i + 1)−3 + ij where i is the row number and j is the column number? Best Answer assume that i is from 1 to 5 and j is from 1 to 6:% i: 1 to 5% j: 1 to 6 [i,j] = meshgrid(1:5,1:6);a=2*(j-4).*(i+1)-3+i.*j;disp(a) Related SolutionsMATLAB: How do you create a matrix Aij where each value is determined by a formula [I,J] = ndgrid(1:2,1:2);(-1).^(I+J) MATLAB: How to create it A bit more efficiently, using meshgrid:[i,j] = meshgrid(1:5);a = 2*cos(0.4*(i-j)*pi); Related QuestionHi, I want to calculate the LST equationt. I get the following error: Subscript indices must either be real positive integers or logicals. can someone helpTransform column and row data of logical matrix to vector(N X 2)How can i show the multiplication table in the command window without showing the zeros
Best Answer