What I want to do is to take a 2d int array and use it to create a Matrix (a class I will be defining) which will effectively wrap all the values of the 2d array together so that I can perform matrix multiplication for coordinate translation. I am rather confused as to how I would do this however. My main problem that I can't figure out is that how can I create the Matrix object so that I can still access specific value at a row and column location (since it won't be an 2d array anymore I can't go something like 'matrix[i][j]')? Anybody have any ideas, or am I approaching this completely wrong?
DEAD TERMINATOR
0
Newbie Poster
Recommended Answers
Jump to Postit won't be an 2d array anymore I can't go something like 'matrix[i][j]')? Anybody have any ideas, or am I approaching this completely wrong?
While in other languages such as C# or C++ you have operator overloading, there's no such feature in Java.
Your best bet is creating …
All 3 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.