PRETTY_MAT_1_ID = PRETTY_MAT_1
PRETTY_MAT_2_ID = PRETTY_MAT_2
Is PRETTY_MAT_1_ID + OPERATION + PRETTY_MAT_2_ID defined?
ANSWER
In order for additionsubtraction of two matrices to be defined, the matrices must have the same dimensions.
If PRETTY_MAT_1_ID is of dimension (\blue m \times \red n) and PRETTY_MAT_2_ID is of dimension (\blue p \times \red q), then:
1. \blue m (number of rows in PRETTY_MAT_1_ID) must equal \blue p (number of rows in PRETTY_MAT_2_ID) and
2. \red n (number of columns in PRETTY_MAT_1_ID) must equal \red q (number of columns in PRETTY_MAT_2_ID)
for their sumdifference to be defined.
Do PRETTY_MAT_1_ID and PRETTY_MAT_2_ID have the same number of rows?
Do PRETTY_MAT_1_ID and PRETTY_MAT_2_ID have the same number of columns?
Since PRETTY_MAT_1_ID has the samedifferent dimensions (DIM_1 + "\\times" + DIM_2) asfrom PRETTY_MAT_2_ID (DIM_3 + "\\times" + DIM_4),
PRETTY_MAT_1_ID + OPERATION + PRETTY_MAT_2_ID is not defined.
In order for multiplication of two matrices to be defined, the two inner dimensions must be equal.
If the two matrices have dimensions (\blue m \times \red n) and (\red p \times \green q), then \red n (number of columns in the first matrix) must equal \red p (number of rows in the second matrix) for their product to be defined.
How many columns does the first matrix, PRETTY_MAT_1_ID, have?
How many rows does the second matrix, PRETTY_MAT_2_ID, have?
PRETTY_MAT_1_ID has the samea different number of columns (DIM_2) asthan PRETTY_MAT_2_ID has rows (DIM_3), PRETTY_MAT_1_ID + PRETTY_MAT_2_ID is not defined.