math library for kdb+ (legacy versions)