title: Calculating the sum of vectors
body: <p>I have two matrices <code>a</code> and <code>b</code> and would like to calculate all the sums between them into a tensor. How can I do this more efficiently than doing the following code:</p>
  
  <pre><code>a = np.array([[1,2],[3,4],[5,6]])
  b = np.array([[4,5],[6,7]])
  
  n1 = a.shape[0]
  n2 = b.shape[0]
  f = a.shape[1]
  c = np.zeros((n1,n2,f))
  
  c = np.zeros((n1,n2,f))
  for i in range(n1):
      for j in range(n2):
          c[i,j,:] = a[i,:] + b[j,:]
  </code></pre>
  
  <p>einstein-sum and the like does obviously not work and an outer product neither - is there an appropriate method?</p>