final tentative version of compare_udmz.php