Is it Possible? - Matrix multiplication

Is it possible to extract the diagonal elements of a matrix into a vector by using matrix multiplication only? If it is possible show how ;)

I'm curious how long it will take for you guys to answer this. Btw, no element by element multiplication is allowed.

5 Comments
 

Look, I don't know how to do it in excel because I refuse to lower my standards to it, but in general

Ax = b

Take a 2-by-2 matrix A, where a_ij is the ith row and jth column element (i,j =2). Then you want b = [a_11 a_22]^T (T is the transpose). In this case,

Ax = b (A^-1)Ax = (A^-1)b

hence x = (A^-1)b

So matrix A has to be invertible. If you can find the inverse of a matrix using your software, then simply multiply this inverse matrix by the vector of diagonals to get this vector x, which you need to multiply to the vector of diagonals.

Just Do It
 
Best Response
maximumlikelihoodLook, I don't know how to do it in excel because I refuse to lower my standards to it, but in general

Ax = b

Take a 2-by-2 matrix A, where a_ij is the ith row and jth column element (i,j =2). Then you want b = [a_11 a_22]^T (T is the transpose). In this case,

Ax = b (A^-1)Ax = (A^-1)b

hence x = (A^-1)b

So matrix A has to be invertible. If you can find the inverse of a matrix using your software, then simply multiply this inverse matrix by the vector of diagonals to get this vector x, which you need to multiply to the vector of diagonals.

That's pretty much the way to do it, but in this case I am not allowed to use any 'find' commands, nor am I able to use any other commands that create a diagonal matrix (all elements besides the diagonal are zero). I am only allowed to use the multiplication of matrices, and am constrained by the number of multiplications I can perform.

 

Hic molestiae dolor exercitationem repellat est aut. Cumque omnis molestiae quo magnam id. Tempora quibusdam non et non. Dolores dolore deserunt voluptate eligendi minima dolorem tenetur.

Dolorum voluptatem non rerum eius eius perferendis. Alias quis iusto ab deleniti consequatur et eaque. Quam ratione consectetur repellat fugiat animi numquam. Facere ex sit eaque voluptatem.

Follow the shit your fellow monkeys say @shitWSOsays Life is hard, it's even harder when you're stupid - John Wayne

Career Advancement Opportunities

November 2026 Investment Banking

  • Evercore 01 99.5%
  • Moelis & Company 01 99.0%
  • JPMorgan 01 98.4%
  • Guggenheim Partners 02 97.9%
  • Morgan Stanley 06 97.4%

Overall Employee Satisfaction

November 2026 Investment Banking

  • Moelis & Company No 99.5%
  • Morgan Stanley 02 99.0%
  • Evercore 01 98.4%
  • Banco Santander 04 97.9%
  • BMO Capital Markets 13 97.4%

Professional Growth Opportunities

November 2026 Investment Banking

  • Evercore 01 99.5%
  • Moelis & Company 01 99.0%
  • Morgan Stanley 05 98.4%
  • Goldman Sachs 01 97.9%
  • JPMorgan No 97.4%

Total Avg Compensation

November 2026 Investment Banking

  • Vice President (17) $409
  • Associates (58) $261
  • 3rd+ Year Analyst (8) $210
  • 2nd Year Analyst (29) $183
  • Intern/Summer Associate (16) $161
  • 1st Year Analyst (84) $151
  • Intern/Summer Analyst (77) $101
notes
16 IB Interviews Notes

“... there’s no excuse to not take advantage of the resources out there available to you. Best value for your $ are the...”

Leaderboard

1
redever's picture
redever
99.2
2
Secyh62's picture
Secyh62
99.0
3
BankonBanking's picture
BankonBanking
99.0
4
kanon's picture
kanon
99.0
5
dosk17's picture
dosk17
98.9
6
DrApeman's picture
DrApeman
98.9
7
GameTheory's picture
GameTheory
98.9
8
Betsy Massar's picture
Betsy Massar
98.9
9
CompBanker's picture
CompBanker
98.9
10
Linda Abraham's picture
Linda Abraham
98.8
success
From 10 rejections to 1 dream investment banking internship

“... I believe it was the single biggest reason why I ended up with an offer...”