Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

3. The following Table (next page) is commonly used in the fields of Strength of

ID: 3749048 • Letter: 3

Question

3. The following Table (next page) is commonly used in the fields of Strength of Materials, Steel Structures, and Mechanical Design. The blue highlighted part of the table is already defined and saved in array named T15_9 with few mistakes marked with red below. Use the provided script file to complete your solution for this problem. Use array indexing and relevant MATLAB features to perform the following: a. Correct the values marked with red in T15_9 using proper indexing commands. Do NOT just re- b. Find the number of beams listed on T15 9 (Use single command to find ONLY the number of c. Use single command to find ONLY the number of columns in T15 9 and save it as T cols define the variable T15 9. rows of T15_9) and save it as T_rows d. Use the proper indexing commands to extract the columns that include only areas and e. Use the proper indexing commands to extract the columns that include only the properties of f. Use the proper indexing commands to extract the Depth column from T15 9 and save it as d. dimensions of the sections (the first 5 columns) and save them to the variable T15 9 dim. the sections (the last 2 columns) and save them to the variable T15_9_prop. g. Use the proper indexing commands to extract the Web thickness column from T15_9 and save h. Calculate the web area, A , which is the result of multiplying the Depth value by the i. Use sprintf to print the values of the web area and moment of inertia of the 3d section (3 itas t corresponding Web thickness for each thickness. (Ad, xt row: W21x73) by using proper indexing for A and T159 to fill the placeholders in the text Output: Section W21x73 has web area o·.** ina2 dnd a nonent of inertia of n°4 Create one column vector/array, w1, for the first number in the section Designation (i.e. 24, 24, 21, 21, 18) and another column vector, w2, for the second number in the Designation (ie. 76, 68, 73, 57, 55) and use them to produce an output statement indicating the section designation of the 3 section and its web area similar to the following j. See the posted sample script Grades Array Exercise.m for similar output statement. Write a similar output statement (just one fprintf command) that will display a series of formatted text showing section designation and web area for all sections appearing in T15_9 See the posted sample script Grades Array Exercise.m for similar output statement. Use proper indexing command to expand the variable T15_9 by adding the row highlighted in green below (for section W18x40). Do NOT just type the new value in the original definition of T15 9 k. I.

Explanation / Answer

% ET 202 HW 02
% Name
% Date
% Strength of Materials / Steel Table

clear
format compact; format short g
% Table T15_9 is defined below wiith some mistakkes.
% Run the file then use proper indexing commands to correct the mistakes
% Do NOT just re-type the incorrect values.

T15_9=[
22.4 23.92 0.440 9.880 0.680 2100 176
20.1 23.73 0.415 8.965 0.585 1830 154
21.5 24.21 0.554 8.295 0.740 6100 151
16.7 21.06 0.405 5.666 0.650 1170 111
16.2 18.11 0.390 7.530 0.630 890 98.3];

% Part a
% Use a proper commands to modify the incorrect elements in the table (Do
% not just re-define the varible T15_9)

T15_9(1, 4)=8.990;
T15_9(3, 2)=21.24;
T15_9(3, 3)=0.455;
T15_9(3, 6)=1600;
T15_9(4, 4)=6.555;
  
% Results for part a (copy from command window)

% Part b
% Use single command to find ONLY the number of rows of the given variable
% and save it to the variable T_row
t=size(T15_9);
T_rows=t(1);

% c. Use single command to find ONLY the number of clumns of the given
% variable and save it to the variable T_col
T_cols=t(2);

% d. Use a proper indexing command to extract the columns that includes only
% the dimensions of the sections (the first five columns) and save them to
% a to the variable T15_9_dim

T15_9_dim=T15_9(:, 1:5);


% e. Use a proper indexing command to extract the columns that includes only
% the properties of the sections (the last two columns) and save them to
% a to the variable T15_9_prop
T15_9_prop=T15_9(:, 6:7);


% f. Use a proper indexing command to extract the depth column and save it
% to the variable d
d=T15_9(:, 2);
% g. Use a proper indexing command to extract the web thickness column and
% save it to the variable t_w
t_w=T15_9(:, 3);

% h. Create a new variable for the web area, A_w, which results from
% multiplying each depth value by its corressponding web thickness value
% (A_w_i = d_i * t_w_i)
A_w=[];
for i=1:length(d)
A_w(1)=d(i)*t_w(i);
end

% i. Use the fprintf to print the values of the 3rd section web area and
% moment of inertia that appear as:
% 'The web area of the 3rd section (W21x73) is ####.## in^2 and the moment
% of inertia is ####.## in^4'
fprintf('the web area of the 3rd section (W21x73) is %.3 in^2 and the moment of inertia is %.3f ', T15_9(3, 1), T15_9(3, 6))
% j and k
area=T15_9(:, 1);
w1=[24 24 21 21 18];
w2=[76 68 73 57 55];
for i=1:length(area)
fprintf('The web area of section W%.0fx%.0f is %.3f ', w1(i), w2(i), area(i))
end
% l. Expand the variable T15_9 by adding an extra row (data for W18x40) using
% a proper indexing command. Do not just add the values in the original
% variable definition above
T_newRow=[11.8 17.90 0.315 6.015 0.525 612 68.4];
T15_9(6, :)=T_newRow;

Note : If A is an array/vector in Matlab, just use A(row, col) to access its elements, also for other modifications such as replacing its elements, adding new rows.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote