New function _matching_variables