matrix form using dimension 1 & dimension 2 (Purchase Line)

How to make a report , from purchase line

and then i want to make matrix form using… dimension 1 and dimension 2

so the report it will be like this

dimension 1 (1st) dimension 1(2nd) dimension 1(3rd)

dimension 2 (1st) 0 10 9

dimension 2 (2nd) 8 25 0

dimension 2 (3rd) 7 0 10