
b = c; // illegal assignment of row vector to column vector
c = b; // illegal assignment of column vector to row vector</code></pre>
</div>
<div id="mixing-matrices-and-arrays" class="section level4 unnumbered">
<h4>Mixing matrices and arrays</h4>
<p>The same holds for matrices, where 2-dimensional arrays may not be
assigned to matrices or vice-versa.</p>
<pre class="stan"><code>array[3, 4] real a;
matrix[3, 4] b;
// ...
a = b;  // illegal assignment of matrix to array
b = a;  // illegal assignment of arra