modified square-free