squarefree decomposition in special cases