The matrix is the quantifier-free part of a formula after it's converted to prenex normal form. It's the core propositional…