title: How to add vectors with different length?
body: <p>I would like to add two vectors with different lengths in Matlab or Octave. E.g.</p>
  
  <pre><code>aa = [1 2 3 4];
  bb = [100 100];
  </code></pre>
  
  <p>Which should result in a vector cc containing</p>
  
  <pre><code>cc = [101 102 3 4]
  </code></pre>
  
  <p>Can anyone figure out how to do this?</p>
  
  <p>Update: This is the code I ended up with for the signals that I then later convert to grey scale images.</p>
  
  <pre><code>load train;
  t = y;
  load chirp;
  c = y;
  
  tc = c + [t; zeros(length(c) - length(t),1)];
  
  plot(1:length(tc),tc)
  </code></pre>
  
  <p>Thank you very much to you all =)</p>