Lecture 03 Presentation

# Lecture 03 Presentation - 14:440:127 Introduction to...

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

14:440:127 Introduction to Computers for Engineers Lecture 3 LEASE TAKE LECTURE 3 NOTES PLEASE TAKE LECTURE 3 NOTES AS YOU ENTER THE ROOM! Lecturer: Blase E. Ur Recitation Instructor: Bocheng ‘Bo’ Jin Recitation Instructor: Cyrus Gerami Recitation Instructor: Vishnu Vijayakumar Recitation Instructor: Wen Yueh

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

View Full Document
14:440:127 Lecture 3 Sum and Product Sum, Prod sum([ 3 5 7 ]) A = [ 2 4 3 ] [ 3 2 6 ] sum(A) gives you [ 5 6 9 ] sum(sum(A)) gives you 20
14:440:127 Lecture 3 Maximum and Minimum max([ 4 6 5]) Ans = 6 [val loc] = max([4 6 5]) val = 6, loc = 2 % value and location of the maximum A = [ 2 4 6 ] [ 3 8 3 ] [b1 b2] = min(A); b1 = [2 4 3] b2 = [1 1 2]

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

View Full Document
14:440:127 Lecture 3 Finding the Min and Location V = [ 5 7 9 ] [ 6 3 2 ] [ 2 1 3 ] [smallC,rowsC] = min(V) [small0,column] = min(smallC) row = rowsC(column)
14:440:127 Lecture 3 Matrix Functions • Mean- Average (add numbers in column, divide by # elements) • Median- The middle number if you order them • mean(mean(M)) finds the average of M • median(median(M)) does NOT find the median of M – Use median(M(:)) A = [ 1 5 ; 7 9 ] A = [ 1 5 ] [ 7 9 ] B = A(:) B = [ 1; 7; 5; 9 ]

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

View Full Document
14:440:127 Lecture 3 Sort, Sortrows Operate by column V = [ 7 6 4 ] [ 5 3 9 ] [ 8 4 5 ] Sortrows is like alphabetizing flipud( ) b flip matrix up to down fliplr( ) b flip matrix left to right
14:440:127 Lecture 3 Transpose Switches rows and columns A = [ 1 5 ; 7 9 ] A = [ 1 5 ] [ 7 9 ] A' ans =[ 1 7 ] [ 5 9 ] transpose(A) ans =[ 1 7 ] [ 5 9 ]

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

View Full Document
14:440:127 Lecture 3 Actually Sorting Rows transpose(sort(transpose(M))) %option 1 OR sort(M')' %option 2
14:440:127 Lecture 3 Calculating Determinants A = [ 1 5 ; 7 9 ] A = [ 1 5 ] [ 7 9 ] det(A) ans = -26 If the determinant is 0, no inverse

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

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 01/11/2010 for the course 440 127 taught by Professor Blase during the Fall '09 term at Rutgers.

### Page1 / 33

Lecture 03 Presentation - 14:440:127 Introduction to...

This preview shows document pages 1 - 10. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online