Need to rewrite linear combination as vector expression.

devonho
Messages
8
Reaction score
0

Homework Statement


Given vectors
<br /> {\bf r}=\left[r_1,r_2,r_3\ldots{}r_n\right]^T<br />
<br /> {\bf e}=\left[e_1,e_2,e_3\ldots{}e_n\right]^T<br />

I need to write the sum

<br /> \sum_{i=1}^{n}r_ie_i^2<br />

in terms of {\bf r} and {\bf e}

Homework Equations


Nil.

The Attempt at a Solution



Without r_i, I am able to write \sum_{i=1}^{n}e_i^2 as

<br /> \sum_{i=1}^{n}e_i^2={\bf e}^T{\bf e}<br />

If r_i can be independant of i I should be able to move it out of the summation. I am looking for some expansion/reexpression of r_i.
 
Physics news on Phys.org
hi devonho! :smile:
devonho said:
I need to write the sum

<br /> \sum_{i=1}^{n}r_ie_i^2<br />

in terms of {\bf r} and {\bf e}

why?? :confused:

(i don't think you can)
 
This seems to work:

<br /> {\bf r}=<br /> \left[<br /> \begin{array}{ccccc}<br /> r_1 &amp; 0 &amp; \ldots &amp; &amp; 0\\<br /> 0 &amp; r_2 &amp; &amp; &amp; \vdots \\<br /> \vdots &amp; &amp; r_3 &amp; &amp; \\<br /> &amp; &amp; &amp; \ddots &amp; \\<br /> 0 &amp; \ldots &amp; &amp; &amp; r_n \\<br /> \end{array}<br /> \right]<br />

<br /> {\bf e}=<br /> \left[<br /> \begin{array}{c}<br /> e_1 \\<br /> e_2 \\<br /> \vdots\\<br /> e_n \\<br /> \end{array}<br /> \right]<br />

<br /> {\bf e}^T{\bf re}=\left[ e_1, e_2 \ldots e_n\right]<br /> \left[<br /> \begin{array}{ccccc}<br /> r_1 &amp; 0 &amp; \ldots &amp; &amp; 0\\<br /> 0 &amp; r_2 &amp; &amp; &amp; \vdots \\<br /> \vdots &amp; &amp; r_3 &amp; &amp; \\<br /> &amp; &amp; &amp; \ddots &amp; \\<br /> 0 &amp; \ldots &amp; &amp; &amp; r_n \\<br /> \end{array}<br /> \right]<br /> \left[<br /> \begin{array}{c}<br /> e_1 \\<br /> e_2 \\<br /> \vdots\\<br /> e_n \\<br /> \end{array}<br /> \right]<br /> =r_1e_1^2+r_2e_2^2\ldots +r_ne_n^2<br /> =\sum_{i=1}^{n}r_ie_i^2<br />
 
but devonho, how do you form that middle matrix out of the vector r ? :confused:
 
Thread 'Use greedy vertex coloring algorithm to prove the upper bound of χ'
Hi! I am struggling with the exercise I mentioned under "Homework statement". The exercise is about a specific "greedy vertex coloring algorithm". One definition (which matches what my book uses) can be found here: https://people.cs.uchicago.edu/~laci/HANDOUTS/greedycoloring.pdf Here is also a screenshot of the relevant parts of the linked PDF, i.e. the def. of the algorithm: Sadly I don't have much to show as far as a solution attempt goes, as I am stuck on how to proceed. I thought...
Back
Top