Finding The Shortest Path, With A Little Help From Dijkstra - Deepstash
Machine Learning With Google

Learn more about computerscience with this collection

Understanding machine learning models

Improving data analysis and decision-making

How Google uses logic in machine learning

Machine Learning With Google

Discover 95 similar ideas in

It takes just

14 mins to read

Graphs that weigh heavy on your mind

A weighted graph is interesting because it has little to do with whether the graph is directed, undirected, or contains cycles. 

At its core, a weighted graph is a graph whose edges have some sort of value that is associated with them. The value that is attached to an edge is what gives the edge its “weight”.

3

8 reads

Dijkstra’s algorithm

Dijkstra’s algorithm can be used to determine the shortest path from one node in a graph to every other node within the same graph data structure, provided that the nodes are reachable from the starting node.

3

7 reads

Rules of Dijkstra’s game

The abstracted rules are as follows: 

  • Every time that we set out to visit a new node, we will choose the node with the smallest known distance/cost to visit first. 
  • Once we’ve moved to the node we’re going to visit, we will check each of its neighboring nodes. 
  • For each neighboring Node, we’ll calculate the Distance/Cost by summing the cost of the edges that lead to the Node we’re checking.
  • Finally, if the distance/cost to a node is less than a known distance, we’ll update the shortest distance that we have on file for that vertex. 

3

3 reads

CURATED BY

joshuarobert

Special educational needs teacher

Read & Learn

20x Faster

without
deepstash

with
deepstash

with

deepstash

Access to 200,000+ ideas

Access to the mobile app

Unlimited idea saving & library

Unlimited history

Unlimited listening to ideas

Downloading & offline access

Personalized recommendations

Supercharge your mind with one idea per day

Enter your email and spend 1 minute every day to learn something new.

Email

I agree to receive email updates