my code (highly) modified with Burt's suggestions and the corresponding .pdf output file; these are actual openangle plots