Although a blank line is required before and after a matrix, in a case like this, where you are creating a spatial fraction, it is better to keep the matrix close to the fraction line. If you insert a blank line, the matrix seems to no longer be part of the fraction. (It is possible to do this matrix fraction with a linear fraction line between the two matrices. However, this does not convey the concept as efficiently as does the spatial fraction.) I would leave no blank lines between the denominator and numerator and the horizontal fraction line.