Home » excel » excel – Evaluating two Index, Match, Match functions for boolean result, does not seem to be working

excel – Evaluating two Index, Match, Match functions for boolean result, does not seem to be working

Posted by: admin May 14, 2020 Leave a comment

Questions:

Picture of sample data

I have been trying to get this function to work but cant seem to get the correct result. What I am trying to accomplish is to Index Match Match a cell from the second table to the first table and evaluate the first set of coordinates, lets say (a,c) , with another set of coordinates (c,a). I will always be evaluating the inverse of each others coordinate. If all goes correctly, the two points in this example are -4 and 4. If the two coordiantes match eachothers inverse then True, otherwise False. I think I set up my function correctly but I cant seem to find the issue with it.

=(INDEX($B$2:$F$6,MATCH($A14,$A$2:$A$6,0),MATCH(B$13,$B$1:$F$1,0)))=(-(INDEX($B$2:$F$6,MATCH($A14,$B$1:$F$1,0),MATCH(B$13,$A$2:$A$6,0))))
How to&Answers:

Try this formula:

=B2=-INDEX($B$2:$F$6,MATCH(B$1,$B$1:$F$1,0),MATCH($A2,$A$2:$A$6,0))

I think you just mixed up your rows and columns. Also, you don’t need the first INDEX, you can just refer to the cell

Example (note I changed one value just to make sure it is working):

enter image description here

Answer:

If it is always a square matrix, and you don’t mind entering it as a single array formula, you could use TRANSPOSE. Enter this in a 5 x 5 area and commit with ctrl+shift+enter:

=-B2:F6=TRANSPOSE(B2:F6)