Initial commit of functions from github.com/btracey/optimize

Add blank line after.