title: Creating 3rd order tensors with python and numpy
body: <p>I have a two 1 dimensional arrays, <code>a</code> such that <code>np.shape(a) == (n,)</code> and <code>b</code> such that <code>np.shape(b) == (m,)</code>.</p>
  
  <p>I <strong>want</strong> to make a (3rd order) tensor <code>c</code> such that <code>np.shape(c) == (n,n,m,)</code>by doing <code>c = np.outer(np.outer(a,a),b)</code>.</p>
  
  <p>But when I do this, I get:</p>
  
  <pre><code>&gt;&gt; np.shape(c) 
  
  (n*n,m)   
  </code></pre>
  
  <p>which is just a rectangular matrix. How can I make a 3D tensor like I want?</p>