minimum-spanning-tree

Find a minimum-weight spanning tree using Prim's and Kruskal's algorithms.

Updated Jan 26, 2026
One-click install
npx skills add https://github.com/SPIRAL-EDWIN/MCM-ICM-2601000 --skill minimum-spanning-tree
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: minimum-spanning-tree
Source: https://github.com/SPIRAL-EDWIN/MCM-ICM-2601000/tree/main/.github/skills/minimum-spanning-tree
Command: npx skills add https://github.com/SPIRAL-EDWIN/MCM-ICM-2601000 --skill minimum-spanning-tree

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Find a minimum-weight spanning tree for a weighted undirected graph.

Core Features & Use Cases

  • Prim's algorithm implementation for dense graphs
  • Kruskal's algorithm implementation for sparse graphs
  • Applications: network design, circuit layout, clustering

Quick Start

Compute the MST for a given weighted undirected graph and return the MST edges with their weights and the total weight.

Frequently Asked Questions about minimum-spanning-tree

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is a minimum spanning tree and when do I need it for network design?

A minimum spanning tree connects all nodes in a weighted undirected graph with the minimal total edge weight. You need it for network design, circuit layout, and clustering tasks to ensure efficient connectivity without redundant paths.

How do I find a minimum spanning tree for a weighted undirected graph?

To find a minimum spanning tree, you provide a weighted undirected graph to the solver. It computes the MST edges with their respective weights and outputs the total weight for your network design or clustering task.

Should I use Prim's or Kruskal's algorithm for my minimum spanning tree?

Use Prim's algorithm for dense graphs and Kruskal's algorithm for sparse graphs. Both compute the minimum spanning tree by returning the MST edges with weights and the total weight for your undirected graph.

Can I use this minimum spanning tree solver for circuit layout and clustering?

Yes, the minimum spanning tree solver applies to circuit layout and clustering tasks. It connects all nodes with minimal total edge weight, returning the MST edges with weights and the total weight for your specific application.

What output format does the minimum spanning tree computation return?

The minimum spanning tree computation returns the MST edges with their corresponding weights along with the total weight. This output applies to network design, circuit layout, and clustering tasks requiring minimal total edge weight.