liveBook · Manning

Weighted graph

As explained in Optimization Algorithms: AI techniques for design, planning, and control problems

A graph whose edges have numerical weights representing quantities such as distance or cost.

A weighted graph assigns a numerical value to each edge. The value can represent distance, travel time, traversal cost, connection speed, or another application-specific metric. In a road network, edges may measure distance or time; in a telecommunications network, they may represent usage cost or connection speed. section 3.1

Weights turn graph connectivity into a basis for comparing routes. Dijkstra’s algorithm solves the single-source shortest-path problem when edge costs are non-negative, while uniform-cost search selects a path by its lowest cumulative cost. section 3.6

Telecommunication devices

A small network can connect Device1, Device2, Device3, and Device4 with weighted edges such as 45.69, 56.34, and 18.5. These values represent connection speeds in Mbps and can be displayed beside the edges. section 3.1

How Optimization Algorithms: AI techniques for design, planning, and control problems covers it

How deep it goes
Defines edge weights and demonstrates NetworkX construction, then connects them to shortest-path search without deriving algorithm internals.
Examples
Uses road networks with distance or cost and telecommunications devices whose edges carry Mbps connection speeds.
What it assumes
Assumes familiarity with graphs, nodes, and edges while treating edge weights as the added modeling distinction.
What you can do after
Operate/configure weighted graphs with NetworkX and visualize nodes, edges, and numerical labels.
How it connects
Connects graph, edge, shortest path, Dijkstra’s algorithm, and uniform-cost search.

Also explained in

Compare how 3 books explain weighted graph →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Optimization Algorithms: AI techniques for design, planning, and control problems. The section links point to the parts of the book it draws on.