Unified node and edge mapping algorithms