title: position number in a vector in matlab
body: <p>I have a question regarding matlab. If I have a vector v=[ 4 5 2 3 0 7]
  and I want to write an equation that include the position number of each element in the vector v. For example, I want to have the the number "1" in an equation and that number changes as I loop the vector from v(1) to v(6) so whenever I want to use the "4" in the vector v, I want a command to output number "1" because "4" is the first position(element) of V. and if I want to use "5" I want it to output a "2" because "2" is the 2nd position of V which is what "5" is at. How this make sense and can anyone help? I have only been learning matlab for a few months. thanks!</p>
  
  <p>David</p>