Uploading some scripts I wrote for this

My code is embarrassingly bad, but, for the sake of completeness, here it is.