In Java which is faster note that I don’t need the flexibility of (remove, add)in Big O thing. But I certainly need the Access Big O.
The operation is only to multiply 2 matrices or subtract, add etc..
Also note that the array is primitive.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
double[][]is much more memory efficient than using ArrayLists and Double. It will use a fraction of the memory meaning you will get better caching behaviour. Also thedoubleindouble[]will be continuous in memory, also improving cache performance.BTW:
Doublemay be rather randomly arranged in memory and there for the cache.