How this calculation works
Find a smallest matching that is maximal under adding another edge, and show which selected edge dominates every input edge.
min |M| subject to M a matching and every e∈E sharing an endpoint with some edge of M.A worked example
For the path 0–1–2–3, the single middle edge 1–2 is maximal: every other edge touches it. The minimum maximal matching size is one.
Good to know
Simple undirected graph on 1–14 vertices and at most 24 edges. Exact matching enumeration capped at 1,000,000 recursive states. Cap errors certify no optimum. Edgeless graph has empty maximal matching; no weights.
Smallest among matchings that cannot grow
A matching is a set of edges with no shared endpoints. It is maximal when no additional input edge can be added without breaking that condition. This calculator finds the smallest cardinality among all such maximal matchings, so the objective deliberately favors an economical way to block every remaining edge.
Maximal describes the inability to add one edge, while minimum describes comparison among all maximal choices. These are different statements. A greedy construction can produce a maximal matching quickly but may select more edges than necessary. The bounded exact search establishes the smallest possible size and returns a matching that attains it.
Compare this with the Maximum weight matching calculator for a general graph. Find the smallest matching that cannot be extended,not a largest or maximum-weight matching.
Preserve every graph edge
Declare up to fourteen vertices and list at most twenty-four undirected edges using zero-based endpoints. Isolated vertices are allowed and remain declared, although they do not force a matching edge. The topology is unweighted; a third cost or weight column is rejected rather than silently discarded.
Loops and repeated unordered pairs are invalid. The empty edge list is valid and has an empty maximal matching, because there is no edge left to add. For a nonempty graph the answer is at least one. These conventions are useful checks when creating or correcting a small hand-entered example.
Inspect the four vertex path
The default graph has edges zero–one, one–two and two–three. Selecting the middle edge occupies vertices one and two. Each other edge shares one of those endpoints, so neither can be added. This single edge is already maximal and gives an objective value of one.
Selecting the two outer edges instead produces a larger matching of size two, and it is also maximal. That choice is maximum in this graph but fails the minimization objective. The contrast shows why a routine designed to maximize matching cardinality would return the wrong answer for this calculator.
Search only disjoint edge selections
The recursion considers including or excluding each input edge. Inclusion is allowed only if both endpoints are unused by the partial matching. At a completed selection, maximality is tested by checking that every input edge touches at least one occupied endpoint. An untouched edge would provide a legal extension.
Once a completed feasible matching is known, a partial selection with at least that many edges cannot improve it. Pruning such a branch is safe because recursion never removes an already selected edge. The search budget counts recursive states, and a budget error leaves minimum cardinality unproved rather than promoting the best partial result.
Verify the edge domination witness
The selected matching edges must be pairwise endpoint-disjoint. The domination records then pair every original edge with a selected edge sharing an endpoint. A selected edge dominates itself, which is expected. This table gives a direct maximality certificate without needing to try every possible extension manually.
Check feasibility in two separate steps: disjointness confirms the matching condition, and domination confirms that the matching cannot grow. Both are necessary. An arbitrary edge dominating set may use edges that touch each other, so domination alone cannot certify that the returned collection satisfies the matching requirement of this page.
Avoid nearby optimization confusions
A minimum edge cover tries to touch every vertex, whereas a maximal matching only has to block every edge. Isolated vertices make that difference especially visible: they prevent an ordinary full edge cover but have no effect on maximal matching size. The selected endpoints need not include every vertex.
A maximum-weight matching optimizes a sum of weights and may prefer many edges. Here there are no weights and the smallest maximal choice is wanted. Similarly, a minimum matching without maximality would always be empty. The extension restriction is the substantive part that makes the minimization meaningful on a graph with edges.
Use the bounded result as a certificate
The calculator handles small graphs exactly with an explicit million-state cap. A completed answer includes one smallest maximal matching and its domination evidence. Dense or difficult inputs can exceed the resource budget; reducing the edge set or vertex count can produce a smaller instance suitable for a complete exact run.
Relabeling vertices or reordering rows can change the selected matching when several optima tie. Compare the objective sizes rather than expecting the same edge identities. The result describes the entered combinatorial graph only, without assuming that occupying an endpoint corresponds to any particular scheduling, communication or physical resource model.
A few questions, answered
What does maximal mean?
No additional input edge can be added while preserving endpoint disjointness.
Is a maximum matching the answer?
Usually not. The objective is the smallest cardinality among maximal matchings.
What happens with no edges?
The empty matching is maximal and the answer is zero.
Does domination alone prove feasibility?
No. Selected edges must also be pairwise endpoint-disjoint.