P: 7

hai everyone, i would like someone to help me with a c++ program that adds, subtracts and multiply matrices
 
Share this Question
Expert Mod 2.5K+
P: 4,677

hai everyone, i would like some to help me with a c++ program that adds, subtracts and multiply matrices
Sure, what do you have so far?
 
P: 7

Sure, what do you have so far?
im still confused, i only have a program that displays the matrix
  Expert Mod 2.5K+
P: 4,677

im still confused, i only have a program that displays the matrix
Ok, well, then lets start with just the addition part.
Do you know how you would add two matricies by hand?
 
P: 7

Ok, well, then lets start with just the addition part.
Do you know how you would add two matricies by hand?
The problem is, i am not doing applied maths or anything that does matrices and i think thats where the problem is
  Expert Mod 2.5K+
P: 4,677

That's still okay  you can figure this stuff out, you just need to have an idea of what you are doing when you code, or else you're not going to be able to get started.
I approached it this way: http://www.google.com/search?hl=en&q...=Google+Search
A Google search. So look through those. It seems pretty straightforward.
 
P: 7

[quote=luvuyo]The problem is, i am not doing applied maths or anything that does matrices and i think thats where the problem is
so, will you please help me
  Expert Mod 2.5K+
P: 4,677

The problem is, i am not doing applied maths or anything that does matrices and i think thats where the problem is
so, will you please help me
That's what I'm trying to do. Did you look through those links and do you understand how to do matrix addition? Next we have to build an algorithm, and then you can code. But it starts with you understanding how matrix addition works. Then once we do that, you can do the subtraction and multiplication on your own.
 
P: 7

Ok, well, then lets start with just the addition part.
Do you know how you would add two matricies by hand?
The problem is, i am not doing applied maths or anything that does matrices and i think thats where the problem is
  Expert Mod 2.5K+
P: 4,677

That's still okay  you can figure this stuff out, you just need to have an idea of what you are doing when you code, or else you're not going to be able to get started.
I approached it this way: http://www.google.com/search?hl=en&q...=Google+Search
A Google search. So look through those. It seems pretty straightforward.
Click on the link. Read a few of the returns about matrix multiplication. If you can do regular multiplication, you can do matrix multiplication.
 
P: 7

now i understand the addition part, but still no idea of writing a code that adds the matrices
  Expert Mod 2.5K+
P: 4,677

now i understand the addition part, but still no idea of writing a code that adds the matrices
We're building up to that. You can't just jump in and start coding  that gets you lost. It's like traveling, you need a map. Sometimes you can just take off and end up in the right place, but you're likely to make a few wrong turns, and not end up where you wanted to go.
So, our "map" is our algorithm. Are the matricies you are going to be working with of a fixed size? (ie always going to be 4x4 or 5x5) Or are they going to change?
 
P: 7

We're building up to that. You can't just jump in and start coding  that gets you lost. It's like traveling, you need a map. Sometimes you can just take off and end up in the right place, but you're likely to make a few wrong turns, and not end up where you wanted to go.
So, our "map" is our algorithm. Are the matricies you are going to be working with of a fixed size? (ie always going to be 4x4 or 5x5) Or are they going to change?
They are going to changes sir
  Expert Mod 2.5K+
P: 4,677

They are going to changes sir
Ok, do you know how they will be read in? Will they be passed in an array, read from a file, entered in command line, etc...?
    Question stats  viewed: 1249
 replies: 13
 date asked: Aug 20 '07
