Guest User

Untitled

a guest
Feb 20th, 2017
129
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. In[67]:= pts = First[poly];
  2.  
  3. In[68]:= offset = First@Ordering[pts[[All, 2]], 1]
  4.  
  5. Out[68]= 62
  6.  
  7. In[69]:= rpts = RotateLeft[pts, offset - 1];
  8.  
  9. In[71]:= split = First@Ordering[rpts[[All, 2]], -1]
  10.  
  11. Out[71]= 370
  12.  
  13. In[89]:= newpts =
  14. Rest@SimplifyLine[rpts[[;; split]], 0.02]~Join~
  15. Rest@SimplifyLine[rpts[[split ;;]]~Append~First[rpts], 0.03];
  16.  
  17. In[90]:= Graphics@{EdgeForm[Black], FaceForm[None], Polygon[newpts],
  18. Point[newpts]}
RAW Paste Data