Code covered by the BSD License  

Highlights from
Breath First Search

Be the first to rate this file! 25 Downloads (last 30 days) File Size: 1.82 KB File ID: #39763

Breath First Search

by

 

Breath First Search algorithm to find shortest paths in a network

| Watch this File

File Information
Description

This implementation of BFS algorithm follows the description in the book "Network: an Introduction - Newman"

Inputs:
- A: the adjacency matrix of the network
- s: starting node
- t: destination node

Outputs:
- shortest_paths: all shortest paths from s to t
- distance: vector containing distances from s to all other nodes

MATLAB release MATLAB 7.10 (R2010a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.

Contact us