Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

small matrix question

Status
Not open for further replies.

mag2142

Electrical
Joined
Jun 23, 2009
Messages
1
Location
US
Sorry for the simplicity of this question. If I have two matrices, one 1000 cells long, the other 4.5 million long. I want to multiple them to create a third matrix 4.5 million cells long, where the first cell of the first matrix multiplies the first 4500 of the second matrix, the second of the first matrix by the next 4500 of the second matrix etc. I am using a for loop but it is taking really long, is there a faster way?
thanks
 
I'm not going to try it but you might want to try creating a 4.5 million long version of the 1000 cell matrix, then .* the two long ones together.

Don't forget the . or you will really discover what a long time is.

Cheers

Greg Locock

SIG:Please see FAQ731-376 for tips on how to make the best use of Eng-Tips.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top