I would like to know how A through K on the 1st picture and
I would like to know how A through K on the 1st picture and then A through F on the second picture are typed up in MatLab. Also please provide solution. Please and thank you if somone can help.
Problem 1) Create the following matrix in MATLAB, 3 7 4 12 5 9 10 2 6 13 8 11 15 4 a Create a vector v consisting of the elements in the second column of A b) Create a vector w consisting of the elements in the second row of A c) Create a 4 x 3 array B consisting of all elements in the second through fourth columns of A d Create a 3 x 4 array C consisting of all elements in the second through fourth rows of A e) Create a 2x3 array D consisting of all elements in the first two rows and the last three columns of A. Find the maximum and minimum of each column of A g) the maximum and minimum of each row of A h) Sort each column and store the result in an array B i) Sort each row and store the result in an array C j) Add each column and store in an array D k) Add each row and store in an array F L2 26Solution
clc
clear all
A=[3 7 -4 12
-5 9 10 2
6 13 8 11
15 5 4 1 ]
v=A(1:4,2) %a)Vector v
w=A(2,1:4) %b)vector w
B=A(1:4,2:4) %c)array B
C=A(2:4,1:4) %d)array C
D=A(1:2,2:4) %e)array D
max(A) %f)maximum of each colomns of A
min(A) %manimum of each colomns of A
(max(A\'))\' %g)maximum of each rows of A
(min(A\'))\' %manimum of each rows of A
B=sort(A) %h)sorted columns
C=(sort(A\'))\' %i)sorted rows
D=sum(A) %j)colums sum
F=(sum(A\'))\' %k)rows sum
%second picture solutions
max(A) %a)maximum of each colomns of A
min(A) %manimum of each colomns of A
(max(A\'))\' %b)maximum of each rows of A
(min(A\'))\' %manimum of each rows of A
B=sort(A) %c)sorted columns
C=(sort(A\'))\' %d)sorted rows
D=sum(A) %e)colums sum
E=(sum(A\'))\' %f)rows sum
