of-matrices-and-vectors" class="section level3 unnumbered">
<h3>Arrays of Matrices and Vectors</h3>
<p>Arrays of vectors and matrices are accessed in the same way as arrays
of doubles. Consider the following vector and scalar declarations.</p>
<pre class="stan"><code>vector[5] a[3, 4];
vector[5] b[4];
vector[5] c;
real x;</code></pre>
<p>With these declarations, the following assignments are legal.</p>
<pre class="stan"><code>b = a[1];      // result is array of vectors
c = a[1, 3];    // result is vector
c