hw2solution

# hw2solution - EE263 HW2 Robert Wilson [email protected]/* <![CDATA[ */!function(t,e,r,n,c,a,p){try{t=document.currentScript||function(){for(t=document.getElementsByTagName('script'),e=t.length;e--;)if(t[e].getAttribute('data-cfhash'))return t[e]}();if(t&&(c=t.previousSibling)){p=t.parentNode;if(a=c.getAttribute('data-cfemail')){for(e='',r='0x'+a.substr(0,2)|0,n=2;a.length-n;n+=2)e+='%'+('0'+('0x'+a.substr(n,2)^r).toString(16)).slice(-2);p.replaceChild(document.createTextNode(decodeURIComponent(e)),c)}p.removeChild(t)}}catch(u){}}()/* ]]> */..

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

EE263 HW2 Robert Wilson [email protected] SCPD Student October 8, 2009 Problem 1 Algorithm 1 BackSubstitution( { r ij } , { y i } ) for i = n to 1 do Set s = y i for j = n to i + 1 do Subtract r ij · x j from s end for Set x i = s/r ii end for return { x i } The algorithm BackSubstitution takes as input the elements of R and y and returns the elements of x . It starts by ﬁnding x n and works backwards (hence the name). Since y i = n j = i r ij x j and all the x j ’s are known by step i for j > i , the only unknown in the sum is the ﬁrst (diagonal) term r ii x i . We thus subtract from y i all the known terms r ij x j and divide by r ii . Since there are two loops each involving O ( n ) iterations, a single ﬂoating point operation (ﬂop) in the inner loop and a single ﬂop in the outer loop, the runtime is (1 · O ( n ) + 1) · O ( n ) = O ( n 2 ) Problem 2 Part 2a) The statement is FALSE . Part 2b) The statement is TRUE . Part 2c) The statement is FALSE . Part 2d) The statement is TRUE . 1

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

View Full Document
Robert Wilson (SCPD student) Part 2e) The statement is TRUE . Part 2f) The statement is TRUE . Part 2g) The statement is TRUE . Part 2h) The statement is TRUE . Part 2i) The statement is TRUE . Part 2j) The statement is FALSE . Problem 3 Before beginning, let’s see how far we can get without assuming anything about B . A = - 1 0 0 - 1 1 0 1 1 0 0 1 0 0 1 0 B = b 11 b 12 b 13 b 21 b 22 b 23 b 31 b 32 b 33 b 41 b 42 b 43 b 51 b 52 b 53 AB = - ( b 11 + b 41 ) + b 51 - ( b 12 + b 42 ) + b 52 - ( b 13 + b 43 ) + b 53 b 21 + b 31 b 22 + b 32 b 23 + b 33 b 11 + b 41 b 12 + b 42 b 13 + b 43 = 1 0 0 0 1 0 0 0 1 Comparing the ﬁrst and third rows, we see that, for example, b 11 + b 41 = 0 which tells us that
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 07/28/2011 for the course EE 263 taught by Professor Boyd,s during the Summer '08 term at Stanford.

### Page1 / 7

hw2solution - EE263 HW2 Robert Wilson [email protected]..

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

View Full Document
Ask a homework question - tutors are online