<p>I have these 2 vectors:</p>

<pre><code>alpha =
     1    1    1    1    1    1    1    1    1

f_uv =
   193  193  194  192  193  193  190  189  191
</code></pre>

<p>And when I do this:</p>

<pre><code>alphaf_uv = alpha * f_uv'
</code></pre>

<p>I get the error message:</p>

<pre><code>"??? Error using ==&gt; mtimes
Integers can only be combined with integers of the same class, or scalar doubles." 
</code></pre>

<p>The interesting part is that this error doesn't appear if I define the same vectors in the console and try the multiplication there.</p>

<p><code>alpha</code> is defined by me and <code>f_uv</code> is obtained from some pixels in a PNG image.</p>

Assuming they're both integer matrices to begin with,
```
f_uv'
```
may not be.
Try:
```
```
alphaf_uv = double(alpha) * double(f_uv')
```
```
and let us know if it still occurs.
You may need to turn
```
alphaf_uv
```
back into an integer type afterwards, depending on your needs.