Useful public-domain matlab scripts and functions