On the trees associated to plane curve singularities and ideals A homological criterion for reducibility of analytic spaces, with application to characterizing the theta divisor of a product of two general principally polarized abelian varieties 