Generic utilities used in the course of my research