The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: Matrix dimensions
Replies: 2   Last Post: Feb 21, 2014 9:58 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 9,850
Registered: 6/7/07
Re: Matrix dimensions
Posted: Feb 21, 2014 9:58 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

On 2/21/2014 7:19 AM, gasmi wrote:
> Hi,
> when I run my code this error appears "??? Error using ==> plus Matrix
> dimensions must agree.
> Error in ==> code at 29
> y = yppm + 10^(-Eb_N0_dB(ii)/20)*n;"
> knowing that;
> yppm <1*2101 double>
> Eb_N0_dB <1*14 double>
> ii 1
> n <1*100000 double>
> please I need your helps and I'll be gratful.

Well, with such disparate sizes I don't know what you expect to be able
to can't very well expect Matlab to know what to do when you
try to add 14 values to some 2000 and then multiply those by 100000 others.

Also note that '*' is a matrix multiply, not element-wise. Need the
"dot" operators .* and the like for that.

But, you're going to have to somehow get the dimensions commensurate to
get anywhere. Only you can know what those should be for your problem.


Date Subject Author
Read Matrix dimensions
Read Re: Matrix dimensions
Read Re: Matrix dimensions

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.