{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Data Str & Algorithm HW Solutions 89

Data Str & Algorithm HW Solutions 89 - − 1 X i =0...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
89 14.3 From Equation 2.2 we know that n i =1 i 2 = 2 n 3 + 3 n 2 + n 6 . Thus, when summing the range a i b , we get b i = a i 2 = 2 b 3 + 3 b 2 + b 6 2 a 3 + 3 a 2 + a 6 = 2( b 3 a 3 ) + 3( b 2 a 2 ) + ( b a ) 6 . 14.4 We need to do some rearranging of the summation to get something to work with. Start with n i =1 i 2 = n i =1 ( i + 1 1) 2 . Substituting i for i 1 , we get n i =1 i 2 = n 1 i =0 ( i + 1)
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: − 1 X i =0 ( i 2 + 2 i + 1) . The i 2 terms mostly cancel, leaving n 2 = n − 1 X i =0 (2 i + 1) = 2 n − 1 X i =0 i + n. n 2 − n 2 = n − 1 X i =0 i Substituting back i − 1 for i , we get n X i =1 = n 2 + n 2 ....
View Full Document

{[ snackBarMessage ]}