HW3_ENED1091_WINTER_2018 (1).docx

# HW3_ENED1091_WINTER_2018 (1).docx - ENED 1091 Homework...

• 7
• 100% (2) 2 out of 2 people found this document helpful

This preview shows pages 1–3. Sign up to view the full content.

ENED 1091: Homework Assignment #3 Due: Week of February 5 th at the beginning of your Recitation Section Problem 1 : (Min and Max Functions) Create the following matrix in MATLAB: M = 3 4 0 -3 3 0 -1 -1 3 -3 5 4 -3 -3 -2 For each of the following, use the max or min functions. Paste both the command and the result in the space below. (a) What MATLAB command would determine the largest value in the entire matrix? MATLAB Command and Results: max(max(M) 5 (b) What MATLAB command would determine the smallest value in each of the columns? MATLAB Command and Results: Min(M) -3 -3 -2 (c) What MATLAB command would determine the smallest value in each of the rows? MATLAB Command and Results: min(M,[],2) 0 -3 -1 -3 -3 (d) What MATLAB command would determine the smallest value in column 2? MATLAB Command and Results: min(min(M,[],2)) -3 (e) What MATLAB command would determine the largest value in rows 3 & 4? (Note: we want a single value here not a maximum for each row) MATLAB Command and Results: Problem 2 : (Sum Function) Create the following matrix in MATLAB (same as Problem 1): M = 3 4 0 -3 3 0 -1 -1 3

This preview has intentionally blurred sections. Sign up to view the full version.

-3 5 4 -3 -3 -2 (a) Use the sum function to add all of the entries in matrix M. MATLAB Command and Results: Sum(sum(M)) 10 (b) Use the sum function to determine the sum of each column.
This is the end of the preview. Sign up to access the rest of the document.
• Spring '14
• Fernandez

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern