Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I had this question on a homework and I was wondering if my thinking was correct.

if you have a nxn matrix, how many total arithmetic operations do you perform? ( +,-, *, /)...I went about this saying that first you must perform n number of operations on the first row then n number of operations on the remaining rows. So, I got n^2. But I am not exactly sure if this is the way to go about it and I was wondering if this was the same as two nested for-loops going through a 2d array.

share|cite|improve this question
up vote 1 down vote accepted

Hint: One can compute the inverse of an $n\times n$ non-singular matrix using Gauss-Jordan elimination. What is the op-count of Gauss-Jordan elimination?

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.