The ns2 namespace is registered to the products node, so you need to call the products node's lookupNamespaceURI method. This is ugly but it does the trick:
$xpath->registerNamespace('ns', $domDoc->documentElement->lookupNamespaceURI(NULL));
$productNode = $xpath->query("/ns:GetMatchingProductForIdResponse/ns:GetMatchingProductForIdResult/ns:Products")->item(0);
$xpath->registerNamespace('n2', $productNode->lookupNamespaceURI('ns2'));