For regex, usage is as described at the end of the tutorial, in the section "I think I’m beginning to understand these regular expressions now... how do I use them in calibre?"
XPath instructions start here:
http://manual.calibre-ebook.com/conv...le-of-contents and link to the XPath tutorial.
For a more general and in depth explanation of the power of regexes, my favorite site remains this one:
http://www.regular-expressions.info/