Are the following the formulae you refer to?
See the end of the post by Michael Gudzinowicz:
https://groups.google.com/forum/?hl=...om/zp8vBn9P8Nw