Same person as @[email protected], different instance.

  • 1 Post
  • 21 Comments
Joined 3 months ago
cake
Cake day: April 3rd, 2024

help-circle









  • That’s wrong, it calculates the surface distance not the distance through the earth, while claiming otherwise. From the geopy.distance.great_circle documentation:

    Use spherical geometry to calculate the surface distance between points.

    This would be a correct calculation, using the formula for the chord length from here:

    from math import *
    
    # Coordinates for Atlanta, West Georgia
    atlanta_coords = (33.7490, -84.3880)
    # Coordinates for Tbilisi, Georgia
    tbilisi_coords = (41.7151, 44.8271)
    
    # Convert from degrees to radians
    phi = (radians(atlanta_coords[0]), radians(tbilisi_coords[0]))
    lambd = (radians(atlanta_coords[1]), radians(tbilisi_coords[1]))
    
    # Spherical law of cosines
    central_angle = acos(sin(phi[0]) * sin(phi[1]) + cos(phi[0]) * cos(phi[1]) * cos(lambd[1] - lambd[0]))
    chord_length = 2 * sin(central_angle/2)
    
    earth_radius = 6335.439 #km
    print(f"Tunnel length: {chord_length * earth_radius:.3f}km")
    

    A straight tunnel from Atlanta to Tbilisi would be 9060.898km long.






  • I must say I like the idea of having changes to files be bound to just the current branch, not the entire worktree (section 6.4.2), but other than that the points that are brought up don’t really seem too compelling. It certainly didn’t convince me that git has an inherently flawed design. For example, eliminating the staging area is a tempting point for simplifying git, but the authors already admit that it has some legitimate use cases.

    But of course it is always nice to see some experimentation done in this space. I think the main reason why git sometimes is confusing, is because distributed version control really is a complex task, and git already does a very good job at making it tractable.