XPath is for selection, not for transformation. (XSLT is for transformation.)
You can select div
elements that do not contain certain a
elements only if the div
elements already exist in the input document; you cannot select div
elements and then remove child elements once selected.