Loading...
Pages: [1] 2   Go Down
Author Topic: URGENT : matrix multiplication  (Read 929 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

can anyone help me with a program that receives two square matrices from the serial interface one by one and performs matrix multiplication then resends the result matrix on the serial interface , refrences to read , or code to build up from .
Logged

UK
Offline Offline
Tesla Member
***
Karma: 89
Posts: 6388
-
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You need to receive the matrix definitions in some format, store them in memory, perform the matrix multiplication, send the resulting matrix back over the serial interface (presumably in a similar format to the received. Individually, all of these seem simple enough.

Which part of this are you having trouble with?
Logged

Austin, TX
Offline Offline
Faraday Member
**
Karma: 41
Posts: 5172
CMiYC
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

If you just need matrix multiplication, why use an Arduino at all?
Logged

www.cmiyc.com - A guide to being an Enginerd

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

unfortunatley , it's an assignment in college , and i dodn't understand what they want definitely
Logged

California
Offline Offline
Edison Member
*
Karma: 41
Posts: 1869
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Start small with Serial communication and work your way up.

I'm guessing this is URGENT because you didn't look at this until the last minute?
Logged

Austin, TX
Offline Offline
Faraday Member
**
Karma: 41
Posts: 5172
CMiYC
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

unfortunatley , it's an assignment in college , and i dodn't understand what they want definitely

So the assignment was:  "Multiple a matrix on an Arduino.  If necessary wait until the last minute and post in the forums"?
Logged

www.cmiyc.com - A guide to being an Enginerd

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

unfortunatley , it's an assignment in college , and i dodn't understand what they want definitely

So the assignment was:  "Multiple a matrix on an Arduino.  If necessary wait until the last minute and post in the forums"?

If you can help i will be thankful for you , if you can't KEEP SILENCE
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

am I wrong ?!
Logged

Austin, TX
Offline Offline
Faraday Member
**
Karma: 41
Posts: 5172
CMiYC
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

am I wrong ?!
Am I?

You still haven't said what part of your homework assignment you are having trouble with.  If your expectation is to have someone write it for you, you can stop trying now.
Logged

www.cmiyc.com - A guide to being an Enginerd

California
Offline Offline
Edison Member
*
Karma: 41
Posts: 1869
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

am I wrong ?!
Wrong about what your assignment is? How would we know?
Logged

Global Moderator
Melbourne, Australia
Offline Offline
Shannon Member
*****
Karma: 218
Posts: 13897
Lua rocks!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

http://www.lmgtfy.com/?q=matrix+multiplication+c%2B%2B
Logged


Seattle, WA
Offline Offline
God Member
*****
Karma: 4
Posts: 673
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

So the assignment was:  "Multiple a matrix on an Arduino.  If necessary wait until the last minute and post in the forums"?

Oh, you missed a part of the assignment.  It also said, "Be really snotty about it when the forum slaves don't send your assignment back completed immediately."
Logged


Austin, TX
Offline Offline
Faraday Member
**
Karma: 41
Posts: 5172
CMiYC
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh, you missed a part of the assignment.  It also said, "Be really snotty about it when the forum slaves don't send your assignment back completed immediately."
That must have been in the extra credit portion of the assignment description.
Logged

www.cmiyc.com - A guide to being an Enginerd

Netherlands
Offline Offline
Tesla Member
***
Karma: 90
Posts: 9401
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


OK serious questions:

Can you post the code you have sofar?
What did you expect?
What did you get?
What have you tried sofar?

What is the size of the square matrices? 5x5 4x4 3x3 2x2 1x1 ? 

What Arduino are you using as there are square matrices that won't fit in an UNO, you might need a MEGA for them.

Should the code include matrix X vector?

Should the code include multiplication of different size square matrices?

Should the matrix multiplication algorithm include specific optimizations or algorithms like Gauss-Jordan elimination with partial pivoting?

The members of the matrices, are these char, byte, int, long, float ?  (un)signed?

Should the code include error handling?
- in the serial communication part  (non digit input, missing bytes, checksum errors etc)
- In the math part  (overflow, underflow, divide by zero)

What are allowed baudrates for your application?

Are you familiar with the playground and tutorial sections of the Arduino where many example code snippets live?

Can you give an example of typical matrices?

In short, can you explain more about the assignment as it is not unambiguous to me yet





Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -

UK
Offline Offline
Tesla Member
***
Karma: 89
Posts: 6388
-
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

unfortunatley , it's an assignment in college , and i dodn't understand what they want definitely

I'm not sure what you mean by that, but if you don't understand your assignment you should get clarification from the person who set it.
Logged

Pages: [1] 2   Go Up
Print
 
Jump to: