Prove that the complete bipartite graph $K_3,s$ has $s^23^s-1$ spanning trees for $sgeq2$Proving that the complement of a bipartite graph is perfectFinding the spanning subgraphs of a complete bipartite graphProve that a graph cannot have two distinct spanning treesGraph theory: proving that a graph with specific property is bipartiteProve that all trees are bipartiteSpanning subgraphs of complete bipartite graphComplete matching in bipartite graphSpanning trees of Complete Bipartite GraphSpanning bipartite graphSpanning trees for complete graph

Do VLANs within a subnet need to have their own subnet for router on a stick?

Test whether all array elements are factors of a number

Why Is Death Allowed In the Matrix?

Why, historically, did Gödel think CH was false?

How can bays and straits be determined in a procedurally generated map?

tikz: show 0 at the axis origin

The use of multiple foreign keys on same column in SQL Server

Writing rule stating superpower from different root cause is bad writing

A newer friend of my brother's gave him a load of baseball cards that are supposedly extremely valuable. Is this a scam?

What are these boxed doors outside store fronts in New York?

What typically incentivizes a professor to change jobs to a lower ranking university?

I’m planning on buying a laser printer but concerned about the life cycle of toner in the machine

In Japanese, what’s the difference between “Tonari ni” (となりに) and “Tsugi” (つぎ)? When would you use one over the other?

Why doesn't Newton's third law mean a person bounces back to where they started when they hit the ground?

US citizen flying to France today and my passport expires in less than 2 months

Can divisibility rules for digits be generalized to sum of digits

Do I have a twin with permutated remainders?

Arthur Somervell: 1000 Exercises - Meaning of this notation

Languages that we cannot (dis)prove to be Context-Free

Can I ask the recruiters in my resume to put the reason why I am rejected?

Why do falling prices hurt debtors?

How much RAM could one put in a typical 80386 setup?

Adding span tags within wp_list_pages list items

Risk of getting Chronic Wasting Disease (CWD) in the United States?



Prove that the complete bipartite graph $K_3,s$ has $s^23^s-1$ spanning trees for $sgeq2$


Proving that the complement of a bipartite graph is perfectFinding the spanning subgraphs of a complete bipartite graphProve that a graph cannot have two distinct spanning treesGraph theory: proving that a graph with specific property is bipartiteProve that all trees are bipartiteSpanning subgraphs of complete bipartite graphComplete matching in bipartite graphSpanning trees of Complete Bipartite GraphSpanning bipartite graphSpanning trees for complete graph













2












$begingroup$


I am wondering about a more combinatorial proof for this question as I have only seen the proof using Kirchoff theorem?
Any help would be much appreciated!










share|cite|improve this question









$endgroup$











  • $begingroup$
    It looks like there is a nice combinatorial proof of this behind a paywall at link.springer.com/chapter/10.1007/978-3-642-46908-4_38
    $endgroup$
    – Mike Earnest
    Mar 22 at 1:21










  • $begingroup$
    There is also a very nice generalization here, with no paywall: sciencedirect.com/science/article/pii/S0012365X99901115
    $endgroup$
    – Mike Earnest
    Mar 28 at 17:02
















2












$begingroup$


I am wondering about a more combinatorial proof for this question as I have only seen the proof using Kirchoff theorem?
Any help would be much appreciated!










share|cite|improve this question









$endgroup$











  • $begingroup$
    It looks like there is a nice combinatorial proof of this behind a paywall at link.springer.com/chapter/10.1007/978-3-642-46908-4_38
    $endgroup$
    – Mike Earnest
    Mar 22 at 1:21










  • $begingroup$
    There is also a very nice generalization here, with no paywall: sciencedirect.com/science/article/pii/S0012365X99901115
    $endgroup$
    – Mike Earnest
    Mar 28 at 17:02














2












2








2


2



$begingroup$


I am wondering about a more combinatorial proof for this question as I have only seen the proof using Kirchoff theorem?
Any help would be much appreciated!










share|cite|improve this question









$endgroup$




I am wondering about a more combinatorial proof for this question as I have only seen the proof using Kirchoff theorem?
Any help would be much appreciated!







combinatorics graph-theory bipartite-graph






share|cite|improve this question













share|cite|improve this question











share|cite|improve this question




share|cite|improve this question










asked Mar 21 at 23:50









178971178971

184




184











  • $begingroup$
    It looks like there is a nice combinatorial proof of this behind a paywall at link.springer.com/chapter/10.1007/978-3-642-46908-4_38
    $endgroup$
    – Mike Earnest
    Mar 22 at 1:21










  • $begingroup$
    There is also a very nice generalization here, with no paywall: sciencedirect.com/science/article/pii/S0012365X99901115
    $endgroup$
    – Mike Earnest
    Mar 28 at 17:02

















  • $begingroup$
    It looks like there is a nice combinatorial proof of this behind a paywall at link.springer.com/chapter/10.1007/978-3-642-46908-4_38
    $endgroup$
    – Mike Earnest
    Mar 22 at 1:21










  • $begingroup$
    There is also a very nice generalization here, with no paywall: sciencedirect.com/science/article/pii/S0012365X99901115
    $endgroup$
    – Mike Earnest
    Mar 28 at 17:02
















$begingroup$
It looks like there is a nice combinatorial proof of this behind a paywall at link.springer.com/chapter/10.1007/978-3-642-46908-4_38
$endgroup$
– Mike Earnest
Mar 22 at 1:21




$begingroup$
It looks like there is a nice combinatorial proof of this behind a paywall at link.springer.com/chapter/10.1007/978-3-642-46908-4_38
$endgroup$
– Mike Earnest
Mar 22 at 1:21












$begingroup$
There is also a very nice generalization here, with no paywall: sciencedirect.com/science/article/pii/S0012365X99901115
$endgroup$
– Mike Earnest
Mar 28 at 17:02





$begingroup$
There is also a very nice generalization here, with no paywall: sciencedirect.com/science/article/pii/S0012365X99901115
$endgroup$
– Mike Earnest
Mar 28 at 17:02











3 Answers
3






active

oldest

votes


















1












$begingroup$

More generally, there are $m^n-1n^m-1$ spanning trees of $K_m,n$. Here is a proof which uses generating functions. The proof is long and appears unwieldy, but the result and methods are quite general and beautiful.




In $K_m,n$, label the vertices of the spanning tree from $v_1$ to $v_m$ in the part of size $m$, and from $v_m+1$ to $v_m+n$ in the other. We will make a generating function which is a polynomial in the variables $x_1,x_2,dots,x_m+n$. For each spanning tree $T$, define the monomial $x^T$ by
$$
x^T=x_1^deg(v_1)-1x_2^deg(v_2)-1cdots x_m+n^deg(v_m+n)-1
$$

The notation $x^T$ is a slight abuse, but it is mnemonic. Then, let
$$
P_n,m=sum_T x^T,
$$

where $T$ ranges over all spanning subtrees of $K_m,n$.




Claim: $P_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1$.




The fact that there are $m^n-1n^m-1$ spanning trees follows by setting each $x_i=1$.



Proof: We prove this by induction on $n$ and $m$. Let
$$
Q_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1
$$



be the polynomial we claim equals $P_m,n$. For each $1le ile m+n$, let
$$
P_m,n^i=sum_substackTtext such that\ v_itext is a leaf x^T
$$

Note that $P_m,n^i$ is exactly the result of setting $x_i=0$ in $P_m,n$; when you set $x_i=0$ in $P_m,n$, any summands where $deg v_ige 2$ will have a factor of $x_i$, and be killed. I will record this fact as
$$
P_m,n^i=P_m,nBig|_x_i=0tag1label1
$$

Now, for the moment, suppose that $ile m$, so $v_i$ is a vertex in the part of size $m$. And suppose that its neighbor in the other part is $v_m+j$, for some $1le jle n$. There is an obvious bijection
$$
left;
beginarrayctextspanning trees of $K_m,n$ where \text$v_i$ is a leaf, with neighbor $v_m+j$
endarray
;rightiff;textspanning trees of $K_m,nsetminus v_i$ ;
$$

Both of these are sets of trees, so we take the sum $sum_T x^T$ for $T$ ranging in either sets. A little thought shows that the sum for the left is equal to $x_m+j$ times the sum for the right. Algebraically,
$$
sum_Tin LHSx^T=x_m+jsum_Tin RHSx^Ttag2label2
$$

Why? You are summing over basically the same trees, the only difference being that $v_m+j$ has an extra neighbor for trees in the LHS. Furthermore, the RHS does not depend on $j$. By induction, the sum of $x^T$ for $T$ in the RHS is just
$$
sum_Tin RHSx^T=(x_1+x_2+dots+hat x_i+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2
$$

where the $hatx_i$ means that $x_i$ is omitted from the sum. This is the same as the
$$
sum_Tin RHSx^T=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0tag3label3
$$

Now, putting this all together, for all $ile m$, we have
beginalign
P_m,nBig|_x_i=0
&stackreleqref1=P_m,n^i
\&=sum_substackTtext such that\ v_itext is a leaf x^T
\&=sum_j=1^mhspace-1em sum_substackTtext such that\ v_itext is a leaf\textwith neighbor $v_m+j$hspace-1em x^T
\&stackreleqref2=sum_j=1^mx_m+jsum_Ttext spans K_m,nsetminusv_ix^T
\&stackreleqref3=left(sum_j=1^mx_m+jright)(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0
\&=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1Big|_x_i=0
\&= Q_m,nBig|_x_i=0
endalign

This is progress! We have not proved that $P_m,n=Q_m,n$ yet, but we have proved they are equal when you substitute $x_i=0$ in both. This means that $x_i$ is a factor of $P_m,n-Q_m,n$, for all $1le ile m$. You can prove the same is true for $m+1le ile m+n$ by the same method. Therefore, we have shown that each variable $x_i$ is a factor of $P_m,n-Q_m,n$, which implies that the product of all the variables is a factor of $P_m,n-Q_m,n$.



Now, for the punchline. If $P_m,n-Q_m,n$ were nonzero, it would have degree at most $m+n-2$, as this is true of both $P_m,n$ and $Q_m,n$. This would contradict the previous conclusion that the product of all the $x_i$ divides $P_m,n-Q_m,n$, which would bring the degree up to at least $m+n$. We conclude $P_m,n-Q_m,n=0$.






share|cite|improve this answer









$endgroup$












  • $begingroup$
    Wow I would never have thought about it like this, thanks so much for taking the time to answer!
    $endgroup$
    – 178971
    Mar 22 at 8:10










  • $begingroup$
    I should note I got this proof idea from artofproblemsolving.com/community/….
    $endgroup$
    – Mike Earnest
    Mar 22 at 22:52


















1












$begingroup$

Let $S=x,y,z$ be one set of the bipartition of $K_3,s$. Let $T$ be any spanning tree of $K_3,s$.



Look first at $x$. Since $T$ is a tree, there exists a unique path $x=v_0, ldots, v_n=y$ from $x$ to $y$ in $T$. Clearly $v_1$ is in the other set of the bipartition, but $v_2$ must be in $S$.



Case 1: $v_2 = z$. In this case, the path from $x$ to $y$ must look like $x, v_1, z, v_3, y$. To create a spanning tree with this path structure from $x$ to $y$, there are $s$ choices for $v_1$, $s-1$ choices for $v_3$, and the remaining $s-2$ vertices can be attached arbitrarily to the three vertices of $S$ in $3^s-2$ ways. Hence there are $(s^2-s) times 3^s-2$ such spanning trees of $K_3,s$.



Case 2: $v_2=y$. In this case the path from $x$ to $y$ is $x, v_1, y$, and we consider the path from $x$ to $z$. There are three possible configurations for this path in $T$:




  1. $x, v_1, y, v_3, z$: as before, there are $s$ choices for $v_1$ and $s-1$ choices for $v_3$, with the remaining vertices attached to a vertex of $S$ arbitrarily, yielding $(s^2-s) times 3^s-2$ such spanning trees.


  2. $x, w_1, z$, where $w_1 ne v_1$: there are $s$ choices for $v_1$ and $s-1$ choices for $w_1$, and again $3^s-2$ ways to attach the remaining vertices, yielding $(s^2-s) times 3^s-2$ such spanning trees


  3. $x,v_1,z$: in which all of $x$, $y$ and $z$ are attached to the same vertex. There are $s$ ways to pick $v_1$, and then the remaining $s-1$ vertices can be attached arbitrarily, yielding $s times 3^s-1$ such spanning trees.

Adding up over all of the possibilities, we see there are
$$3 times (s^2-s)times 3^s-2 + 3 times s times 3^s-2 = s^2 times 3^s-1$$
spanning trees.



Clearly, this sort of analysis becomes unwieldy for even $K_4,s$, let alone the general case. Hopefully it illustrates the power of Kirchoff's theorem over this more simple-minded approach.






share|cite|improve this answer











$endgroup$












  • $begingroup$
    Thanks so much, this is really useful and interesting!
    $endgroup$
    – 178971
    Mar 22 at 8:09










  • $begingroup$
    I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
    $endgroup$
    – 178971
    Mar 24 at 21:33











  • $begingroup$
    I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
    $endgroup$
    – Jeremy Dover
    Mar 24 at 22:23










  • $begingroup$
    I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
    $endgroup$
    – 178971
    Mar 24 at 22:30










  • $begingroup$
    It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
    $endgroup$
    – Jeremy Dover
    Mar 25 at 15:02


















1












$begingroup$

Adding a separate answer because I now have a much simpler proof!




To prove there are $m^n-1n^m-1$ spanning trees, we will use a slight modification of Prüfer's original algorithm to get a bijection between trees and integers sequences of length $m+n-2$. Recall that to get a Prufer code, you repeatedly delete the smallest leaf, and record the label of its neighbor. In our case, we will do almost the same; however, instead of always pruning the smallest leaf, we will prune the smallest leaf in a specific part of the bipartite graph.



Specifically, suppose $mle n$. We will prune leaves from the parts according to the following pattern:
$$
underbracemathsfN,N,dots,N_n-m,underbracemathsfN,M,N,Mdots,N,M_2(m-1)
$$



So the first string of leaves will come from the larger part, until the parts are equalized, and we alternate thereafter. There are obviously $m^n-1n^m-1$ possible codes resulting from this pattern, and you can show this procedure is a bijection in a similar way.



How do we know we can always find a leaf in the prescribed part? By this lemma:




Lemma: In the bipartite graph $K_m,n$, with $mle n$, there is a leaf in the part of size $n$.




Proof: The sum of the degrees of the vertices in the $n$ part is equal to the total number of edges, $n+m-1$. If each vertex had degree $2$ or more, this sum of degrees would be at least $2n>n+m-1$. $square$






share|cite|improve this answer









$endgroup$













    Your Answer





    StackExchange.ifUsing("editor", function ()
    return StackExchange.using("mathjaxEditing", function ()
    StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
    StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
    );
    );
    , "mathjax-editing");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "69"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    noCode: true, onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3157546%2fprove-that-the-complete-bipartite-graph-k-3-s-has-s23s-1-spanning-tree%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    3 Answers
    3






    active

    oldest

    votes








    3 Answers
    3






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    1












    $begingroup$

    More generally, there are $m^n-1n^m-1$ spanning trees of $K_m,n$. Here is a proof which uses generating functions. The proof is long and appears unwieldy, but the result and methods are quite general and beautiful.




    In $K_m,n$, label the vertices of the spanning tree from $v_1$ to $v_m$ in the part of size $m$, and from $v_m+1$ to $v_m+n$ in the other. We will make a generating function which is a polynomial in the variables $x_1,x_2,dots,x_m+n$. For each spanning tree $T$, define the monomial $x^T$ by
    $$
    x^T=x_1^deg(v_1)-1x_2^deg(v_2)-1cdots x_m+n^deg(v_m+n)-1
    $$

    The notation $x^T$ is a slight abuse, but it is mnemonic. Then, let
    $$
    P_n,m=sum_T x^T,
    $$

    where $T$ ranges over all spanning subtrees of $K_m,n$.




    Claim: $P_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1$.




    The fact that there are $m^n-1n^m-1$ spanning trees follows by setting each $x_i=1$.



    Proof: We prove this by induction on $n$ and $m$. Let
    $$
    Q_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1
    $$



    be the polynomial we claim equals $P_m,n$. For each $1le ile m+n$, let
    $$
    P_m,n^i=sum_substackTtext such that\ v_itext is a leaf x^T
    $$

    Note that $P_m,n^i$ is exactly the result of setting $x_i=0$ in $P_m,n$; when you set $x_i=0$ in $P_m,n$, any summands where $deg v_ige 2$ will have a factor of $x_i$, and be killed. I will record this fact as
    $$
    P_m,n^i=P_m,nBig|_x_i=0tag1label1
    $$

    Now, for the moment, suppose that $ile m$, so $v_i$ is a vertex in the part of size $m$. And suppose that its neighbor in the other part is $v_m+j$, for some $1le jle n$. There is an obvious bijection
    $$
    left;
    beginarrayctextspanning trees of $K_m,n$ where \text$v_i$ is a leaf, with neighbor $v_m+j$
    endarray
    ;rightiff;textspanning trees of $K_m,nsetminus v_i$ ;
    $$

    Both of these are sets of trees, so we take the sum $sum_T x^T$ for $T$ ranging in either sets. A little thought shows that the sum for the left is equal to $x_m+j$ times the sum for the right. Algebraically,
    $$
    sum_Tin LHSx^T=x_m+jsum_Tin RHSx^Ttag2label2
    $$

    Why? You are summing over basically the same trees, the only difference being that $v_m+j$ has an extra neighbor for trees in the LHS. Furthermore, the RHS does not depend on $j$. By induction, the sum of $x^T$ for $T$ in the RHS is just
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+hat x_i+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2
    $$

    where the $hatx_i$ means that $x_i$ is omitted from the sum. This is the same as the
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0tag3label3
    $$

    Now, putting this all together, for all $ile m$, we have
    beginalign
    P_m,nBig|_x_i=0
    &stackreleqref1=P_m,n^i
    \&=sum_substackTtext such that\ v_itext is a leaf x^T
    \&=sum_j=1^mhspace-1em sum_substackTtext such that\ v_itext is a leaf\textwith neighbor $v_m+j$hspace-1em x^T
    \&stackreleqref2=sum_j=1^mx_m+jsum_Ttext spans K_m,nsetminusv_ix^T
    \&stackreleqref3=left(sum_j=1^mx_m+jright)(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0
    \&=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1Big|_x_i=0
    \&= Q_m,nBig|_x_i=0
    endalign

    This is progress! We have not proved that $P_m,n=Q_m,n$ yet, but we have proved they are equal when you substitute $x_i=0$ in both. This means that $x_i$ is a factor of $P_m,n-Q_m,n$, for all $1le ile m$. You can prove the same is true for $m+1le ile m+n$ by the same method. Therefore, we have shown that each variable $x_i$ is a factor of $P_m,n-Q_m,n$, which implies that the product of all the variables is a factor of $P_m,n-Q_m,n$.



    Now, for the punchline. If $P_m,n-Q_m,n$ were nonzero, it would have degree at most $m+n-2$, as this is true of both $P_m,n$ and $Q_m,n$. This would contradict the previous conclusion that the product of all the $x_i$ divides $P_m,n-Q_m,n$, which would bring the degree up to at least $m+n$. We conclude $P_m,n-Q_m,n=0$.






    share|cite|improve this answer









    $endgroup$












    • $begingroup$
      Wow I would never have thought about it like this, thanks so much for taking the time to answer!
      $endgroup$
      – 178971
      Mar 22 at 8:10










    • $begingroup$
      I should note I got this proof idea from artofproblemsolving.com/community/….
      $endgroup$
      – Mike Earnest
      Mar 22 at 22:52















    1












    $begingroup$

    More generally, there are $m^n-1n^m-1$ spanning trees of $K_m,n$. Here is a proof which uses generating functions. The proof is long and appears unwieldy, but the result and methods are quite general and beautiful.




    In $K_m,n$, label the vertices of the spanning tree from $v_1$ to $v_m$ in the part of size $m$, and from $v_m+1$ to $v_m+n$ in the other. We will make a generating function which is a polynomial in the variables $x_1,x_2,dots,x_m+n$. For each spanning tree $T$, define the monomial $x^T$ by
    $$
    x^T=x_1^deg(v_1)-1x_2^deg(v_2)-1cdots x_m+n^deg(v_m+n)-1
    $$

    The notation $x^T$ is a slight abuse, but it is mnemonic. Then, let
    $$
    P_n,m=sum_T x^T,
    $$

    where $T$ ranges over all spanning subtrees of $K_m,n$.




    Claim: $P_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1$.




    The fact that there are $m^n-1n^m-1$ spanning trees follows by setting each $x_i=1$.



    Proof: We prove this by induction on $n$ and $m$. Let
    $$
    Q_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1
    $$



    be the polynomial we claim equals $P_m,n$. For each $1le ile m+n$, let
    $$
    P_m,n^i=sum_substackTtext such that\ v_itext is a leaf x^T
    $$

    Note that $P_m,n^i$ is exactly the result of setting $x_i=0$ in $P_m,n$; when you set $x_i=0$ in $P_m,n$, any summands where $deg v_ige 2$ will have a factor of $x_i$, and be killed. I will record this fact as
    $$
    P_m,n^i=P_m,nBig|_x_i=0tag1label1
    $$

    Now, for the moment, suppose that $ile m$, so $v_i$ is a vertex in the part of size $m$. And suppose that its neighbor in the other part is $v_m+j$, for some $1le jle n$. There is an obvious bijection
    $$
    left;
    beginarrayctextspanning trees of $K_m,n$ where \text$v_i$ is a leaf, with neighbor $v_m+j$
    endarray
    ;rightiff;textspanning trees of $K_m,nsetminus v_i$ ;
    $$

    Both of these are sets of trees, so we take the sum $sum_T x^T$ for $T$ ranging in either sets. A little thought shows that the sum for the left is equal to $x_m+j$ times the sum for the right. Algebraically,
    $$
    sum_Tin LHSx^T=x_m+jsum_Tin RHSx^Ttag2label2
    $$

    Why? You are summing over basically the same trees, the only difference being that $v_m+j$ has an extra neighbor for trees in the LHS. Furthermore, the RHS does not depend on $j$. By induction, the sum of $x^T$ for $T$ in the RHS is just
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+hat x_i+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2
    $$

    where the $hatx_i$ means that $x_i$ is omitted from the sum. This is the same as the
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0tag3label3
    $$

    Now, putting this all together, for all $ile m$, we have
    beginalign
    P_m,nBig|_x_i=0
    &stackreleqref1=P_m,n^i
    \&=sum_substackTtext such that\ v_itext is a leaf x^T
    \&=sum_j=1^mhspace-1em sum_substackTtext such that\ v_itext is a leaf\textwith neighbor $v_m+j$hspace-1em x^T
    \&stackreleqref2=sum_j=1^mx_m+jsum_Ttext spans K_m,nsetminusv_ix^T
    \&stackreleqref3=left(sum_j=1^mx_m+jright)(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0
    \&=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1Big|_x_i=0
    \&= Q_m,nBig|_x_i=0
    endalign

    This is progress! We have not proved that $P_m,n=Q_m,n$ yet, but we have proved they are equal when you substitute $x_i=0$ in both. This means that $x_i$ is a factor of $P_m,n-Q_m,n$, for all $1le ile m$. You can prove the same is true for $m+1le ile m+n$ by the same method. Therefore, we have shown that each variable $x_i$ is a factor of $P_m,n-Q_m,n$, which implies that the product of all the variables is a factor of $P_m,n-Q_m,n$.



    Now, for the punchline. If $P_m,n-Q_m,n$ were nonzero, it would have degree at most $m+n-2$, as this is true of both $P_m,n$ and $Q_m,n$. This would contradict the previous conclusion that the product of all the $x_i$ divides $P_m,n-Q_m,n$, which would bring the degree up to at least $m+n$. We conclude $P_m,n-Q_m,n=0$.






    share|cite|improve this answer









    $endgroup$












    • $begingroup$
      Wow I would never have thought about it like this, thanks so much for taking the time to answer!
      $endgroup$
      – 178971
      Mar 22 at 8:10










    • $begingroup$
      I should note I got this proof idea from artofproblemsolving.com/community/….
      $endgroup$
      – Mike Earnest
      Mar 22 at 22:52













    1












    1








    1





    $begingroup$

    More generally, there are $m^n-1n^m-1$ spanning trees of $K_m,n$. Here is a proof which uses generating functions. The proof is long and appears unwieldy, but the result and methods are quite general and beautiful.




    In $K_m,n$, label the vertices of the spanning tree from $v_1$ to $v_m$ in the part of size $m$, and from $v_m+1$ to $v_m+n$ in the other. We will make a generating function which is a polynomial in the variables $x_1,x_2,dots,x_m+n$. For each spanning tree $T$, define the monomial $x^T$ by
    $$
    x^T=x_1^deg(v_1)-1x_2^deg(v_2)-1cdots x_m+n^deg(v_m+n)-1
    $$

    The notation $x^T$ is a slight abuse, but it is mnemonic. Then, let
    $$
    P_n,m=sum_T x^T,
    $$

    where $T$ ranges over all spanning subtrees of $K_m,n$.




    Claim: $P_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1$.




    The fact that there are $m^n-1n^m-1$ spanning trees follows by setting each $x_i=1$.



    Proof: We prove this by induction on $n$ and $m$. Let
    $$
    Q_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1
    $$



    be the polynomial we claim equals $P_m,n$. For each $1le ile m+n$, let
    $$
    P_m,n^i=sum_substackTtext such that\ v_itext is a leaf x^T
    $$

    Note that $P_m,n^i$ is exactly the result of setting $x_i=0$ in $P_m,n$; when you set $x_i=0$ in $P_m,n$, any summands where $deg v_ige 2$ will have a factor of $x_i$, and be killed. I will record this fact as
    $$
    P_m,n^i=P_m,nBig|_x_i=0tag1label1
    $$

    Now, for the moment, suppose that $ile m$, so $v_i$ is a vertex in the part of size $m$. And suppose that its neighbor in the other part is $v_m+j$, for some $1le jle n$. There is an obvious bijection
    $$
    left;
    beginarrayctextspanning trees of $K_m,n$ where \text$v_i$ is a leaf, with neighbor $v_m+j$
    endarray
    ;rightiff;textspanning trees of $K_m,nsetminus v_i$ ;
    $$

    Both of these are sets of trees, so we take the sum $sum_T x^T$ for $T$ ranging in either sets. A little thought shows that the sum for the left is equal to $x_m+j$ times the sum for the right. Algebraically,
    $$
    sum_Tin LHSx^T=x_m+jsum_Tin RHSx^Ttag2label2
    $$

    Why? You are summing over basically the same trees, the only difference being that $v_m+j$ has an extra neighbor for trees in the LHS. Furthermore, the RHS does not depend on $j$. By induction, the sum of $x^T$ for $T$ in the RHS is just
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+hat x_i+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2
    $$

    where the $hatx_i$ means that $x_i$ is omitted from the sum. This is the same as the
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0tag3label3
    $$

    Now, putting this all together, for all $ile m$, we have
    beginalign
    P_m,nBig|_x_i=0
    &stackreleqref1=P_m,n^i
    \&=sum_substackTtext such that\ v_itext is a leaf x^T
    \&=sum_j=1^mhspace-1em sum_substackTtext such that\ v_itext is a leaf\textwith neighbor $v_m+j$hspace-1em x^T
    \&stackreleqref2=sum_j=1^mx_m+jsum_Ttext spans K_m,nsetminusv_ix^T
    \&stackreleqref3=left(sum_j=1^mx_m+jright)(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0
    \&=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1Big|_x_i=0
    \&= Q_m,nBig|_x_i=0
    endalign

    This is progress! We have not proved that $P_m,n=Q_m,n$ yet, but we have proved they are equal when you substitute $x_i=0$ in both. This means that $x_i$ is a factor of $P_m,n-Q_m,n$, for all $1le ile m$. You can prove the same is true for $m+1le ile m+n$ by the same method. Therefore, we have shown that each variable $x_i$ is a factor of $P_m,n-Q_m,n$, which implies that the product of all the variables is a factor of $P_m,n-Q_m,n$.



    Now, for the punchline. If $P_m,n-Q_m,n$ were nonzero, it would have degree at most $m+n-2$, as this is true of both $P_m,n$ and $Q_m,n$. This would contradict the previous conclusion that the product of all the $x_i$ divides $P_m,n-Q_m,n$, which would bring the degree up to at least $m+n$. We conclude $P_m,n-Q_m,n=0$.






    share|cite|improve this answer









    $endgroup$



    More generally, there are $m^n-1n^m-1$ spanning trees of $K_m,n$. Here is a proof which uses generating functions. The proof is long and appears unwieldy, but the result and methods are quite general and beautiful.




    In $K_m,n$, label the vertices of the spanning tree from $v_1$ to $v_m$ in the part of size $m$, and from $v_m+1$ to $v_m+n$ in the other. We will make a generating function which is a polynomial in the variables $x_1,x_2,dots,x_m+n$. For each spanning tree $T$, define the monomial $x^T$ by
    $$
    x^T=x_1^deg(v_1)-1x_2^deg(v_2)-1cdots x_m+n^deg(v_m+n)-1
    $$

    The notation $x^T$ is a slight abuse, but it is mnemonic. Then, let
    $$
    P_n,m=sum_T x^T,
    $$

    where $T$ ranges over all spanning subtrees of $K_m,n$.




    Claim: $P_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1$.




    The fact that there are $m^n-1n^m-1$ spanning trees follows by setting each $x_i=1$.



    Proof: We prove this by induction on $n$ and $m$. Let
    $$
    Q_n,m=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1
    $$



    be the polynomial we claim equals $P_m,n$. For each $1le ile m+n$, let
    $$
    P_m,n^i=sum_substackTtext such that\ v_itext is a leaf x^T
    $$

    Note that $P_m,n^i$ is exactly the result of setting $x_i=0$ in $P_m,n$; when you set $x_i=0$ in $P_m,n$, any summands where $deg v_ige 2$ will have a factor of $x_i$, and be killed. I will record this fact as
    $$
    P_m,n^i=P_m,nBig|_x_i=0tag1label1
    $$

    Now, for the moment, suppose that $ile m$, so $v_i$ is a vertex in the part of size $m$. And suppose that its neighbor in the other part is $v_m+j$, for some $1le jle n$. There is an obvious bijection
    $$
    left;
    beginarrayctextspanning trees of $K_m,n$ where \text$v_i$ is a leaf, with neighbor $v_m+j$
    endarray
    ;rightiff;textspanning trees of $K_m,nsetminus v_i$ ;
    $$

    Both of these are sets of trees, so we take the sum $sum_T x^T$ for $T$ ranging in either sets. A little thought shows that the sum for the left is equal to $x_m+j$ times the sum for the right. Algebraically,
    $$
    sum_Tin LHSx^T=x_m+jsum_Tin RHSx^Ttag2label2
    $$

    Why? You are summing over basically the same trees, the only difference being that $v_m+j$ has an extra neighbor for trees in the LHS. Furthermore, the RHS does not depend on $j$. By induction, the sum of $x^T$ for $T$ in the RHS is just
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+hat x_i+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2
    $$

    where the $hatx_i$ means that $x_i$ is omitted from the sum. This is the same as the
    $$
    sum_Tin RHSx^T=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0tag3label3
    $$

    Now, putting this all together, for all $ile m$, we have
    beginalign
    P_m,nBig|_x_i=0
    &stackreleqref1=P_m,n^i
    \&=sum_substackTtext such that\ v_itext is a leaf x^T
    \&=sum_j=1^mhspace-1em sum_substackTtext such that\ v_itext is a leaf\textwith neighbor $v_m+j$hspace-1em x^T
    \&stackreleqref2=sum_j=1^mx_m+jsum_Ttext spans K_m,nsetminusv_ix^T
    \&stackreleqref3=left(sum_j=1^mx_m+jright)(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-2Big|_x_i=0
    \&=(x_1+x_2+dots+x_m)^n-1(x_m+1+x_m+2+dots+x_m+n)^m-1Big|_x_i=0
    \&= Q_m,nBig|_x_i=0
    endalign

    This is progress! We have not proved that $P_m,n=Q_m,n$ yet, but we have proved they are equal when you substitute $x_i=0$ in both. This means that $x_i$ is a factor of $P_m,n-Q_m,n$, for all $1le ile m$. You can prove the same is true for $m+1le ile m+n$ by the same method. Therefore, we have shown that each variable $x_i$ is a factor of $P_m,n-Q_m,n$, which implies that the product of all the variables is a factor of $P_m,n-Q_m,n$.



    Now, for the punchline. If $P_m,n-Q_m,n$ were nonzero, it would have degree at most $m+n-2$, as this is true of both $P_m,n$ and $Q_m,n$. This would contradict the previous conclusion that the product of all the $x_i$ divides $P_m,n-Q_m,n$, which would bring the degree up to at least $m+n$. We conclude $P_m,n-Q_m,n=0$.







    share|cite|improve this answer












    share|cite|improve this answer



    share|cite|improve this answer










    answered Mar 22 at 2:29









    Mike EarnestMike Earnest

    27k22152




    27k22152











    • $begingroup$
      Wow I would never have thought about it like this, thanks so much for taking the time to answer!
      $endgroup$
      – 178971
      Mar 22 at 8:10










    • $begingroup$
      I should note I got this proof idea from artofproblemsolving.com/community/….
      $endgroup$
      – Mike Earnest
      Mar 22 at 22:52
















    • $begingroup$
      Wow I would never have thought about it like this, thanks so much for taking the time to answer!
      $endgroup$
      – 178971
      Mar 22 at 8:10










    • $begingroup$
      I should note I got this proof idea from artofproblemsolving.com/community/….
      $endgroup$
      – Mike Earnest
      Mar 22 at 22:52















    $begingroup$
    Wow I would never have thought about it like this, thanks so much for taking the time to answer!
    $endgroup$
    – 178971
    Mar 22 at 8:10




    $begingroup$
    Wow I would never have thought about it like this, thanks so much for taking the time to answer!
    $endgroup$
    – 178971
    Mar 22 at 8:10












    $begingroup$
    I should note I got this proof idea from artofproblemsolving.com/community/….
    $endgroup$
    – Mike Earnest
    Mar 22 at 22:52




    $begingroup$
    I should note I got this proof idea from artofproblemsolving.com/community/….
    $endgroup$
    – Mike Earnest
    Mar 22 at 22:52











    1












    $begingroup$

    Let $S=x,y,z$ be one set of the bipartition of $K_3,s$. Let $T$ be any spanning tree of $K_3,s$.



    Look first at $x$. Since $T$ is a tree, there exists a unique path $x=v_0, ldots, v_n=y$ from $x$ to $y$ in $T$. Clearly $v_1$ is in the other set of the bipartition, but $v_2$ must be in $S$.



    Case 1: $v_2 = z$. In this case, the path from $x$ to $y$ must look like $x, v_1, z, v_3, y$. To create a spanning tree with this path structure from $x$ to $y$, there are $s$ choices for $v_1$, $s-1$ choices for $v_3$, and the remaining $s-2$ vertices can be attached arbitrarily to the three vertices of $S$ in $3^s-2$ ways. Hence there are $(s^2-s) times 3^s-2$ such spanning trees of $K_3,s$.



    Case 2: $v_2=y$. In this case the path from $x$ to $y$ is $x, v_1, y$, and we consider the path from $x$ to $z$. There are three possible configurations for this path in $T$:




    1. $x, v_1, y, v_3, z$: as before, there are $s$ choices for $v_1$ and $s-1$ choices for $v_3$, with the remaining vertices attached to a vertex of $S$ arbitrarily, yielding $(s^2-s) times 3^s-2$ such spanning trees.


    2. $x, w_1, z$, where $w_1 ne v_1$: there are $s$ choices for $v_1$ and $s-1$ choices for $w_1$, and again $3^s-2$ ways to attach the remaining vertices, yielding $(s^2-s) times 3^s-2$ such spanning trees


    3. $x,v_1,z$: in which all of $x$, $y$ and $z$ are attached to the same vertex. There are $s$ ways to pick $v_1$, and then the remaining $s-1$ vertices can be attached arbitrarily, yielding $s times 3^s-1$ such spanning trees.

    Adding up over all of the possibilities, we see there are
    $$3 times (s^2-s)times 3^s-2 + 3 times s times 3^s-2 = s^2 times 3^s-1$$
    spanning trees.



    Clearly, this sort of analysis becomes unwieldy for even $K_4,s$, let alone the general case. Hopefully it illustrates the power of Kirchoff's theorem over this more simple-minded approach.






    share|cite|improve this answer











    $endgroup$












    • $begingroup$
      Thanks so much, this is really useful and interesting!
      $endgroup$
      – 178971
      Mar 22 at 8:09










    • $begingroup$
      I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
      $endgroup$
      – 178971
      Mar 24 at 21:33











    • $begingroup$
      I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
      $endgroup$
      – Jeremy Dover
      Mar 24 at 22:23










    • $begingroup$
      I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
      $endgroup$
      – 178971
      Mar 24 at 22:30










    • $begingroup$
      It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
      $endgroup$
      – Jeremy Dover
      Mar 25 at 15:02















    1












    $begingroup$

    Let $S=x,y,z$ be one set of the bipartition of $K_3,s$. Let $T$ be any spanning tree of $K_3,s$.



    Look first at $x$. Since $T$ is a tree, there exists a unique path $x=v_0, ldots, v_n=y$ from $x$ to $y$ in $T$. Clearly $v_1$ is in the other set of the bipartition, but $v_2$ must be in $S$.



    Case 1: $v_2 = z$. In this case, the path from $x$ to $y$ must look like $x, v_1, z, v_3, y$. To create a spanning tree with this path structure from $x$ to $y$, there are $s$ choices for $v_1$, $s-1$ choices for $v_3$, and the remaining $s-2$ vertices can be attached arbitrarily to the three vertices of $S$ in $3^s-2$ ways. Hence there are $(s^2-s) times 3^s-2$ such spanning trees of $K_3,s$.



    Case 2: $v_2=y$. In this case the path from $x$ to $y$ is $x, v_1, y$, and we consider the path from $x$ to $z$. There are three possible configurations for this path in $T$:




    1. $x, v_1, y, v_3, z$: as before, there are $s$ choices for $v_1$ and $s-1$ choices for $v_3$, with the remaining vertices attached to a vertex of $S$ arbitrarily, yielding $(s^2-s) times 3^s-2$ such spanning trees.


    2. $x, w_1, z$, where $w_1 ne v_1$: there are $s$ choices for $v_1$ and $s-1$ choices for $w_1$, and again $3^s-2$ ways to attach the remaining vertices, yielding $(s^2-s) times 3^s-2$ such spanning trees


    3. $x,v_1,z$: in which all of $x$, $y$ and $z$ are attached to the same vertex. There are $s$ ways to pick $v_1$, and then the remaining $s-1$ vertices can be attached arbitrarily, yielding $s times 3^s-1$ such spanning trees.

    Adding up over all of the possibilities, we see there are
    $$3 times (s^2-s)times 3^s-2 + 3 times s times 3^s-2 = s^2 times 3^s-1$$
    spanning trees.



    Clearly, this sort of analysis becomes unwieldy for even $K_4,s$, let alone the general case. Hopefully it illustrates the power of Kirchoff's theorem over this more simple-minded approach.






    share|cite|improve this answer











    $endgroup$












    • $begingroup$
      Thanks so much, this is really useful and interesting!
      $endgroup$
      – 178971
      Mar 22 at 8:09










    • $begingroup$
      I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
      $endgroup$
      – 178971
      Mar 24 at 21:33











    • $begingroup$
      I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
      $endgroup$
      – Jeremy Dover
      Mar 24 at 22:23










    • $begingroup$
      I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
      $endgroup$
      – 178971
      Mar 24 at 22:30










    • $begingroup$
      It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
      $endgroup$
      – Jeremy Dover
      Mar 25 at 15:02













    1












    1








    1





    $begingroup$

    Let $S=x,y,z$ be one set of the bipartition of $K_3,s$. Let $T$ be any spanning tree of $K_3,s$.



    Look first at $x$. Since $T$ is a tree, there exists a unique path $x=v_0, ldots, v_n=y$ from $x$ to $y$ in $T$. Clearly $v_1$ is in the other set of the bipartition, but $v_2$ must be in $S$.



    Case 1: $v_2 = z$. In this case, the path from $x$ to $y$ must look like $x, v_1, z, v_3, y$. To create a spanning tree with this path structure from $x$ to $y$, there are $s$ choices for $v_1$, $s-1$ choices for $v_3$, and the remaining $s-2$ vertices can be attached arbitrarily to the three vertices of $S$ in $3^s-2$ ways. Hence there are $(s^2-s) times 3^s-2$ such spanning trees of $K_3,s$.



    Case 2: $v_2=y$. In this case the path from $x$ to $y$ is $x, v_1, y$, and we consider the path from $x$ to $z$. There are three possible configurations for this path in $T$:




    1. $x, v_1, y, v_3, z$: as before, there are $s$ choices for $v_1$ and $s-1$ choices for $v_3$, with the remaining vertices attached to a vertex of $S$ arbitrarily, yielding $(s^2-s) times 3^s-2$ such spanning trees.


    2. $x, w_1, z$, where $w_1 ne v_1$: there are $s$ choices for $v_1$ and $s-1$ choices for $w_1$, and again $3^s-2$ ways to attach the remaining vertices, yielding $(s^2-s) times 3^s-2$ such spanning trees


    3. $x,v_1,z$: in which all of $x$, $y$ and $z$ are attached to the same vertex. There are $s$ ways to pick $v_1$, and then the remaining $s-1$ vertices can be attached arbitrarily, yielding $s times 3^s-1$ such spanning trees.

    Adding up over all of the possibilities, we see there are
    $$3 times (s^2-s)times 3^s-2 + 3 times s times 3^s-2 = s^2 times 3^s-1$$
    spanning trees.



    Clearly, this sort of analysis becomes unwieldy for even $K_4,s$, let alone the general case. Hopefully it illustrates the power of Kirchoff's theorem over this more simple-minded approach.






    share|cite|improve this answer











    $endgroup$



    Let $S=x,y,z$ be one set of the bipartition of $K_3,s$. Let $T$ be any spanning tree of $K_3,s$.



    Look first at $x$. Since $T$ is a tree, there exists a unique path $x=v_0, ldots, v_n=y$ from $x$ to $y$ in $T$. Clearly $v_1$ is in the other set of the bipartition, but $v_2$ must be in $S$.



    Case 1: $v_2 = z$. In this case, the path from $x$ to $y$ must look like $x, v_1, z, v_3, y$. To create a spanning tree with this path structure from $x$ to $y$, there are $s$ choices for $v_1$, $s-1$ choices for $v_3$, and the remaining $s-2$ vertices can be attached arbitrarily to the three vertices of $S$ in $3^s-2$ ways. Hence there are $(s^2-s) times 3^s-2$ such spanning trees of $K_3,s$.



    Case 2: $v_2=y$. In this case the path from $x$ to $y$ is $x, v_1, y$, and we consider the path from $x$ to $z$. There are three possible configurations for this path in $T$:




    1. $x, v_1, y, v_3, z$: as before, there are $s$ choices for $v_1$ and $s-1$ choices for $v_3$, with the remaining vertices attached to a vertex of $S$ arbitrarily, yielding $(s^2-s) times 3^s-2$ such spanning trees.


    2. $x, w_1, z$, where $w_1 ne v_1$: there are $s$ choices for $v_1$ and $s-1$ choices for $w_1$, and again $3^s-2$ ways to attach the remaining vertices, yielding $(s^2-s) times 3^s-2$ such spanning trees


    3. $x,v_1,z$: in which all of $x$, $y$ and $z$ are attached to the same vertex. There are $s$ ways to pick $v_1$, and then the remaining $s-1$ vertices can be attached arbitrarily, yielding $s times 3^s-1$ such spanning trees.

    Adding up over all of the possibilities, we see there are
    $$3 times (s^2-s)times 3^s-2 + 3 times s times 3^s-2 = s^2 times 3^s-1$$
    spanning trees.



    Clearly, this sort of analysis becomes unwieldy for even $K_4,s$, let alone the general case. Hopefully it illustrates the power of Kirchoff's theorem over this more simple-minded approach.







    share|cite|improve this answer














    share|cite|improve this answer



    share|cite|improve this answer








    edited Mar 22 at 13:06

























    answered Mar 22 at 2:31









    Jeremy DoverJeremy Dover

    1,249411




    1,249411











    • $begingroup$
      Thanks so much, this is really useful and interesting!
      $endgroup$
      – 178971
      Mar 22 at 8:09










    • $begingroup$
      I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
      $endgroup$
      – 178971
      Mar 24 at 21:33











    • $begingroup$
      I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
      $endgroup$
      – Jeremy Dover
      Mar 24 at 22:23










    • $begingroup$
      I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
      $endgroup$
      – 178971
      Mar 24 at 22:30










    • $begingroup$
      It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
      $endgroup$
      – Jeremy Dover
      Mar 25 at 15:02
















    • $begingroup$
      Thanks so much, this is really useful and interesting!
      $endgroup$
      – 178971
      Mar 22 at 8:09










    • $begingroup$
      I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
      $endgroup$
      – 178971
      Mar 24 at 21:33











    • $begingroup$
      I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
      $endgroup$
      – Jeremy Dover
      Mar 24 at 22:23










    • $begingroup$
      I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
      $endgroup$
      – 178971
      Mar 24 at 22:30










    • $begingroup$
      It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
      $endgroup$
      – Jeremy Dover
      Mar 25 at 15:02















    $begingroup$
    Thanks so much, this is really useful and interesting!
    $endgroup$
    – 178971
    Mar 22 at 8:09




    $begingroup$
    Thanks so much, this is really useful and interesting!
    $endgroup$
    – 178971
    Mar 22 at 8:09












    $begingroup$
    I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
    $endgroup$
    – 178971
    Mar 24 at 21:33





    $begingroup$
    I have another question on this, what is the number of distinct isomorphism types of spanning trees of $K_3,s$? Am I correct in thinking it would be 4?
    $endgroup$
    – 178971
    Mar 24 at 21:33













    $begingroup$
    I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
    $endgroup$
    – Jeremy Dover
    Mar 24 at 22:23




    $begingroup$
    I think it's a lot more than that. Look at the case where all three vertices of $S$ are distance 2 from each other. In order for two such trees to be isomorphic, the multiset of sizes of the neighborhoods of each of the three vertices in $S$ must be identical. Even for $s=5$, there are already 5 different such partitions: $5,0,0,4,1,0,3,2,0,3,1,1,2,2,1$, i.e., the number of partitions of 5 into at most 3 integers.
    $endgroup$
    – Jeremy Dover
    Mar 24 at 22:23












    $begingroup$
    I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
    $endgroup$
    – 178971
    Mar 24 at 22:30




    $begingroup$
    I see how it would be a lot more. Is there any way of figuring this number out for arbitrary $s$?
    $endgroup$
    – 178971
    Mar 24 at 22:30












    $begingroup$
    It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
    $endgroup$
    – Jeremy Dover
    Mar 25 at 15:02




    $begingroup$
    It should be doable, but the devil is going to be the edge cases. I'd start by just computing this for $s=3$, since it is likely going to have some exceptional collapsing. Then for $s ge 4$ I'd split the problem into two, based on whether the vertices from the size 3 partition form a star or a path in the spanning tree. For each of these subcases, the problem should reduce to counting partitions of the set of $s$ points, connecting them to the appropriate vertex of degree $s$.
    $endgroup$
    – Jeremy Dover
    Mar 25 at 15:02











    1












    $begingroup$

    Adding a separate answer because I now have a much simpler proof!




    To prove there are $m^n-1n^m-1$ spanning trees, we will use a slight modification of Prüfer's original algorithm to get a bijection between trees and integers sequences of length $m+n-2$. Recall that to get a Prufer code, you repeatedly delete the smallest leaf, and record the label of its neighbor. In our case, we will do almost the same; however, instead of always pruning the smallest leaf, we will prune the smallest leaf in a specific part of the bipartite graph.



    Specifically, suppose $mle n$. We will prune leaves from the parts according to the following pattern:
    $$
    underbracemathsfN,N,dots,N_n-m,underbracemathsfN,M,N,Mdots,N,M_2(m-1)
    $$



    So the first string of leaves will come from the larger part, until the parts are equalized, and we alternate thereafter. There are obviously $m^n-1n^m-1$ possible codes resulting from this pattern, and you can show this procedure is a bijection in a similar way.



    How do we know we can always find a leaf in the prescribed part? By this lemma:




    Lemma: In the bipartite graph $K_m,n$, with $mle n$, there is a leaf in the part of size $n$.




    Proof: The sum of the degrees of the vertices in the $n$ part is equal to the total number of edges, $n+m-1$. If each vertex had degree $2$ or more, this sum of degrees would be at least $2n>n+m-1$. $square$






    share|cite|improve this answer









    $endgroup$

















      1












      $begingroup$

      Adding a separate answer because I now have a much simpler proof!




      To prove there are $m^n-1n^m-1$ spanning trees, we will use a slight modification of Prüfer's original algorithm to get a bijection between trees and integers sequences of length $m+n-2$. Recall that to get a Prufer code, you repeatedly delete the smallest leaf, and record the label of its neighbor. In our case, we will do almost the same; however, instead of always pruning the smallest leaf, we will prune the smallest leaf in a specific part of the bipartite graph.



      Specifically, suppose $mle n$. We will prune leaves from the parts according to the following pattern:
      $$
      underbracemathsfN,N,dots,N_n-m,underbracemathsfN,M,N,Mdots,N,M_2(m-1)
      $$



      So the first string of leaves will come from the larger part, until the parts are equalized, and we alternate thereafter. There are obviously $m^n-1n^m-1$ possible codes resulting from this pattern, and you can show this procedure is a bijection in a similar way.



      How do we know we can always find a leaf in the prescribed part? By this lemma:




      Lemma: In the bipartite graph $K_m,n$, with $mle n$, there is a leaf in the part of size $n$.




      Proof: The sum of the degrees of the vertices in the $n$ part is equal to the total number of edges, $n+m-1$. If each vertex had degree $2$ or more, this sum of degrees would be at least $2n>n+m-1$. $square$






      share|cite|improve this answer









      $endgroup$















        1












        1








        1





        $begingroup$

        Adding a separate answer because I now have a much simpler proof!




        To prove there are $m^n-1n^m-1$ spanning trees, we will use a slight modification of Prüfer's original algorithm to get a bijection between trees and integers sequences of length $m+n-2$. Recall that to get a Prufer code, you repeatedly delete the smallest leaf, and record the label of its neighbor. In our case, we will do almost the same; however, instead of always pruning the smallest leaf, we will prune the smallest leaf in a specific part of the bipartite graph.



        Specifically, suppose $mle n$. We will prune leaves from the parts according to the following pattern:
        $$
        underbracemathsfN,N,dots,N_n-m,underbracemathsfN,M,N,Mdots,N,M_2(m-1)
        $$



        So the first string of leaves will come from the larger part, until the parts are equalized, and we alternate thereafter. There are obviously $m^n-1n^m-1$ possible codes resulting from this pattern, and you can show this procedure is a bijection in a similar way.



        How do we know we can always find a leaf in the prescribed part? By this lemma:




        Lemma: In the bipartite graph $K_m,n$, with $mle n$, there is a leaf in the part of size $n$.




        Proof: The sum of the degrees of the vertices in the $n$ part is equal to the total number of edges, $n+m-1$. If each vertex had degree $2$ or more, this sum of degrees would be at least $2n>n+m-1$. $square$






        share|cite|improve this answer









        $endgroup$



        Adding a separate answer because I now have a much simpler proof!




        To prove there are $m^n-1n^m-1$ spanning trees, we will use a slight modification of Prüfer's original algorithm to get a bijection between trees and integers sequences of length $m+n-2$. Recall that to get a Prufer code, you repeatedly delete the smallest leaf, and record the label of its neighbor. In our case, we will do almost the same; however, instead of always pruning the smallest leaf, we will prune the smallest leaf in a specific part of the bipartite graph.



        Specifically, suppose $mle n$. We will prune leaves from the parts according to the following pattern:
        $$
        underbracemathsfN,N,dots,N_n-m,underbracemathsfN,M,N,Mdots,N,M_2(m-1)
        $$



        So the first string of leaves will come from the larger part, until the parts are equalized, and we alternate thereafter. There are obviously $m^n-1n^m-1$ possible codes resulting from this pattern, and you can show this procedure is a bijection in a similar way.



        How do we know we can always find a leaf in the prescribed part? By this lemma:




        Lemma: In the bipartite graph $K_m,n$, with $mle n$, there is a leaf in the part of size $n$.




        Proof: The sum of the degrees of the vertices in the $n$ part is equal to the total number of edges, $n+m-1$. If each vertex had degree $2$ or more, this sum of degrees would be at least $2n>n+m-1$. $square$







        share|cite|improve this answer












        share|cite|improve this answer



        share|cite|improve this answer










        answered Mar 23 at 0:05









        Mike EarnestMike Earnest

        27k22152




        27k22152



























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Mathematics Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            Use MathJax to format equations. MathJax reference.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3157546%2fprove-that-the-complete-bipartite-graph-k-3-s-has-s23s-1-spanning-tree%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Moe incest case Sentencing See also References Navigation menu"'Australian Josef Fritzl' fathered four children by daughter""Small town recoils in horror at 'Australian Fritzl' incest case""Victorian rape allegations echo Fritzl case - Just In (Australian Broadcasting Corporation)""Incest father jailed for 22 years""'Australian Fritzl' sentenced to 22 years in prison for abusing daughter for three decades""RSJ v The Queen"

            Who is our nearest planetary neighbor, on average?Santa Claus flies to the South PoleSeven Spheres of Unequal Mass, a weighing problem with a twistDescribe a large integerFast Mental Calculation of $7.5^7$Math in Space (without the help of celebrities)Find the value of $bigstar$: Puzzle 8 - InequalityWho drinks beer while running anyway?A Crucial DeliveryRanking And AverageHow long will my money last at roulette?

            Daza language Contents Vocabulary Phonology References External links Navigation menudaza1242Daza"Dazaga"eeee178086576