cd chord_simulator/
mix run lib/proj3.exs 1000 10
Average hops: 3.2904666666666746
All the algorithms in the paper are implemented, including find_successor, closest_preceding_node, create, join, stabilize, notify, fix_fingers and check_predecessor. Every node joins the network either by the create function or the join function. stabilize, fix_fingers and check_predecessor will run periodically to maintain the network. Query for an id is done through the find_successor function.
numNodes = 5000 numRequests = 10