home.social

#2optswap — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #2optswap, aggregated by home.social.

  1. Comparing a naive "nearest neighbor" #TravellingSalesmanProblem solver with a #2optSwap one, adding a #DelaunayTriangulation mesh, it shows how often the better solution falls into the triangulation!

    The #py5 sketch is interactive, you can generate other random nodes and move them around dragging with the mouse.

    Code at: github.com/villares/sketch-a-d
    More sketch-a-day: abav.lugaralgum.com/sketch-a-d
    If you like this, support my work: paypal.com/donate/?hosted_butt
    #scipy #Processing #Python #TSP #CreativeCoding